GET | /api/InventoryHistory |
---|
"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 InventoryHistoryObj {
/** @param {{DateVal?:string,SDateVal?:string,Acct?:number,Sub?:number,CusName?:string,Qty?:number,Amt?:number,Ref?:string,Type?:string,Serial?:string,Employee?:string,EmployeeName?:string,Stloc?:string,Dunn?:string,SoldDesc?:string,Tcp_rtncode?:string,TableName?:string,TraPk?:number,CusPk?:number,SasPk?:number,SaqPk?:number,SkuPk?:number,SadPk?:number,TablePk?:number,Description?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
DateVal;
/** @type {string} */
SDateVal;
/** @type {number} */
Acct;
/** @type {number} */
Sub;
/** @type {string} */
CusName;
/** @type {number} */
Qty;
/** @type {number} */
Amt;
/** @type {string} */
Ref;
/** @type {string} */
Type;
/** @type {string} */
Serial;
/** @type {string} */
Employee;
/** @type {string} */
EmployeeName;
/** @type {string} */
Stloc;
/** @type {string} */
Dunn;
/** @type {string} */
SoldDesc;
/** @type {string} */
Tcp_rtncode;
/** @type {string} */
TableName;
/** @type {?number} */
TraPk;
/** @type {?number} */
CusPk;
/** @type {?number} */
SasPk;
/** @type {?number} */
SaqPk;
/** @type {?number} */
SkuPk;
/** @type {?number} */
SadPk;
/** @type {number} */
TablePk;
/** @type {string} */
Description;
}
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 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 'Guided Navigation' */
WebType;
}
export class LocationInfo {
/** @param {{Id?:number,Desc?:string,ShortDesc?:string,Region?:string,Latitude?:number,Longitude?:number,InStorePickup?:string,Active?:boolean,CashSaleAcct?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
Id;
/** @type {string} */
Desc;
/** @type {string} */
ShortDesc;
/** @type {string} */
Region;
/** @type {number} */
Latitude;
/** @type {number} */
Longitude;
/** @type {string} */
InStorePickup;
/** @type {boolean} */
Active;
/** @type {?number} */
CashSaleAcct;
}
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 InventoryDetailSubstitute {
/** @param {{Model?:string,Sku?:string,Mfg?:string,Description?:string,Price?:number,AvailableQty?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Model;
/** @type {string} */
Sku;
/** @type {string} */
Mfg;
/** @type {string} */
Description;
/** @type {number} */
Price;
/** @type {number} */
AvailableQty;
}
export class InventoryDetailByLocation {
/** @param {{SaqPk?:number,LocationInfo?:LocationInfo,Serials?:InventoryDetailBySerial[],Substitutes?:InventoryDetailSubstitute[],Retail?:number,OurPrice?:number,SalePrice?:number,SaleInfo?:string,PriceA?:number,PriceB?:number,PriceC?:number,MinPrice?:number,ActiveEPrice?:number,CustomerPrice?:number,AllowPriceChange?:boolean,Qty?:number,QtyAvail?:number,ActiveeHoldbackQty?:number,ReorderMin?:number,ReorderMax?:number,AverageCost?:number,WeightedCost?:number,Locator?:string,SelectionCode?:string,SelectionCodeDescription?:string,Spiff?:number,CurrentSpotCheckQty?:number,QtyOut?:number,QtyOnOrder?:number,AvailableForSTR?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
SaqPk;
/** @type {LocationInfo} */
LocationInfo;
/** @type {InventoryDetailBySerial[]} */
Serials;
/** @type {InventoryDetailSubstitute[]} */
Substitutes;
/** @type {number} */
Retail;
/** @type {number} */
OurPrice;
/** @type {?number} */
SalePrice;
/** @type {string} */
SaleInfo;
/** @type {number} */
PriceA;
/** @type {number} */
PriceB;
/** @type {number} */
PriceC;
/** @type {number} */
MinPrice;
/** @type {number} */
ActiveEPrice;
/** @type {number} */
CustomerPrice;
/** @type {boolean} */
AllowPriceChange;
/** @type {number} */
Qty;
/** @type {number} */
QtyAvail;
/** @type {number} */
ActiveeHoldbackQty;
/** @type {number} */
ReorderMin;
/** @type {number} */
ReorderMax;
/** @type {?number} */
AverageCost;
/** @type {?number} */
WeightedCost;
/** @type {string} */
Locator;
/** @type {string} */
SelectionCode;
/** @type {string} */
SelectionCodeDescription;
/** @type {number} */
Spiff;
/** @type {?number} */
CurrentSpotCheckQty;
/** @type {number} */
QtyOut;
/** @type {number} */
QtyOnOrder;
/** @type {number} */
AvailableForSTR;
}
export class InventoryDetailByVariant {
/** @param {{SkuPk?:number,Sku?:string,VendorCost?:number,VendorName?:string,Attributes?:InventoryDetailAttribute[],LocationDetails?:InventoryDetailByLocation[],Images?:ImageInfo[],HasImages?:boolean,Barcodes?:string[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
SkuPk;
/** @type {string} */
Sku;
/** @type {?number} */
VendorCost;
/** @type {string} */
VendorName;
/** @type {InventoryDetailAttribute[]} */
Attributes;
/** @type {InventoryDetailByLocation[]} */
LocationDetails;
/** @type {ImageInfo[]} */
Images;
/** @type {boolean} */
HasImages;
/** @type {string[]} */
Barcodes;
}
export class AddOnDetail {
/** @param {{SadPk?:number,SkuPk?:number,CatPk?:number,SubPk?:number,Item?:string,Description?:string,Price?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {number} */
SadPk;
/** @type {number} */
SkuPk;
/** @type {number} */
CatPk;
/** @type {number} */
SubPk;
/** @type {string} */
Item;
/** @type {string} */
Description;
/** @type {number} */
Price;
}
export class ActiveEInfo {
/** @param {{Dimension?:string,WebDescription?:string,Summary?:string,SETitle?:string,SEDescription?:string,SEKeywords?:string,SEAltText?:string,SEHtmlFreeText?:string,Unpublished?:boolean,FreeShipping?:boolean,IsFeatured?:boolean,WebCategoryIds?:number[]}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
Dimension;
/** @type {string} */
WebDescription;
/** @type {string} */
Summary;
/** @type {string} */
SETitle;
/** @type {string} */
SEDescription;
/** @type {string} */
SEKeywords;
/** @type {string} */
SEAltText;
/** @type {string} */
SEHtmlFreeText;
/** @type {boolean} */
Unpublished;
/** @type {boolean} */
FreeShipping;
/** @type {boolean} */
IsFeatured;
/** @type {number[]} */
WebCategoryIds;
}
export class InventoryDetailResponse extends BaseResponse {
/** @param {{SadPk?:number,InvType?:string,Model?:string,Description?:string,Mfg?:string,Category?:number,CategoryDescription?:string,SubCategory?:number,SubCategoryDescription?:string,SelectionCode?:string,SelectionCodeDescription?:string,SellSerialsOnline?:boolean,Notes?:string,Images?:ImageInfo[],HasImages?:boolean,VariantDetails?:InventoryDetailByVariant[],AddOns?:AddOnDetail[],ActiveEInfo?:ActiveEInfo,Weight?:number,Unit?:string,ShipCharge?:number,Status?:BaseResponseResult}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {number} */
SadPk;
/** @type {string} */
InvType;
/** @type {string} */
Model;
/** @type {string} */
Description;
/** @type {string} */
Mfg;
/** @type {number} */
Category;
/** @type {string} */
CategoryDescription;
/** @type {number} */
SubCategory;
/** @type {string} */
SubCategoryDescription;
/** @type {string} */
SelectionCode;
/** @type {string} */
SelectionCodeDescription;
/** @type {boolean} */
SellSerialsOnline;
/** @type {string} */
Notes;
/** @type {ImageInfo[]} */
Images;
/** @type {boolean} */
HasImages;
/** @type {InventoryDetailByVariant[]} */
VariantDetails;
/** @type {AddOnDetail[]} */
AddOns;
/** @type {ActiveEInfo} */
ActiveEInfo;
/** @type {number} */
Weight;
/** @type {string} */
Unit;
/** @type {number} */
ShipCharge;
}
export class InventoryHistoryResponse extends BaseResponse {
/** @param {{HistoryRecords?:InventoryHistoryObj[],InventoryDetail?:InventoryDetailResponse,Status?:BaseResponseResult}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {InventoryHistoryObj[]} */
HistoryRecords;
/** @type {InventoryDetailResponse} */
InventoryDetail;
}
export class InventoryHistoryRequest extends BaseSecureRequest {
/** @param {{LocId?:number,Item?:string,Token?:string,DeviceId?:string,AppId?:string,ApiKey?:string,OAuthToken?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {?number} */
LocId;
/** @type {string} */
Item;
}
JavaScript InventoryHistoryRequest 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/InventoryHistory HTTP/1.1 Host: active-ewebservice.biz Accept: application/json
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"HistoryRecords":[{"Acct":0,"Sub":0,"CusName":"String","Qty":0,"Amt":0,"Ref":"String","Type":"String","Serial":"String","Employee":"String","EmployeeName":"String","Stloc":"String","Dunn":"String","SoldDesc":"String","Tcp_rtncode":"String","TableName":"String","TraPk":0,"CusPk":0,"SasPk":0,"SaqPk":0,"SkuPk":0,"SadPk":0,"TablePk":0,"Description":"String"}],"InventoryDetail":{"SadPk":0,"InvType":"String","Model":"String","Description":"String","Mfg":"String","Category":0,"CategoryDescription":"String","SubCategory":0,"SubCategoryDescription":"String","SelectionCode":"String","SelectionCodeDescription":"String","SellSerialsOnline":false,"Notes":"String","Images":[{"Url":"String","ImageStream":"String","ImageSize":"String","ErrorMessage":"String","UriPk":0}],"HasImages":true,"VariantDetails":[{}],"AddOns":[{}],"ActiveEInfo":{"Dimension":"String","WebDescription":"String","Summary":"String","SETitle":"String","SEDescription":"String","SEKeywords":"String","SEAltText":"String","SEHtmlFreeText":"String","Unpublished":false,"FreeShipping":false,"IsFeatured":false,"WebCategoryIds":[0]},"Weight":0,"Unit":"String","ShipCharge":0,"Status":{"StatusCode":"String","Login":"String","ErrorCode":"String","ErrorDisplayText":"String","ErrorMessage":"String","DomainName":"String","IpAddress":"String"}},"Status":{"StatusCode":"String","Login":"String","ErrorCode":"String","ErrorDisplayText":"String","ErrorMessage":"String","DomainName":"String","IpAddress":"String"}}