sfgboxapi

<back to all web services

MediaLookup

The following routes are available for this service:
GET/media
import 'package:servicestack/servicestack.dart';

// @DataContract
class MediaLookup implements IConvertible
{
    // @DataMember(Order=2)
    int? tenantsId;

    // @DataMember(Order=3)
    String? entity;

    // @DataMember(Order=5)
    int? entityId;

    // @DataMember(Order=6)
    String? mediaType;

    // @DataMember(Order=7)
    String? mediaPath;

    // @DataMember(Order=8)
    int? questionnairsId;

    // @DataMember(Order=9)
    String? name;

    // @DataMember(Order=10)
    bool? free;

    // @DataMember(Order=11)
    String? publicAccessGuid;

    MediaLookup({this.tenantsId,this.entity,this.entityId,this.mediaType,this.mediaPath,this.questionnairsId,this.name,this.free,this.publicAccessGuid});
    MediaLookup.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        tenantsId = json['tenantsId'];
        entity = json['entity'];
        entityId = json['entityId'];
        mediaType = json['mediaType'];
        mediaPath = json['mediaPath'];
        questionnairsId = json['questionnairsId'];
        name = json['name'];
        free = json['free'];
        publicAccessGuid = json['publicAccessGuid'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'tenantsId': tenantsId,
        'entity': entity,
        'entityId': entityId,
        'mediaType': mediaType,
        'mediaPath': mediaPath,
        'questionnairsId': questionnairsId,
        'name': name,
        'free': free,
        'publicAccessGuid': publicAccessGuid
    };

    getTypeName() => "MediaLookup";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'sfgboxapi.dev.scadsoftware.com', types: <String, TypeInfo> {
    'MediaLookup': TypeInfo(TypeOf.Class, create:() => MediaLookup()),
});

Dart MediaLookup DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other

HTTP + OTHER

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /media HTTP/1.1 
Host: sfgboxapi.dev.scadsoftware.com 
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{Unable to show example output for type 'IEnumerable`1' using the custom 'other' filter}Cannot dynamically create an instance of type 'System.Collections.Generic.IEnumerable`1[sfgboxapi.ServiceModel.MediaLookupResponse]'. Reason: Cannot create an instance of an interface.