Trendsic Platform Service

<back to all web services

AgreementCreditsRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/serviceagreement/credits

export class CreditLedger
{
    public CreditLedgerID: number;
    public TenantId: string;
    public BranchId?: string;
    public AgreementID?: number;
    public ProjectID?: number;
    public AgreementJobID?: number;
    public Amount?: number;
    public Reason: string;
    public Status: string;
    public CreatedBy: string;
    public CreatedAt?: string;
    public AppliedAt?: string;
    public AgreementName: string;
    public ProjectName: string;

    public constructor(init?: Partial<CreditLedger>) { (Object as any).assign(this, init); }
}

export class AgreementCreditsResponse
{
    public ResponseStatus: ResponseStatus;
    public Credits: CreditLedger[] = [];

    public constructor(init?: Partial<AgreementCreditsResponse>) { (Object as any).assign(this, init); }
}

export class AgreementCreditsRequest
{

    public constructor(init?: Partial<AgreementCreditsRequest>) { (Object as any).assign(this, init); }
}

TypeScript AgreementCreditsRequest 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.

GET /v1/serviceagreement/credits HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
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
		}
	},
	Credits: 
	[
		{
			CreditLedgerID: 0,
			TenantId: 00000000000000000000000000000000,
			BranchId: 00000000000000000000000000000000,
			AgreementID: 0,
			ProjectID: 0,
			AgreementJobID: 0,
			Amount: 0,
			Reason: String,
			Status: String,
			CreatedBy: String,
			CreatedAt: 0001-01-01,
			AppliedAt: 0001-01-01,
			AgreementName: String,
			ProjectName: String
		}
	]
}