digitaluapi

<back to all web services

ActionDocumentsAdd

Requires Authentication
Requires any of the roles:Client, Admin, Partner
The following routes are available for this service:
POST/action_documents
import 'package:servicestack/servicestack.dart';
import 'dart:collection';

class ActionDocumentsAddResponse implements IConvertible
{
    // @DataMember(Order=2)
    int? TenantsId;

    // @DataMember(Order=3)
    int? ActionsId;

    // @DataMember(Order=4)
    String? DocumentUrl;

    // @DataMember(Order=6)
    ResponseStatus? ResponseStatus;

    ActionDocumentsAddResponse({this.TenantsId,this.ActionsId,this.DocumentUrl,this.ResponseStatus});
    ActionDocumentsAddResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        TenantsId = json['TenantsId'];
        ActionsId = json['ActionsId'];
        DocumentUrl = json['DocumentUrl'];
        ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'TenantsId': TenantsId,
        'ActionsId': ActionsId,
        'DocumentUrl': DocumentUrl,
        'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!)
    };

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

// @DataContract
class ActionDocumentsAdd implements IConvertible
{
    // @DataMember(Order=2)
    // @Validate(Validator="NotNull")
    int? TenantsId;

    // @DataMember(Order=3)
    // @Validate(Validator="NotNull")
    int? ActionsId;

    // @DataMember(Order=4)
    // @Validate(Validator="NotNull")
    String? DocumentUrl;

    ActionDocumentsAdd({this.TenantsId,this.ActionsId,this.DocumentUrl});
    ActionDocumentsAdd.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        TenantsId = json['TenantsId'];
        ActionsId = json['ActionsId'];
        DocumentUrl = json['DocumentUrl'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'TenantsId': TenantsId,
        'ActionsId': ActionsId,
        'DocumentUrl': DocumentUrl
    };

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

TypeContext _ctx = TypeContext(library: 'duengageapi.uat.scadsoftware.com', types: <String, TypeInfo> {
    'ActionDocumentsAddResponse': TypeInfo(TypeOf.Class, create:() => ActionDocumentsAddResponse()),
    'ActionDocumentsAdd': TypeInfo(TypeOf.Class, create:() => ActionDocumentsAdd()),
});

Dart ActionDocumentsAdd DTOs

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

HTTP + CSV

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

POST /action_documents HTTP/1.1 
Host: duengageapi.uat.scadsoftware.com 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"TenantsId":0,"ActionsId":0,"DocumentUrl":"String"}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"TenantsId":0,"ActionsId":0,"DocumentUrl":"String","ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}