| 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 .xml suffix or ?format=xml
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: application/xml
Content-Type: application/xml
Content-Length: length
<SerialDetailRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AIM.WebService">
<ApiKey>String</ApiKey>
<AppId>String</AppId>
<DeviceId>String</DeviceId>
<OAuthToken>String</OAuthToken>
<Token>String</Token>
<CustomerAcct>0</CustomerAcct>
<Pk>0</Pk>
<Serial>String</Serial>
<SkipImages>false</SkipImages>
</SerialDetailRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length
<SerialDetailResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AIM.WebService">
<Status>
<DomainName>String</DomainName>
<ErrorCode>String</ErrorCode>
<ErrorDisplayText>String</ErrorDisplayText>
<ErrorMessage>String</ErrorMessage>
<IpAddress>String</IpAddress>
<Login>String</Login>
<StatusCode>String</StatusCode>
</Status>
<Details i:nil="true" />
<LocPk>0</LocPk>
<Location>String</Location>
<Model>String</Model>
<SKU>String</SKU>
<SadPk>0</SadPk>
<SaqPk>0</SaqPk>
<SasPk>0</SasPk>
<Serial>String</Serial>
<SkuPk>0</SkuPk>
</SerialDetailResponse>