/pricelists/import v1.0.0
Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.
Base URLs:
Price Lists
postPriceListImports
Code samples
const inputBody = '{
"type": "object",
"properties": {
"file": {
"type": "string",
"format": "binary",
"description": "Excel file containing price list data to import"
}
}
}';
const headers = {
'Content-Type':'multipart/form-data',
'Accept':'application/json'
};
fetch('https://goldleaf.app/api/v1/pricelists/import',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
POST /pricelists/import
Bulk import of price lists via Excel file
Imports price list properties in bulk through an uploaded Excel file. Requires admin role.
Body parameter
type: object
properties:
file:
type: string
format: binary
description: Excel file containing price list data to import
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | object | true | none |
| ยป file | body | string(binary) | false | Excel file containing price list data to import |
Example responses
500 Response
{
"type": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Price list updated successfully | None |
| 401 | Unauthorized | none | None |
| 500 | Internal Server Error | none | string |
