| POST, GET | /api/SerialDetail |
|---|
"use strict";
export class BaseRequest {
/** @param {{ApiKey?:string,OAuthToken?:string,DeviceId?:string,AppId?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {string}
* @description This is your AIM API Key provided by Tri-Tech */
ApiKey;
/**
* @type {string}
* @description The OAuthToken token return by AeServices30 */
OAuthToken;
/**
* @type {string}
* @description The Device ID of the Mobile Device. Not used for non-mobile devices. */
DeviceId;
/**
* @type {string}
* @description An identifier for your integration */
AppId;
}
export class BaseSecureRequest extends BaseRequest {
/** @param {{Token?:string,ApiKey?:string,OAuthToken?:string,DeviceId?:string,AppId?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/**
* @type {string}
* @description The Login Token return by the Security API. Required for secured calls. */
Token;
}
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 InventoryDetailAttribute {
/** @param {{Name?:string,Value?:string,Priority?:number,WebType?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Name;
/** @type {string} */
Value;
/** @type {number} */
Priority;
/**
* @type {number}
* @description 1 is 'Don't Send to Web', 2 is 'Send To Web' */
WebType;
}
export class ImageInfo {
/** @param {{Url?:string,ImageStream?:string,ImageSize?:string,ErrorMessage?:string,UriPk?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Url;
/** @type {string} */
ImageStream;
/** @type {string} */
ImageSize;
/** @type {string} */
ErrorMessage;
/** @type {?number} */
UriPk;
}
export class InventoryDetailBySerial {
/** @param {{SasPk?:number,Serial?:string,Retail?:number,OurPrice?:number,SalePrice?:number,Status?:string,SaleInfo?:string,PriceA?:number,PriceB?:number,PriceC?:number,MinPrice?:number,ActiveEPrice?:number,AllowPriceChange?:boolean,Cost?:number,WeightedCost?:number,Notes?:string,Attributes?:InventoryDetailAttribute[],Images?:ImageInfo[],HasImages?:boolean,IsActiveeHoldback?:boolean,CustomerAcct?:number,AvailableForSTR?:boolean}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
SasPk;
/** @type {string} */
Serial;
/** @type {number} */
Retail;
/** @type {number} */
OurPrice;
/** @type {?number} */
SalePrice;
/** @type {string} */
Status;
/** @type {string} */
SaleInfo;
/** @type {number} */
PriceA;
/** @type {number} */
PriceB;
/** @type {number} */
PriceC;
/** @type {number} */
MinPrice;
/** @type {number} */
ActiveEPrice;
/** @type {boolean} */
AllowPriceChange;
/** @type {?number} */
Cost;
/** @type {?number} */
WeightedCost;
/** @type {string} */
Notes;
/** @type {InventoryDetailAttribute[]} */
Attributes;
/** @type {ImageInfo[]} */
Images;
/** @type {boolean} */
HasImages;
/** @type {boolean} */
IsActiveeHoldback;
/** @type {?number} */
CustomerAcct;
/** @type {boolean} */
AvailableForSTR;
}
export class SerialDetailResponse extends BaseResponse {
/** @param {{SasPk?:number,Serial?:string,SaqPk?:number,LocPk?:number,Location?:string,SkuPk?:number,SKU?:string,SadPk?:number,Model?:string,Details?:InventoryDetailBySerial,Status?:BaseResponseResult}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {number} */
SasPk;
/** @type {string} */
Serial;
/** @type {number} */
SaqPk;
/** @type {number} */
LocPk;
/** @type {string} */
Location;
/** @type {number} */
SkuPk;
/** @type {string} */
SKU;
/** @type {number} */
SadPk;
/** @type {string} */
Model;
/** @type {InventoryDetailBySerial} */
Details;
}
export class SerialDetailRequest extends BaseSecureRequest {
/** @param {{Pk?:number,Serial?:string,SkipImages?:boolean,CustomerAcct?:number,Token?:string,ApiKey?:string,OAuthToken?:string,DeviceId?:string,AppId?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/**
* @type {?number}
* @description The PK being used for lookup. Do not use if Serial is passed in. */
Pk;
/**
* @type {string}
* @description The Serial# being used for lookup. Do not use if Pk is passed in. */
Serial;
/** @type {boolean} */
SkipImages;
/**
* @type {?number}
* @description If sent, the Customer Acct will be used for customer specific pricing. */
CustomerAcct;
}
JavaScript SerialDetailRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/SerialDetail HTTP/1.1
Host: active-ewebservice.biz
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length
{"Pk":0,"Serial":"String","SkipImages":false,"CustomerAcct":0,"Token":"String","ApiKey":"String","OAuthToken":"String","DeviceId":"String","AppId":"String"}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length
{"SasPk":0,"Serial":"String","SaqPk":0,"LocPk":0,"Location":"String","SkuPk":0,"SKU":"String","SadPk":0,"Model":"String","Status":{"StatusCode":"String","Login":"String","ErrorCode":"String","ErrorDisplayText":"String","ErrorMessage":"String","DomainName":"String","IpAddress":"String"}}