{ "total_amount": "860.00", "total_records": "10", "collection": [ { "id": 942, "description": "some trip to somewhere", "user_name": "John Smith", "state": "reviewing", "date": "2023-09-01", "cost_center_names": "Some Cost Center", "approved_by": "", "user_id": 34, "cost_center_ids": [42], "cost_center_external_ids": ["ABC01"], "sent_at": null, "created_by": "John Smith", "updated_at": "2023-09-04", "paid_at": null, "batch_reference_number": null, "vehicle_name": "Autolla", "passengers": 1, "total_cost": "86.00", "cost_per_unit": "0.43", "vehicle_category_unit": "km", "total_distance": 200.0, "debit_account_code": "7870" } ] }
Param name | Description |
---|---|
page
optional |
Page number. Validations:
|
per_page
optional |
Number of records per page. Default: 25. Validations:
|
q
optional |
Query to filter trips by description or amount, e.g.: “Helsinki”, “12.40”. Validations:
|
date_range
optional |
Date range to filter trips by. Format: “DD/MM/YYYY - DD/MM/YYYY”, e.g. “01/09/2023 - 04/09/2023”. Validations:
|
user_id
optional |
User ID to filter trips by. Validations:
|
cost_center_id
optional |
Cost center ID to filter trips by. Validations:
|
state
optional |
State to filter trips by. Validations:
|
updated_at_range
optional |
Date range when trips were last updated to filter by. Format: “DD/MM/YYYY - DD/MM/YYYY”, e.g. “01/09/2023 - 04/09/2023”. Validations:
|
sort
optional |
Parameter to sort trips by. Sorted by updated date in descending order by default. Validations:
|
order
optional |
Sort trips by sort param in ascending or descending order. Default: asc. Validations:
|
OK
Param name | Description |
---|---|
total_amount
required |
Total amount for trips matching filtering criteria, e.g. “415.90”. Validations:
|
total_records
required |
Total number of trips matching filtering criteria, e.g. “3”. Validations:
|
collection
required |
List of trips. Validations:
|