Trendsic Platform Service

<back to all web services

FundingSourceSaveRequest

Requires Authentication
The following routes are available for this service:
POST,PUT,OPTIONS/v1/projects/{ProjectID}/funding-source
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class FundingSourceResponse implements IConvertible
{
    ResponseStatus? ResponseStatus;
    int? ProjectID;
    String? FundingSource;
    bool? FloorRequired;
    bool? MissingDetermination;

    FundingSourceResponse({this.ResponseStatus,this.ProjectID,this.FundingSource,this.FloorRequired,this.MissingDetermination});
    FundingSourceResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
        ProjectID = json['ProjectID'];
        FundingSource = json['FundingSource'];
        FloorRequired = json['FloorRequired'];
        MissingDetermination = json['MissingDetermination'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!),
        'ProjectID': ProjectID,
        'FundingSource': FundingSource,
        'FloorRequired': FloorRequired,
        'MissingDetermination': MissingDetermination
    };

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

class FundingSourceSaveRequest implements IConvertible
{
    int? ProjectID;
    String? FundingSource;

    FundingSourceSaveRequest({this.ProjectID,this.FundingSource});
    FundingSourceSaveRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ProjectID = json['ProjectID'];
        FundingSource = json['FundingSource'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ProjectID': ProjectID,
        'FundingSource': FundingSource
    };

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

TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: <String, TypeInfo> {
    'FundingSourceResponse': TypeInfo(TypeOf.Class, create:() => FundingSourceResponse()),
    'FundingSourceSaveRequest': TypeInfo(TypeOf.Class, create:() => FundingSourceSaveRequest()),
});

Dart FundingSourceSaveRequest DTOs

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

HTTP + JSV

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

POST /v1/projects/{ProjectID}/funding-source HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	ProjectID: 0,
	FundingSource: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	ProjectID: 0,
	FundingSource: String,
	FloorRequired: False,
	MissingDetermination: False
}