| POST,OPTIONS | /v1/book/{Slug}/orders | ||
|---|---|---|---|
| POST,OPTIONS | /v1/book/{Slug}/orders/confirm |
"use strict";
export class CourierBookOrderResponse {
/** @param {{Done?:boolean,NeedsAction?:boolean,ClientSecret?:string,SetupIntentId?:string,Code?:string,TrackUrl?:string,IcsUrl?:string,WindowText?:string,Promise?:string,Total?:number,PayTiming?:string,CardLast4?:string,Repeats?:string,LinkSentBy?:string,ReopenStep?:string,ResponseStatus?:ResponseStatus}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {boolean} */
Done;
/** @type {boolean} */
NeedsAction;
/** @type {string} */
ClientSecret;
/** @type {string} */
SetupIntentId;
/** @type {string} */
Code;
/** @type {string} */
TrackUrl;
/** @type {string} */
IcsUrl;
/** @type {string} */
WindowText;
/** @type {string} */
Promise;
/** @type {number} */
Total;
/** @type {string} */
PayTiming;
/** @type {string} */
CardLast4;
/** @type {string} */
Repeats;
/** @type {string} */
LinkSentBy;
/** @type {string} */
ReopenStep;
/** @type {ResponseStatus} */
ResponseStatus;
}
export class CourierBookOrderRequest {
/** @param {{Slug?:string,Profile?:string,TurnstileToken?:string,Level?:string,WindowId?:string,Recur?:string,Address?:string,Unit?:string,City?:string,Zip?:string,Lat?:number,Lng?:number,PickupName?:string,DropAddress?:string,DropUnit?:string,DropCity?:string,DropZip?:string,DropLat?:number,DropLng?:number,RecipientName?:string,Units?:number,Handoff?:string,GateCode?:string,Note?:string,Name?:string,Phone?:string,Email?:string,SmsConsent?:boolean,Terms?:boolean,PaymentMethodId?:string,SetupIntentId?:string,QuotedTotal?:number,Lang?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Slug;
/** @type {string} */
Profile;
/** @type {string} */
TurnstileToken;
/** @type {string} */
Level;
/** @type {string} */
WindowId;
/** @type {string} */
Recur;
/** @type {string} */
Address;
/** @type {string} */
Unit;
/** @type {string} */
City;
/** @type {string} */
Zip;
/** @type {?number} */
Lat;
/** @type {?number} */
Lng;
/** @type {string} */
PickupName;
/** @type {string} */
DropAddress;
/** @type {string} */
DropUnit;
/** @type {string} */
DropCity;
/** @type {string} */
DropZip;
/** @type {?number} */
DropLat;
/** @type {?number} */
DropLng;
/** @type {string} */
RecipientName;
/** @type {number} */
Units;
/** @type {string} */
Handoff;
/** @type {string} */
GateCode;
/** @type {string} */
Note;
/** @type {string} */
Name;
/** @type {string} */
Phone;
/** @type {string} */
Email;
/** @type {boolean} */
SmsConsent;
/** @type {boolean} */
Terms;
/** @type {string} */
PaymentMethodId;
/** @type {string} */
SetupIntentId;
/** @type {?number} */
QuotedTotal;
/** @type {string} */
Lang;
}
JavaScript CourierBookOrderRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/book/{Slug}/orders HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"Slug":"String","Profile":"String","TurnstileToken":"String","Level":"String","WindowId":"String","Recur":"String","Address":"String","Unit":"String","City":"String","Zip":"String","Lat":0,"Lng":0,"PickupName":"String","DropAddress":"String","DropUnit":"String","DropCity":"String","DropZip":"String","DropLat":0,"DropLng":0,"RecipientName":"String","Units":0,"Handoff":"String","GateCode":"String","Note":"String","Name":"String","Phone":"String","Email":"String","SmsConsent":false,"Terms":false,"PaymentMethodId":"String","SetupIntentId":"String","QuotedTotal":0,"Lang":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"Done":false,"NeedsAction":false,"ClientSecret":"String","SetupIntentId":"String","Code":"String","TrackUrl":"String","IcsUrl":"String","WindowText":"String","Promise":"String","Total":0,"PayTiming":"String","CardLast4":"String","Repeats":"String","LinkSentBy":"String","ReopenStep":"String","ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}