{ "opencollection": "1.0.0", "info": { "name": "YOOBIC Public Answers Stores API", "version": "1.0" }, "items": [ { "info": { "name": "Stores", "type": "folder" }, "items": [ { "info": { "name": "Get", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores/:id", "headers": [ { "name": "Accept", "value": "application/json" } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Get a store for the given id." }, { "info": { "name": "Partial Update", "type": "http" }, "http": { "method": "PATCH", "url": "https:///public/api/stores/:id", "headers": [ { "name": "Accept", "value": "application/json" } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Update a subset of properties of a store" }, { "info": { "name": "Health Score of a store API", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores/:id/health-score?days:days", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "days", "value": "7", "type": "query", "description": "The number of days back to calculate the healthscore (defaults to 7)" } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "An in house KPI to help measure a store's condition.\nThe Health Score is determined according to 4 criteria:\n\n- `reactivity`: Percentage of completed missions on time.\n\n- `accuracy`: Percentage of compliant missions.\n\n- `compliance`: Percentage of compliant campaigns. Campaign compliancy is set when the last mission on the store is compliant.\n\n- `review`: This concept aims to integrate audits completed by managers over the store in the Health Score\n\nThe final score is then given with two additio" }, { "info": { "name": "Archive", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores/:id/archive", "headers": [ { "name": "Accept", "value": "application/json" } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Archive a store" }, { "info": { "name": "Unarchive", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores/:id/unarchive", "headers": [ { "name": "Accept", "value": "application/json" } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Restore an archived store." }, { "info": { "name": "Get all", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores?filter=:filter", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "filter", "value": "{}", "type": "query", "description": "A valid JSON filter object" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Get all stores." }, { "info": { "name": "Get all archives", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores/archives?filter=:filter", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "filter", "value": "{}", "type": "query", "description": "A valid JSON filter object" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Get all archived stores. You can use the same filters as for the regular “Get all stores” method" }, { "info": { "name": "Count", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores/count?where=:where", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "where", "value": "{ \"property\": \"value\" }", "type": "query", "description": "A valid JSON [Where filter](#section-api-requests-filter-where)" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Count all the existing entities based on the where filter" }, { "info": { "name": "Create", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores", "headers": [ { "name": "Accept", "value": "application/json" } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "/", "accessTokenUrl": "/", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "You may create a new single store or multiple stores using this action. \nWhen creating a single store the body contains a json object, when creating multiple stores the body contains an array of objects. \n**Warning: a maximum of 1000 items can be sent in a single request.**" }, { "info": { "name": "Export archived stores", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores_archived/export?type=:type&filter=:filter", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "type", "value": "csv", "type": "path", "description": "The type of file, either `csv` (default value) or `excel`" }, { "name": "filter", "value": "{}", "type": "query", "description": "A valid JSON filter object (does not accept a `fields` filter)" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Export all results as a file. \nThis action is asynchronous and returns the id of a job. See [`jobs`](#group-jobs) endpoint to query the status of the job. The file will contain the results with all of the fields specified on the resource." }, { "info": { "name": "Import Stores To Archive", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores/archive/import?type=:type", "headers": [ { "name": "Content-Disposition", "value": "form-data; name=\"file\"; filename=\"file.csv\"" } ], "params": [ { "name": "type", "value": "csv", "type": "path", "description": "The type of file, either `csv` (default value) or `excel`" } ] }, "docs": "This method will archive all stores found from the imported file.\n\n### Fields\n\n| Field | Format | Required | Description |\n|--------------------------|---------|:--------:|-----------------|\n|`store_id` | string | x | Unique store id |\n|`client_id` | string | x | The external unique id of the store as it may exists in your Information System|\n\nOnly one of store_id or client_id is required" }, { "info": { "name": "Import Stores To Un Archive", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores/unarchive/import?type=:type", "headers": [ { "name": "Content-Disposition", "value": "form-data; name=\"file\"; filename=\"file.csv\"" } ], "params": [ { "name": "type", "value": "csv", "type": "path", "description": "The type of file, either `csv` (default value) or `excel`" } ] }, "docs": "This method will unarchive all stores found from the imported file.\n\n### Fields\n\n| Field | Format | Required | Description |\n|--------------------------|---------|:--------:|-----------------|\n|`store_id` | string | x | Unique store id |\n|`client_id` | string | x | The external unique id of the store as it may exists in your Information System|\n\nOnly one of store_id or client_id is required" }, { "info": { "name": "Export", "type": "http" }, "http": { "method": "GET", "url": "https:///public/api/stores/export?:filter&type=:type", "headers": [ { "name": "Accept", "value": "application/json" } ], "params": [ { "name": "type", "value": "csv", "type": "path", "description": "The type of file, either `csv` (default value) or `excel`" }, { "name": "filter", "value": "{}", "type": "query", "description": "A valid JSON filter object (does not accept a `fields` filter)" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Export all results as a file. \nThis action is asynchronous and returns the id of a job. See [`jobs`](#group-jobs) endpoint to query the status of the job. The file will contain the results with all of the fields specified on the resource." }, { "info": { "name": "Import", "type": "http" }, "http": { "method": "POST", "url": "https:///public/api/stores/import?type=:type", "headers": [ { "name": "Content-Disposition", "value": "form-data; name=\"file\"; filename=\"file.csv\"" } ], "params": [ { "name": "type", "value": "csv", "type": "path", "description": "The type of file, either `csv` (default value) or `excel`" } ] }, "docs": "See the [Import file section](#section-import-jobs) for more information.\n\n### Fields\n\n| Field | Format | Required | Description |\n|--------------------------|---------|:--------:|-----------------|\n|`store_id` | string | | Unique store id |\n|`title` | string | x | Name of the store|\n|`address` | string | x | The full address allows us to locate the store on the map. This is used to display the mi" } ] } ], "bundled": true }