{"info":{"_postman_id":"2674538f-91f2-4473-b757-0ca9a4832193","name":"Cyberpuerta Provider API - Light","description":"<html><head></head><body><p>This guide outlines different forms of interaction via API between Cyberpuerta and our Providers. Our goal is to automate the information exchange regarding the available product catalog and the transaction execution as much as reasonably possible.</p>\n<p>We implemented the <strong>Cyberpuerta Provider API</strong> in order to enable our Providers to automate most of their interactions with our ERP. The Provider requests, Cyberpuerta responds.</p>\n<p>Whenever Cyberpuerta needs to interact with the Provider, there are always two options: We either send an automated email (default option) or we utilize any API implemented <strong>by the Provider</strong>. This document outlines generic minimum requirements for common API use cases. Cyberpuerta requests, the Provider responds <strong>(Cyberpuerta-initiated)</strong>.</p>\n<p>Only the full catalog update (see <em>Catalog Update / Update full catalog</em>) is mandatory. The remaining items are optional but implementation is desired</p>\n<h1 id=\"authentication\">Authentication</h1>\n<p>Each request is validated using a <strong>bearer token</strong>. In order to authenticate the client who makes the request, the bearer token must be included on the request header.</p>\n<h1 id=\"considerations\">Considerations</h1>\n<p>To ensure system availability, a throttle limit has been set at a maximum of 60 requests per minute.</p>\n<h2 id=\"http-response-status-codes\">HTTP Response status codes</h2>\n<p>We use standard HTTP status codes to indicate if a request was successful or not.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Code</th>\n<th>Meaning</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>2xx</td>\n<td>The 2xx (Successful) class of status code indicates that the client's request was successfully received, understood, and accepted.</td>\n</tr>\n<tr>\n<td>4xx</td>\n<td>The 4xx (Client Error) class of status code indicates that the client seems to have erred.  Except when responding to a HEAD request, the server SHOULD send a representation containing an explanation of the error situation, and whether it is a temporary or permanent condition. These status codes are applicable to any request method. User agents SHOULD display any included representation to the user.</td>\n</tr>\n</tbody>\n</table>\n</div><p>For further information on HTTP status codes, please refer to <a href=\"https://tools.ietf.org/html/rfc7231#page-47\">RFC 7231</a></p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"Authentication","slug":"authentication"},{"content":"Considerations","slug":"considerations"}],"owner":"11388161","collectionId":"2674538f-91f2-4473-b757-0ca9a4832193","publishedId":"SzzobFta","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2020-06-22T16:47:31.000Z"},"item":[{"name":"Catalog update","item":[{"name":"Update full catalog","id":"337616f6-8bb5-4bba-8128-13a68b2ce613","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Accept","type":"text","value":"application/json"},{"key":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":"[\r\n    {\r\n        \"sku\": \"00001\",\r\n        \"manufacturer_sku\": \"DFG990-01\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": 9999999999999,\r\n        \"upc\": 888888888888,\r\n        \"asin\": \"B0006GQ8RW\",\r\n        \"title\": \"The product title\",\r\n        \"description\": \"The product description\",\r\n        \"currency\": \"MXN\",\r\n        \"price\": 3999,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 9\r\n            },\r\n            \"2\": {\r\n                \"stock\": 2\r\n            }\r\n        }\r\n    },\r\n    {\r\n        \"sku\": \"00002\",\r\n        \"manufacturer_sku\": \"DFG990-02\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": \"9999999999999\",\r\n        \"title\": \"The product title 2\",\r\n        \"description\": \"The product description 2\",\r\n        \"currency\": \"MXN\",\r\n        \"price\": 1299,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 10\r\n            },\r\n            \"2\": {\r\n                \"stock\": 3\r\n            }\r\n        }\r\n    },\r\n    {\r\n        \"sku\": \"00003\",\r\n        \"manufacturer_sku\": \"DFG990-03\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": \"9999999999999\",\r\n        \"title\": \"The product title 3\",\r\n        \"description\": \"The product description 3\",\r\n        \"currency\": \"MXN\",\r\n        \"price\": 788,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 11\r\n            },\r\n            \"2\": {\r\n                \"stock\": 4\r\n            }\r\n        }\r\n    } \r\n]"},"url":"https://domain.com/api/provider/articles/full-catalog","description":"<p>With this endpoint, the Provider can upload its entire products catalog. This feed will be taken by our system to make a bulk update of all the Provider's articles.</p>\n<p>It is recommended to update the full catalog once per hour. The submission of the full catalog update needs to be a fully automated process and submission frequency will be strictly monitored.</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>sku</strong></td>\n<td>string</td>\n<td>The Provider SKU.</td>\n</tr>\n<tr>\n<td><strong>manufacturer_sku</strong></td>\n<td>string</td>\n<td>The product BRAND SKU.</td>\n</tr>\n<tr>\n<td><strong>manufacturer</strong></td>\n<td>string</td>\n<td>The brand name.</td>\n</tr>\n<tr>\n<td>*<strong>ean</strong></td>\n<td>int</td>\n<td>International Article Number (13 digits).</td>\n</tr>\n<tr>\n<td>*<strong>upc</strong></td>\n<td>int</td>\n<td>Universal Product Code (12 digits).</td>\n</tr>\n<tr>\n<td>*<strong>asin</strong></td>\n<td>string</td>\n<td>Amazon Standard Identification Number (10 characters).</td>\n</tr>\n<tr>\n<td><strong>title</strong></td>\n<td>string</td>\n<td>The product title.</td>\n</tr>\n<tr>\n<td>*<strong>description</strong></td>\n<td>string</td>\n<td>The product description.</td>\n</tr>\n<tr>\n<td><strong>currency</strong></td>\n<td>string</td>\n<td>The price currency, allowed values are <em>USD</em> or <em>MXN</em>.</td>\n</tr>\n<tr>\n<td><strong>price</strong></td>\n<td>float</td>\n<td>The product price before taxes.</td>\n</tr>\n<tr>\n<td><strong>warehouses</strong></td>\n<td>json</td>\n<td>The provider locations, each one with their own stock described below.</td>\n</tr>\n</tbody>\n</table>\n</div><h5 id=\"warehouse-stock\">Warehouse stock</h5>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>id</strong></td>\n<td>string</td>\n<td>Identifier of the location as the key of the given warehouse.</td>\n</tr>\n<tr>\n<td><strong>id-&gt;stock</strong></td>\n<td>integer</td>\n<td>The stock in this location.</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>message</strong></td>\n<td>string</td>\n<td>A message that notifies if the products were uploaded or not.</td>\n</tr>\n</tbody>\n</table>\n</div><p>*These fields are completely optional but it is recommended that they are filled. The description should be short and must contain only the keypoints of the product.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"fooTokenBar=="}]},"isInherited":true,"source":{"_postman_id":"2674538f-91f2-4473-b757-0ca9a4832193","id":"2674538f-91f2-4473-b757-0ca9a4832193","name":"Cyberpuerta Provider API - Light","type":"collection"}},"urlObject":{"path":["api","provider","articles","full-catalog"],"host":["https://domain.com"],"query":[],"variable":[]}},"response":[{"id":"1810e3a5-7aa7-4237-9bec-a6f1b986d28b","name":"Update full catalog","originalRequest":{"method":"POST","header":[{"key":"Accept","type":"text","value":"application/json"},{"key":"Content-Type","value":"application/json","type":"text"},{"key":"Authorization","name":"Content-Type","type":"text","value":"Bearer fooTokenBar=="}],"body":{"mode":"raw","raw":"[\r\n    {\r\n        \"sku\": \"00001\",\r\n        \"manufacturer_sku\": \"DFG990-01\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": 9999999999999,\r\n        \"upc\": 888888888888,\r\n        \"asin\": \"B0006GQ8RW\",\r\n        \"title\": \"The product title\",\r\n        \"description\": null,\r\n        \"currency\": \"MXN\",\r\n        \"price\": 3999,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 9\r\n            },\r\n            \"2\": {\r\n                \"stock\": 2\r\n            }\r\n        }\r\n    },\r\n    {\r\n        \"sku\": \"00002\",\r\n        \"manufacturer_sku\": \"DFG990-02\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": null,\r\n        \"title\": \"The product title 2\",\r\n        \"description\": \"The product description 2\",\r\n        \"currency\": \"MXN\",\r\n        \"price\": 1299,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 10\r\n            },\r\n            \"2\": {\r\n                \"stock\": 3\r\n            }\r\n        }\r\n    },\r\n    {\r\n        \"sku\": \"00003\",\r\n        \"manufacturer_sku\": \"DFG990-03\",\r\n        \"manufacturer\": \"BRAND\",\r\n        \"ean\": 9999999999999,\r\n        \"title\": \"The product title 3\",\r\n        \"description\": \"The product description 3\",\r\n        \"currency\": \"MXN\",\r\n        \"price\": 788,\r\n        \"warehouses\": {\r\n            \"1\": {\r\n                \"stock\": 11\r\n            },\r\n            \"2\": {\r\n                \"stock\": 4\r\n            }\r\n        }\r\n    }\r\n]","options":{"raw":{"language":"json"}}},"url":"https://domain.com/api/provider/articles/full-catalog"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":null,"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"Products uploaded successfully!\"\n}"}],"_postman_id":"337616f6-8bb5-4bba-8128-13a68b2ce613"}],"id":"0b46a12e-5511-44de-b64b-6144a9f70e0c","description":"<p>These endpoints will be used by the Providers who do not have a web service implemented and want an alternative to upload their articles. By making a request they will update their products, either one or the full catalog, ensuring that Cyberpuerta always has the latest information regarding price and stock.</p>\n","_postman_id":"0b46a12e-5511-44de-b64b-6144a9f70e0c","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"fooTokenBar=="}]},"isInherited":true,"source":{"_postman_id":"2674538f-91f2-4473-b757-0ca9a4832193","id":"2674538f-91f2-4473-b757-0ca9a4832193","name":"Cyberpuerta Provider API - Light","type":"collection"}}}],"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"fooTokenBar=="}]}},"event":[{"listen":"prerequest","script":{"id":"96653927-32d1-4f51-9049-4522579b1265","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"ba001c4d-62b9-46b2-a006-5fafca610029","type":"text/javascript","exec":[""]}}],"variable":[{"key":"token","value":"fooTokenBar=="},{"key":"host","value":"https://domain.com"}]}