GET | /api/ShippingAddressLookup |
---|
"use strict";
export class BaseRequest {
/** @param {{ApiKey?:string,OAuthToken?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {string}
* @description This is your AIM API Key provided by Tri-Tech */
ApiKey;
/** @type {string} */
OAuthToken;
}
export class BaseSecureRequest extends BaseRequest {
/** @param {{Token?:string,DeviceId?:string,AppId?:string,ApiKey?:string,OAuthToken?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {string} */
Token;
/** @type {string} */
DeviceId;
/** @type {string} */
AppId;
}
export class BaseResponseResult {
/** @param {{StatusCode?:string,Login?:string,ErrorCode?:string,ErrorDisplayText?:string,ErrorMessage?:string,DomainName?:string,IpAddress?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
StatusCode;
/** @type {string} */
Login;
/** @type {string} */
ErrorCode;
/** @type {string} */
ErrorDisplayText;
/** @type {string} */
ErrorMessage;
/** @type {string} */
DomainName;
/** @type {string} */
IpAddress;
}
export class BaseResponse {
/** @param {{Status?:BaseResponseResult}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {BaseResponseResult} */
Status;
}
export class ShipToInfo {
/** @param {{Id?:number,Name?:string,Attention?:string,Address1?:string,Address2?:string,City?:string,State?:string,Zip?:string,Country?:string,Email?:string,Phone?:string,Phone2?:string,Notes?:string,Primary?:boolean,TaxLoc?:string,Active?:boolean}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
Id;
/** @type {string} */
Name;
/** @type {string} */
Attention;
/** @type {string} */
Address1;
/** @type {string} */
Address2;
/** @type {string} */
City;
/** @type {string} */
State;
/** @type {string} */
Zip;
/** @type {string} */
Country;
/** @type {string} */
Email;
/** @type {string} */
Phone;
/** @type {string} */
Phone2;
/** @type {string} */
Notes;
/** @type {boolean} */
Primary;
/** @type {string} */
TaxLoc;
/** @type {boolean} */
Active;
}
export class ShippingAddressLookupResponse extends BaseResponse {
/** @param {{ShipTos?:ShipToInfo[],Status?:BaseResponseResult}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {ShipToInfo[]} */
ShipTos;
}
export class ShippingAddressLookupRequest extends BaseSecureRequest {
/** @param {{Acct?:number,ShipId?:number,Token?:string,DeviceId?:string,AppId?:string,ApiKey?:string,OAuthToken?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/**
* @type {?number}
* @description Pass in this parameter if you want to lookup all shipping addresses linked to a customer. Not required if using a customer login. Do not pass in this parameter if passing in the ShipId parameter. */
Acct;
/**
* @type {?number}
* @description Use this parameter to lookup a single Shipping Address with this ID. Do not pass in this parameter if passing in the Acct parameter. */
ShipId;
}
JavaScript ShippingAddressLookupRequest 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.
GET /api/ShippingAddressLookup HTTP/1.1 Host: active-ewebservice.biz Accept: application/json
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"ShipTos":[{"Id":0,"Name":"String","Attention":"String","Address1":"String","Address2":"String","City":"String","State":"String","Zip":"String","Country":"String","Email":"String","Phone":"String","Phone2":"String","Notes":"String","Primary":false,"TaxLoc":"String","Active":false}],"Status":{"StatusCode":"String","Login":"String","ErrorCode":"String","ErrorDisplayText":"String","ErrorMessage":"String","DomainName":"String","IpAddress":"String"}}