/organization/items 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:
Item
getOrganizationItems
Code samples
const headers = {
Accept: "application/json",
};
fetch("https://goldleaf.app/api/v1/organization/items", {
method: "GET",
headers: headers,
})
.then(function (res) {
return res.json();
})
.then(function (body) {
console.log(body);
});
GET /organization/items
Get organization items
Retrieves items accessible to the organization. Supports filtering by part number, skipping certain item types, sorting, and pagination. These items appear in item assemblies setup.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| search.partNumber | query | string | false | Filter items by part number |
| skipItemTypes | query | array[string] | false | List of item types to exclude (e.g., ['hose', 'adaptor']) |
| page | query | integer | false | Page number for pagination |
| limit | query | integer | false | Number of items per page |
Example responses
500 Response
{
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"image": {
"type": "string",
"nullable": true
}
}
}
},
"total": {
"type": "integer"
}
}
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | A list of organization items | None |
| 500 | Internal Server Error | Default empty response | Inline |
Response Schema
Status Code 500
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| » items | [object] | false | none | none |
| »» name | string | false | none | none |
| »» image | string¦null | false | none | none |
| » total | integer | false | none | none |
