API Operations can be performed from Developer portal and client applications with few prerequisites and authentication process.
The APIs can be consumed by following the steps mentioned below.
Westcon API’s can be accessed by authorized client applications only.
The Westcon support team will register the application and provide the client credentials through which client would get an access token to consume the API’s.
Post
https://login.microsoftonline.com/ec8933c6-cfb2-4dd9-bfc9-621cde1dea8f/oauth2/token
x-www-form-urlencoded
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
client_credentials
e46124f9-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Sample Response:
{ "token_type": "Bearer", "expires_in": "3600", "ext_expires_in": "3600", "expires_on": "1562587331", "not_before": "1562583431", "resource": "e46124f9-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "access_token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...xxxxxxxxxxxxxx" }
Post
https://api.westconcomstor.com/Orders/orderStatus
This values should be a Bearer token which we received from Microsoft Login
Developer can find this Subscription Key in Profile
application/json
{ "mT_OrderStatus_API_REQ": { "partnerKey": "0****************3", "orderType": "W", "language": "EN", "order":[ "6****4", "6****9" ] } }
Sample Response:
{ "MT_OrderStatus_Response": [{ "eRPOrderNumber": "0********4", "eRPOrderLineNumber": "0****0", "customerOrderNumber": "Rb****-03", "customerLineNumber": "", "eRPProductNumber": "T****3", "lineQuantity": " 2.000", "unitOfMeasure": "EA", "lineStatusCode": "INV", "lineStatusDescription": "Invoiced", "statusDate": "yyyymmdd", "shipDate": "yyyymmdd", "billingDocument": "0*******7", "parentERPLine": "0****0" }, { "eRPOrderNumber": "0********4", "eRPOrderLineNumber": "0****0", "customerOrderNumber": "Rb****03", "customerLineNumber": "", "eRPProductNumber": "T****3", "lineQuantity": " 2.000", "unitOfMeasure": "EA", "lineStatusCode": "INV", "lineStatusDescription": "Invoiced", "statusDate": "yyyymmdd", "shipDate": "yyyymmdd", "billingDocument": "0*******7", "parentERPLine": "0****0" }, { "eRPOrderNumber": "0********9", "eRPOrderLineNumber": "000010", "customerOrderNumber": "VC REGULAR MFR SN", "customerLineNumber": "", "eRPProductNumber": "U************U", "lineQuantity": " 1.000", "unitOfMeasure": "EA", "lineStatusCode": "SHI", "lineStatusDescription": "Shipped", "statusDate": "yyyymmdd", "shipDate": "yyyymmdd", "billingDocument": "", "parentERPLine": "0****0" }, { "eRPOrderNumber": "0********9", "eRPOrderLineNumber": "000020", "customerOrderNumber": "VC REGULAR MFR SN", "customerLineNumber": "", "eRPProductNumber": "C***********T", "lineQuantity": " 2.000", "unitOfMeasure": "EA", "lineStatusCode": "SHI", "lineStatusDescription": "Shipped", "statusDate": "yyyymmdd", "shipDate": "yyyymmdd", "billingDocument": "", "parentERPLine": "0****0" } ] }
Please click here to download the Source code.
< add key="client_id" value="3a****48-2**7-4**f-b**8-1****5d****9" />
< add key="client_secret" value="GpR****B.z****X.*5:J****3IR****nR" />
< add key="resource" value="e4****f9-b**f-4**7-a**b-e****e6****4" />
< add key="subscriptionKey" value="bb****************************68" />
W: Westcon Order Number. Type in W, if you have the Westcon Order Number.
C: Customer Order Number. Type in C, if you have your own Customer Order Number.