Download OpenAPI specification:Download
The Expenses API allows you to manage accounting and expenses information.
List expenses under the same account. Admin and bookkeeper have access to any expense, and regular users can only access their own.
expand[] | Array of strings or null Get additional details for the expense, e.g. merchant mcc code, by passing in Example: expand[]=
?expand[]=merchant&expand[]=location
|
user_id[] | Array of strings or null Get expenses belong to provided user(s). |
parent_expense_id[] | Array of strings or null Get itemized expenses belong to provided parent expenses ID(s). |
budget_id[] | Array of strings or null |
status[] | Array of strings or null (ExpenseStatus) Enum: "DRAFT" "SUBMITTED" "APPROVED" "OUT_OF_POLICY" "VOID" "CANCELED" "SPLIT" "SETTLED" |
payment_status[] | Array of strings or null (ExpensePaymentStatus) Enum: "NOT_STARTED" "PROCESSING" "CANCELED" "DECLINED" "CLEARED" "REFUNDING" "REFUNDED" "CASH_ADVANCE" "CREDITED" "AWAITING_PAYMENT" "SCHEDULED" |
purchased_at_start | string or null <date-time> Shows only expenses with a Example: purchased_at_start=
2023-01-01T23:59:59.999
|
purchased_at_end | string or null <date-time> Shows only expenses with a Example: purchased_at_end=
2023-01-10T23:59:59.999
|
load_custom_fields | boolean or null Load custom fields for the expenses. |
cursor | string or null The cursor to use for pagination. This is the |
limit | integer or null <int32> Controls the maximum number of expenses returned in the response, cant be greater than 1000. |
List expenses response.
Bad request
Unauthorized
Forbidden
{- "next_cursor": "string",
- "items": [
- {
- "id": "string",
- "memo": "string",
- "location_id": "string",
- "location": {
- "id": "string",
- "name": "string"
}, - "address": {
- "country": "Brazil",
- "state": "RJ",
- "city": "Rio de Janeiro",
- "postal_code": "21941-900",
- "line1": "Av. Vinte de Janeiro, S/N",
- "line2": "Ilha do Governador",
- "coordinates": {
- "latitude": -22.8145373,
- "longitude": -43.2465548
}, - "timezone": "America/Sao_Paulo"
}, - "department_id": "string",
- "department": {
- "id": "string",
- "name": "string"
}, - "updated_at": "2019-08-24T14:15:22Z",
- "payment_posted_at": "2019-08-24T14:15:22Z",
- "category": "ADVERTISING_AND_MARKETING",
- "merchant_id": "string",
- "merchant": {
- "raw_descriptor": "string",
- "mcc": "string",
- "country": "string"
}, - "receipts": [
- {
- "id": "string",
- "download_uris": [
- "string"
]
}
], - "budget_id": "string",
- "budget": {
- "id": "string",
- "name": "string"
}, - "expense_type": "CARD",
- "original_amount": {
- "amount": 0,
- "currency": "string"
}, - "billing_amount": {
- "amount": 0,
- "currency": "string"
}, - "budget_amount": {
- "amount": 0,
- "currency": "string"
}, - "purchased_at": "2019-08-24T14:15:22Z",
- "status": "DRAFT",
- "payment_status": "NOT_STARTED",
- "user_id": "string",
- "user": {
- "id": "string",
- "first_name": "string",
- "last_name": "string",
- "department_id": "string",
- "location_id": "string"
}, - "payment": {
- "id": "string",
- "paymentInstrument": {
- "type": "CARD",
- "id": "string"
}, - "statusReason": "OTHER"
}, - "custom_fields": [
- {
- "key": "string",
- "value": {
- "value_type": "SINGLE_VALUE",
- "data_type": "STRING",
- "data": "string"
}
}
], - "trip_id": "string"
}
]
}
Get an expense by its ID.
Get an expense response.
Bad request
Unauthorized
Forbidden
Not Found
{- "id": "string",
- "memo": "string",
- "location_id": "string",
- "location": {
- "id": "string",
- "name": "string"
}, - "address": {
- "country": "Brazil",
- "state": "RJ",
- "city": "Rio de Janeiro",
- "postal_code": "21941-900",
- "line1": "Av. Vinte de Janeiro, S/N",
- "line2": "Ilha do Governador",
- "coordinates": {
- "latitude": -22.8145373,
- "longitude": -43.2465548
}, - "timezone": "America/Sao_Paulo"
}, - "department_id": "string",
- "department": {
- "id": "string",
- "name": "string"
}, - "updated_at": "2019-08-24T14:15:22Z",
- "payment_posted_at": "2019-08-24T14:15:22Z",
- "category": "ADVERTISING_AND_MARKETING",
- "merchant_id": "string",
- "merchant": {
- "raw_descriptor": "string",
- "mcc": "string",
- "country": "string"
}, - "receipts": [
- {
- "id": "string",
- "download_uris": [
- "string"
]
}
], - "budget_id": "string",
- "budget": {
- "id": "string",
- "name": "string"
}, - "expense_type": "CARD",
- "original_amount": {
- "amount": 0,
- "currency": "string"
}, - "billing_amount": {
- "amount": 0,
- "currency": "string"
}, - "budget_amount": {
- "amount": 0,
- "currency": "string"
}, - "purchased_at": "2019-08-24T14:15:22Z",
- "status": "DRAFT",
- "payment_status": "NOT_STARTED",
- "user_id": "string",
- "user": {
- "id": "string",
- "first_name": "string",
- "last_name": "string",
- "department_id": "string",
- "location_id": "string"
}, - "payment": {
- "id": "string",
- "paymentInstrument": {
- "type": "CARD",
- "id": "string"
}, - "statusReason": "OTHER"
}, - "custom_fields": [
- {
- "key": "string",
- "value": {
- "value_type": "SINGLE_VALUE",
- "data_type": "STRING",
- "data": "string"
}
}
], - "trip_id": "string"
}
Update an expense. Admin and bookkeeper have access to any expense, and regular users can only access their own.
Update an expense response.
Bad request
Unauthorized
Forbidden
Not Found
{- "memo": "string"
}
{- "id": "string",
- "memo": "string",
- "location_id": "string",
- "department_id": "string",
- "updated_at": "2019-08-24T14:15:22Z",
- "category": "ADVERTISING_AND_MARKETING",
- "merchant_id": "string",
- "budget_id": "string",
- "original_amount": {
- "amount": 0,
- "currency": "string"
}, - "billing_amount": {
- "amount": 0,
- "currency": "string"
}, - "purchased_at": "2019-08-24T14:15:22Z",
- "status": "DRAFT",
- "payment_status": "NOT_STARTED"
}
The uri
will be a pre-signed S3 URL allowing you to upload the receipt securely. This URL can only be used for a PUT
operation and expires 30 minutes after its creation. Once your upload is complete, we will try to match the receipt with existing expenses.
Refer to these docs on how to upload to this pre-signed S3 URL. We highly recommend using one of AWS SDKs if they're available for your language to upload these files.
Create a new receipt match response.
Bad request
Unauthorized
{- "receipt_name": "string"
}
{- "id": "string",
- "uri": "string"
}
The uri
will be a pre-signed S3 URL allowing you to upload the receipt securely. This URL can only be used for a PUT
operation and expires 30 minutes after its creation. Once your upload is complete, we will try to match the receipt with existing expenses.
Refer to these docs on how to upload to this pre-signed S3 URL. We highly recommend using one of AWS SDKs if they're available for your language to upload these files.
Upload a new receipt response.
Bad request
Unauthorized
Forbidden
Not Found
{- "receipt_name": "string"
}
{- "id": "string",
- "uri": "string"
}