Expenses > Mileage
Reads all Mileages
Changed onReads all Mileages
get/api/2026-10-01/resources/expenses/mileages
Request
- Base URLhttps://api.factorialhr.com
- URLhttps://api.factorialhr.com/api/2026-10-01/resources/expenses/mileages
- Auth
- OAuth 2Authorization code: https://id.factorialhr.com/oauth/authorizeToken URL: https://id.factorialhr.com/api/oauth/token scopes: expenses
- or API key in header x-api-key
Query parameters
ids[]string[]
Return only the mileage records with these ids.
[ "1" ]
expenses_expensable_ids[]string[]
Return only the mileage records attached to these expensables. A mileage record is the detail record of an expensable, so this is the usual way to reach it from the header.
[ "1" ]
include_manual_draftsboolean required
employee_ids[]string[]
Return only the mileage records of these employees.
[ "1" ]
external_authorization_ids[]string[]
card_ids[]string[]
Return only the mileage records paid with these cards.
[ "1" ]
card_payment_ids[]string[]
Return only the mileage records raised from these card payments.
[ "1" ]
include_attachmentsboolean required
fromstring
Start of the window of travel dates (effective_on) to return, inclusive. It only takes effect together with to: given on its own it is ignored.
Example:2024-01-01T00:00:00Z
tostring
End of the window of travel dates (effective_on) to return, exclusive. It only takes effect together with from.
Example:2024-02-01T00:00:00Z
dispute_ids[]string[]
Return only the mileage records under these payment disputes.
[ "1" ]
Response
OK
Example response
{
"data": [
{
"id": "1",
"employee_id": "1",
"company_id": "1",
"expenses_expensable_id": "1",
"subcategory": "client_visit",
"category_id": "1",
"amount": 1000,
"currency": "EUR",
"reimbursable_amount": 250,
"reimbursable_currency": "USD",
"status": "approved",
"mileage": 100,
"units": "km",
"rate_measurement_unit": "mi",
"from": "Madrid",
"to": "Barcelona",
"description": "Client meeting",
"effective_on": "2024-06-06T12:00:00.000Z",
"review_request_at": "2024-06-06T12:00:00.000Z",
"paid_at": "2024-06-06T12:00:00.000Z",
"payment": "reimbursable",
"ledger_account_id": "1",
"round_trip": true,
"calculated_mileage": 62700,
"budget_id": "2",
"project_id": "3",
"cost_center_ids": [
"4",
"5"
]
}
]
}Changes
- info
endpoint added
- info