{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"4939fed4-ed26-4a19-b706-3c9aa3667376","name":"V.Alexander & Co. eAdaptor Proxy API","description":"The V. Alexander eAdaptor Proxy API enables vendors to create secure data integrations with our internal ERP system CargoWise One.\n\nUnlike traditional RESTful API, V. Alexander eAdaptor Proxy API only uses one single resource endpoint and POST method for all data retrieval, creation, update, and deletion. It is accepting only XML as request body instead of JSON.\n\n# Getting started\n\nTo get started, contact your V. Alexander IT team to obtain credentials and an API key. You will need the following information:\n\n1. The email address for the technical contact at your company.\n2. The IP address (or IP addresses) you will use to send requests to the API.\n    \n\n> **Note**: Access to the V. Alexander eAdaptor Proxy API is restricted to a list of allowed IP addresses. Please remember to make a note of the originating IP address so we can allow the new traffic.\n\n## Authentication and Authorization\n\nThe V. Alexander eAdaptor Proxy API uses OAuth 2.0 along with an API key for authentication and authorization. All applications follow a basic pattern when accessing a V.Alexander eAdaptor Proxy API using OAuth 2.0. At a high level, you follow these steps:\n\n1. Contact the V.Alexander IT team to obtain your access credentials if you don't have them before continuing.\n2. **Note:** Access tokens expire after 1 hour. Client credentials do not use refresh tokens, and you will need to re-authenticate when your token expires.\n3. Include the access token and API key with your request.  \n    After your application obtains an access token, it should send the token and API Key to the V. Alexander eAdaptor Proxy API in the HTTP request header.\n    - Set an `\"x-api-key\"` header with the value set to your API key.\n    - Set an `\"Authorization\"` header with the value set to your access token.\n\n## Scope\n\nV. Alexander eAdaptor Proxy API controls authenticated access to resource and method with scope. Currently, there is only one scope available for the API: \"eadaptor.write\". Client app may need to provide this scope when obtaining access token.\n\n## Import and Test API Collection Locally in Postman\n\nV. Alexander eAdaptor Proxy API Collection can be imported into your local Postman app for testing. You will need the Postman application to use this feature.\n\n1. From this documentation, click `Run in Postman` and select the workspace to import the collection into.\n2. Click on the `edit` option on the imported collection.\n3. Add the following script into the `Pre-request script` section and update the `clientId`, `clientSecret`, `apiKey`, and `tokenUrl` constants. You will have received these data points from V. Alexander as part of the setup process.\n    \n\n```\n// update this section\nconst clientId = 'your_client_id';\nconst clientSecret = 'your_client_secret';\nconst apiKey = \"your_api_key\";\nconst tokenUrl = 'token_url';\nconst domain = 'eadaptorproxy.valexanderapis.com';\nconst getTokenRequest = {\n  method: \"POST\",\n  url: tokenUrl,\n  body: {\n    mode: \"urlencoded\",\n    urlencoded: [\n      { key: \"client_id\", value: clientId },\n      { key: \"client_secret\", value: clientSecret },\n      { key: \"grant_type\", value: \"client_credentials\" },\n    ],\n  },\n};\npm.sendRequest(getTokenRequest, (err, response) => {\n  if (err) {\n    console.log(err);\n  }\n  const jsonResponse = response.json();\n  const newAccessToken = jsonResponse.access_token;\n  pm.environment.set(\"domain\", domain);\n  pm.environment.set(\"api_key\", apiKey);\n  pm.environment.set(\"access_token\", newAccessToken);\n});\n\n```\n\nAfter you save the script, Postman will automatically authenticate to the API, and you will able to make request to our API.\n\n# Support\n\nFor help regarding accessing the V. Alexander eAdaptor Proxy API, please contact V. Alexander IT. To help us address your request efficiently, please include the following:\n\n- A detailed description of the issue\n- The request you made, including the HTTP headers\n- The response you received from the API\n    \n\n### Troubleshooting\n\n#### `403 Forbidden`\n\nIf you receive a 403 response, check your IP address to ensure it is the same IP address we allowed during setup. Testing from behind a web VPN will change your IP address, and the API will block your request.\n\nIf receive a `5XX` error, it implies that we have hit an unexpected errors internally. Please kindly let us know.\n\n# API Reference\n\n---\n\n### 5XX Error responses\n\nDespite the V. Alexander eAdaptor Proxy API accepts and returns payload in form of XML, when the API encounters unexpected internal error, it returns response in form of JSON.\n\n#### Example\n\n```\n{\n    \"message\": \"Internal server error\"\n}\n\n```\n\nThis means before client tries to parse the response, it is recommended to check for the HTTP status first and determine if the response will be in form of XML or JSON.","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"12752850","team":92111,"collectionId":"4939fed4-ed26-4a19-b706-3c9aa3667376","publishedId":"2s8YsnYcEp","public":true,"publicUrl":"https://eadaptorproxy-documentation.valexanderapis.com","privateUrl":"https://go.postman.co/documentation/12752850-4939fed4-ed26-4a19-b706-3c9aa3667376","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"documentationLayout":"classic-double-column","customisation":null,"version":"8.10.1","publishDate":"2023-02-06T20:17:42.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{},"logos":{}},"statusCode":200},"environments":[],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://res.cloudinary.com/postman/image/upload/t_team_logo_pubdoc/v1/team/141cc0e9ab5152ea2d5a3c5bdafe7f9f71a57cf174fd5f60cf5f2b805f58f2e6","favicon":"https://res.cloudinary.com/postman/image/upload/v1557947504/team/zwkrg64rlk5u3gfx1tcq.ico"},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"}],"canonicalUrl":"https://eadaptorproxy-documentation.valexanderapis.com/view/metadata/2s8YsnYcEp"}