Billing Overview Relations API
General notes
Enumerators
ModelType:
This enumerator value is used in field model_type.
| Name | Type | Value |
|---|---|---|
CLIENT_CONTRACT_INVOICE | int | 1 |
CLIENT_HOSTING_INVOICE | int | 2 |
PROJECT | int | 3 |
Embeddable fields
| Name | Type | Description |
|---|---|---|
billings_overview | BillingsOverview | -- |
report | Report | Returns Report or null. |
Billings Overviews collection:
Single Billings Overview:
Billings Overview Relations collection
List of relations
GET /api/v0/users/billings-overview-relations
This method needs permission
accessonbillings-overviews.
| Index behaviour | Definition |
|---|---|
| Paginated by default | Yes |
| Sorting | id, name, model_type, model_id, price, date, billings_overview_id, responsible_person_id, responsible_person_name, note, client_id, client_name, past_deadline, past_deadline_notifed_at, invoice_number, report_id |
| Filters | id:enum, name:string, model_type:int, model_id:int, price:decimal, date:date, billings_overview_id:int, responsible_person_id:int, responsible_person_name:string, note:string, client_id:int, client_name:string, past_deadline:bool, past_deadline_notifed_at:date, invoice_number:string, report_id:int |
Request
GET /api/v0/billings-overview-relations HTTP/1.1
Responses
200 OK
{
"items": [
{
"id": 55,
"name": "athletebox.cz / právní dokumenty",
"model_type": "3",
"model_id": "2",
"price": {
"CZK": {
"value": 404,
"formatted": "404,00 Kč"
}
},
"date": "2024-02-02",
"billings_overview_id": 148,
"responsible_person_id": 1,
"responsible_person_name": "Aleš Bžatek",
"note": null,
"client_id": 3,
"client_name": "Nadační horka s.r.o.",
"past_deadline": false,
"past_deadline_notified_at": null,
"invoice_number": null,
"created_at": "2024-02-19T10:54:32+0100",
"updated_at": "2024-02-20T10:45:23+0100"
},
{
"id": 56,
"name": "athletebox.cz / aktualizace a servis",
"model_type": "3",
"model_id": "3",
"price": {
"CZK": {
"value": 3725,
"formatted": "3 725,00 Kč"
}
},
"date": "2024-02-01",
"billings_overview_id": 148,
"responsible_person_id": 1,
"responsible_person_name": "Aleš Bžatek",
"note": null,
"client_id": 3,
"client_name": "Nadační horka s.r.o.",
"past_deadline": false,
"past_deadline_notified_at": null,
"invoice_number": null,
"created_at": "2024-02-19T10:54:32+0100",
"updated_at": "2024-02-19T10:54:32+0100"
}
]
}
Single Billings Overview Relations
Get Billings Overview Relation
GET /api/v0/users/billings-overview-relations/{id}
This method needs permission
readonbillings-overviews.
| Index behaviour | Definition |
|---|---|
| Paginated by default | No |
Request
GET /api/v0/billings-overview-relations/55 HTTP/1.1
Responses
200 OK
{
"id": 55,
"name": "athletebox.cz / právní dokumenty",
"model_type": "3",
"model_id": "2",
"price": {
"CZK": {
"value": 404,
"formatted": "404,00 Kč"
}
},
"date": "2024-02-02",
"billings_overview_id": 148,
"responsible_person_id": 1,
"responsible_person_name": "Aleš Bžatek",
"note": null,
"client_id": 3,
"client_name": "Nadační horka s.r.o.",
"past_deadline": false,
"past_deadline_notified_at": null,
"invoice_number": null,
"created_at": "2024-02-19T10:54:32+0100",
"updated_at": "2024-02-20T10:45:23+0100"
}
Update Billings Overview Relation
PATCH /api/v0/users/billings-overview-relations/{id}
This method needs permission
updateonbillings-overviews.
Request
| Param | Type | Description | Requirements |
|---|---|---|---|
invoice_number | string | Invoice number | Required. |
PATCH /api/v0/billings-overview-relations/55 HTTP/1.1
{
"invoice_number": "2023/001231",
}
Responses
200 OK
{
"id": 55,
"name": "athletebox.cz / právní dokumenty",
"model_type": "3",
"model_id": "2",
"price": {
"CZK": {
"value": 404,
"formatted": "404,00 Kč"
}
},
"date": "2024-02-02",
"billings_overview_id": 148,
"responsible_person_id": 1,
"responsible_person_name": "Aleš Bžatek",
"note": null,
"client_id": 3,
"client_name": "Nadační horka s.r.o.",
"past_deadline": false,
"past_deadline_notified_at": null,
"invoice_number": "2023/001232",
"created_at": "2024-02-19T10:54:32+0100",
"updated_at": "2024-02-20T10:45:23+0100"
}