| POST,OPTIONS | /v1/integrations/{Provider}/{Action} |
|---|
"use strict";
export class ProviderView {
/** @param {{Key?:string,Name?:string,Category?:string,Blurb?:string,Mono?:string,AuthMode?:string,Available?:boolean,Status?:string,Health?:string,StatusDetail?:string,AccountLabel?:string,Environment?:string,LastActivityAt?:string,ManageRoute?:string,Actions?:string[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Key;
/** @type {string} */
Name;
/** @type {string} */
Category;
/** @type {string} */
Blurb;
/** @type {string} */
Mono;
/** @type {string} */
AuthMode;
/** @type {boolean} */
Available;
/** @type {string} */
Status;
/** @type {string} */
Health;
/** @type {string} */
StatusDetail;
/** @type {string} */
AccountLabel;
/** @type {string} */
Environment;
/** @type {?string} */
LastActivityAt;
/** @type {string} */
ManageRoute;
/** @type {string[]} */
Actions = [];
}
export class IntegrationsActionResponse {
/** @param {{Ok?:boolean,Message?:string,Url?:string,Provider?:ProviderView,ResponseStatus?:ResponseStatus}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {boolean} */
Ok;
/** @type {string} */
Message;
/** @type {string} */
Url;
/** @type {ProviderView} */
Provider;
/** @type {ResponseStatus} */
ResponseStatus;
}
export class IntegrationsActionRequest {
/** @param {{Provider?:string,Action?:string,ApiKey?:string,FromDate?:string,ToDate?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Provider;
/** @type {string} */
Action;
/** @type {string} */
ApiKey;
/** @type {string} */
FromDate;
/** @type {string} */
ToDate;
}
JavaScript IntegrationsActionRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/integrations/{Provider}/{Action} HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
Provider: String,
Action: String,
ApiKey: String,
FromDate: String,
ToDate: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
Ok: False,
Message: String,
Url: String,
Provider:
{
Key: String,
Name: String,
Category: String,
Blurb: String,
Mono: String,
AuthMode: String,
Available: False,
Status: String,
Health: String,
StatusDetail: String,
AccountLabel: String,
Environment: String,
LastActivityAt: 0001-01-01,
ManageRoute: String,
Actions:
[
String
]
},
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}
}