For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Logo
Resources
Log inGet a demo
Get startedAPI referenceImplementation
Get startedAPI referenceImplementation
    • Overview
          • The ExpenseReport object
          • GET/expense-reports
          • POST/expense-reports
          • GET/expense-reports/{expense_report_id}/lines
          • GET/expense-reports/{id}
          • GET/expense-reports/lines/remote-field-classes
          • GET/expense-reports/meta/post
          • GET/expense-reports/remote-field-classes
UnifiedAgent HandlerGateway
UnifiedAgent HandlerGateway
Resources
Log inGet a demo
Common ModelsExpense Reports

/expense-reports/{id}

Beta
GET
/accounting/v1/expense-reports/:id
GET
/api/accounting/v1/expense-reports/:id
$curl -G https://api.merge.dev/api/accounting/v1/expense-reports/id \
> -H "X-Account-Token: X-Account-Token" \
> -H "Authorization: Bearer <token>" \
> --data-urlencode expand=lines,employee,accounting_period,company
200Retrieved
1{
2 "tracking_categories": [
3 "a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d",
4 "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"
5 ],
6 "id": "123e4567-e89b-12d3-a456-426614174000",
7 "remote_id": "exp_123e4567-e89b-12d3-a456-426614174000",
8 "created_at": "2024-01-31T12:00:00Z",
9 "modified_at": "2024-01-31T14:30:00Z",
10 "report_date": "2024-01-31T00:00:00Z",
11 "report_identifier": "EXP-2024-001",
12 "employee": "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1",
13 "status": "SUBMITTED",
14 "total_amount": 150,
15 "lines": [
16 {
17 "tracking_categories": [
18 "cat-1",
19 "cat-2"
20 ],
21 "id": "1234",
22 "remote_id": "abcd-1234",
23 "created_at": "2021-09-15T00:00:00Z",
24 "modified_at": "2021-10-16T00:00:00Z",
25 "account": "acc-1234",
26 "description": "Client lunch meeting",
27 "expense_date": "2024-01-15T00:00:00Z",
28 "amount": 50,
29 "currency": "USD",
30 "exchange_rate": "1",
31 "is_billable": true,
32 "employee": "emp-1234",
33 "project": "proj-5678",
34 "company": "comp-1234",
35 "contact": "cont-5678",
36 "quantity": 1,
37 "unit_price": 50,
38 "non_reimbursable": false,
39 "tax_amount": 5,
40 "inclusive_of_tax": false,
41 "tax_rate": "tax-1234",
42 "remote_was_deleted": false,
43 "integration_params": {
44 "unique_integration_field": "unique_integration_field_value"
45 },
46 "linked_account_params": {
47 "unique_linked_account_field": "unique_linked_account_field_value"
48 },
49 "field_mappings": {
50 "organization_defined_targets": {
51 "custom_key": "custom_value"
52 },
53 "linked_account_defined_targets": {
54 "custom_key": "custom_value"
55 }
56 }
57 }
58 ],
59 "currency": "USD",
60 "description": "January 2024 Travel Expenses",
61 "accounting_period": "7d793c67-9f72-4a6b-9256-3936f237b0d9",
62 "company": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
63 "remote_was_deleted": true,
64 "field_mappings": {
65 "organization_defined_targets": {
66 "custom_key": "custom_value"
67 },
68 "linked_account_defined_targets": {
69 "custom_key": "custom_value"
70 }
71 },
72 "remote_data": [
73 {
74 "path": "/actions",
75 "data": null
76 }
77 ],
78 "remote_fields": [
79 {
80 "remote_field_class": {
81 "id": "string",
82 "display_name": "string",
83 "remote_key_name": "string",
84 "description": "string",
85 "is_custom": true,
86 "is_common_model_field": true,
87 "is_required": true,
88 "field_type": "string",
89 "field_format": "string",
90 "field_choices": [
91 "string"
92 ],
93 "item_schema": {
94 "item_type": "string",
95 "item_format": "string",
96 "item_choices": [
97 "string"
98 ]
99 }
100 },
101 "value": "string"
102 }
103 ]
104}

Returns an ExpenseReport object with the given id.

Field support by integration

See all supported fields

Use the /linked-accounts endpoint to pull platform support information

Was this page helpful?
Previous

/expense-reports/{expense_report_id}/lines

Next

/expense-reports/lines/remote-field-classes

Built with

Authentication

AuthorizationBearer

Token-based authentication with required prefix “Bearer”

Path parameters

idstringRequiredformat: "uuid"

Headers

X-Account-TokenstringRequired
Token identifying the end user.

Query parameters

expandenumOptional
Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
include_remote_databooleanOptional

Whether to include the original data Merge fetched from the third-party to produce these models.

include_remote_fieldsbooleanOptional
Whether to include all remote fields, including fields that Merge did not map to common models, in a normalized format.
include_shell_databooleanOptional

Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).

Response

tracking_categorieslist of strings
The related tracking categories associated with the expense report
idstringRead-onlyformat: "uuid"
remote_idstring or null

The third-party API ID of the matching object.

created_atdatetimeRead-only
The datetime that this object was created by Merge.
modified_atdatetimeRead-only
The datetime that this object was modified by Merge.
report_datedatetime or null
The date of the expense report.
report_identifierstring or null<=1024 characters

Human-readable expense report identifier.

employeestring or nullformat: "uuid"
Identifier for the employee who submitted or is associated with the expense report
statusenum or null

Overall status of the expense report. One of DRAFT, SUBMITTED, APPROVED, REJECTED

  • DRAFT - DRAFT
  • SUBMITTED - SUBMITTED
  • APPROVED - APPROVED
  • REJECTED - REJECTED
Allowed values:
total_amountdouble or null
Total amount of the expense report
lineslist of objectsRead-only
currencyenum or null
Currency code for the expense report. The currency code in ISO 4217 format.
descriptionstring or null<=1024 characters
A brief description or purpose for the expense report
accounting_periodstring or nullformat: "uuid"
The accounting period the report was posted in
companystring or nullformat: "uuid"
The subsidiary that the expense report is created in
remote_was_deletedbooleanRead-only

Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. Learn more.

field_mappingsobject or nullRead-only
remote_datalist of objects or nullRead-only
remote_fieldslist of objectsRead-only