Returns a list of materials.
Material List
| Parameter | Mandatory | Description | Examples | More Info |
|---|---|---|---|---|
| API | Yes | The API area | tspending.json | |
| General | Yes | Parameters described in overview | see overview | Structure of an API call |
| Company | Yes | The company number | company=1 | |
| Action | Yes | The action to perform | action=materiallist |
Example request (OAuth 2.0):
Authorization: Bearer <access_token>
http://<SERVER>/jsonapi/tspending.json?&version=6&action=materiallist&company=1
Example request (legacy username/password):
http://<SERVER>/jsonapi/tspending.json?&version=6&action=materiallist&company=1&user=<username>&password=<password>
Example response:
{
"responsecode": 1,
"responsestatus": "OK",
"errorcode": 0,
"errormessage": "",
"totalrows": 24,
"totalpages": 12,
"responsemessage": "",
"pagerows": 2,
"pagenumber": 1,
"success": true,
"data": [
{
"resourcesUuid": "D941A8DA9E434014A56672D1F00191F5",
"resourcesTimestampModified": 1458225526,
"resourcesRecordVersionNumber": 3,
"resourcesCode": "1/4DEC",
"resourcesName": "4 decimals"
},
{
"resourcesUuid": "977C27066AA74A5A8B43BE9D6EB9DF09",
"resourcesTimestampModified": 1458225575,
"resourcesRecordVersionNumber": 3,
"resourcesCode": "1/A2CC",
"resourcesName": "A2 black and white "
}
]
}