/hosekits/export 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:
Hose Kits
postHoseKitsExport
Code samples
const inputBody = '{
"type": "object",
"properties": {
"hoseKits": {
"type": "array",
"description": "Array of hose kit IDs to export",
"items": {
"type": "string",
"format": "objectId"
}
},
"selectAll": {
"type": "boolean",
"description": "If true, exports all hose kits matching the search criteria"
},
"search": {
"type": "object",
"description": "Optional search filters",
"properties": {
"partNumberWithRevision": {
"type": "string"
},
"customerName": {
"type": "string"
},
"customerPartNumberWithRevision": {
"type": "string"
},
"description": {
"type": "string"
},
"status": {
"type": "string"
},
"commonSearch": {
"type": "string"
}
}
}
}
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'Authorization':{
"type": "string"
}
};
fetch('https://goldleaf.app/api/v1/hosekits/export',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
POST /hosekits/export
Export selected hose kits
Exports selected hose kits or all matching hose kits based on search criteria into an Excel or CSV format.
Body parameter
{
"type": "object",
"properties": {
"hoseKits": {
"type": "array",
"description": "Array of hose kit IDs to export",
"items": {
"type": "string",
"format": "objectId"
}
},
"selectAll": {
"type": "boolean",
"description": "If true, exports all hose kits matching the search criteria"
},
"search": {
"type": "object",
"description": "Optional search filters",
"properties": {
"partNumberWithRevision": {
"type": "string"
},
"customerName": {
"type": "string"
},
"customerPartNumberWithRevision": {
"type": "string"
},
"description": {
"type": "string"
},
"status": {
"type": "string"
},
"commonSearch": {
"type": "string"
}
}
}
}
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Authorization | header | string | true | Bearer token for authentication |
| body | body | object | true | none |
| » hoseKits | body | [string] | false | Array of hose kit IDs to export |
| » selectAll | body | boolean | false | If true, exports all hose kits matching the search criteria |
| » search | body | object | false | Optional search filters |
| »» partNumberWithRevision | body | string | false | none |
| »» customerName | body | string | false | none |
| »» customerPartNumberWithRevision | body | string | false | none |
| »» description | body | string | false | none |
| »» status | body | string | false | none |
| »» commonSearch | body | string | false | none |
Example responses
400 Response
{
"type": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Successfully exported hose kits | None |
| 400 | Bad Request | No hose Kits specified | string |
| 500 | Internal Server Error | Server error. | string |
