Relationships
Property
Type
Contract
Description
The include query parameter
Example request and response
Response
{
"data": [
{
"id": "babcf91e-5930-4b90-b929-0fb2b076bd3b",
"type": "invoices",
"attributes": {
"cancelled": false,
"cancelReason": null,
"description": null,
"createdAt": "2018-07-26T07:35:07.817Z",
"updatedAt": "2018-07-26T07:35:07.836Z",
"discount": null,
"tax": "0.00",
"total": "10.00",
"subtotal": "10.00",
"discountAmount": null,
"itemDiscountAmount": null,
"tipAmount": null
},
"relationships": {
"user": {
"data": {
"id": "918a47d1-6553-42ee-8de4-3b5af5edc8e7",
"type": "users"
}
},
"register": {
"data": {
"id": "f35693cb-cc0c-4c6f-bf16-eb0547444642",
"type": "registers"
}
},
"invoiceItems": {
"data": [
{
"id": "7d87444b-807a-4ea4-8b69-b0e91f5fa174",
"type": "invoiceItems"
}
]
}
}
}
],
"included": [
{
"id": "7d87444b-807a-4ea4-8b69-b0e91f5fa174",
"type": "invoiceItems",
"attributes": {
"productName": "liebe",
"quantity": "2.0",
"unitPriceInclTax": "5.00",
"subtotal": "10.00",
"tax": "0.00",
"total": "10.00",
"discount": null
},
"relationships": {
"product": {
"data": {
"id": "139a7f7a-591f-4797-ba23-08c9bee0d044",
"type": "products"
}
},
"productVariant": {
"data": null
},
"invoiceItemModifiers": {
"data": []
}
}
},
{
"id": "918a47d1-6553-42ee-8de4-3b5af5edc8e7",
"type": "users",
"attributes": {
"name": "John Smith"
}
},
{
"id": "f35693cb-cc0c-4c6f-bf16-eb0547444642",
"type": "registers",
"attributes": {
"name": "Register #1",
"invoicesCount": 1325,
"index": 1,
"virtual": false,
"createdAt": "2018-07-12T13:18:04.306Z",
"updatedAt": "2020-02-04T14:51:20.730Z"
},
"relationships": {
"outlet": {
"data": {
"id": "65e8856a-8bab-46d2-85e2-2cde89f40f95",
"type": "outlets"
}
}
},
"links": {
"self": "[PlatformAddress]/v1/registers/f35693cb-cc0c-4c6f-bf16-eb0547444642"
}
}
],
"links": {
"prev": "[PlatformAddress]/v1/invoices?page[before]=OTMzMw&page[size]=1",
"next": "[PlatformAddress]/v1/invoices?page[after]=OTMzMw&page[size]=1"
}
}Last updated
Was this helpful?