Accounting API (1.0.0-alpha)

Download OpenAPI specification:Download

The Accounting API allows you to manage accounting data for connecting to your accounting system. The Accounting API is currently in Alpha. To access the Accounting Alpha API, please email developer-support@brex.com to express your interest. Please note that participation is determined by Brex based on program needs. For more details, please refer to https://developer.brex.com/docs/api-launch-stages/.

Accounting Integrations

View and manage accounting integrations.

Create accounting integration

Create a new accounting integration. The behavior depends on the existing active integration:

  • If no active integration exists: Creates and returns new integration
  • If active integration exists with same vendor: Returns the existing active integration
  • If active integration exists with different vendor: Returns 409 error

This ensures only one active integration exists per account.

Securityoauth2
Request
Request Body schema: application/json
vendor
required
string

The accounting vendor/system

Enum: "CAMPFIRE" "HANOVER_PARK" "RILLET"
vendor_account_id
required
string

The vendor account ID to tie this integration to

Responses
200

Integration created successfully

400

Bad request

401

Unauthorized

403

Forbidden

409

Active integration with different vendor already exists

500

Internal server error

post/v3/accounting/integration
Request samples
application/json
{
  • "vendor": "ERP_A",
  • "vendor_account_id": "vendor_account_id"
}
Response samples
application/json
{
  • "id": "int_abc123",
  • "vendor": "ERP_A",
  • "status": "ACTIVE",
  • "created_at": "2025-08-15T10:00:00Z",
  • "vendor_account_id": "vendor_account_id"
}

Disconnect accounting integration

Disconnect an active accounting integration.

  • If integration is ACTIVE: Disconnects and returns success
  • If integration ID doesn't exist: Returns 404 error
  • If integration is not currently active: Returns 409 error
Securityoauth2
Request
path Parameters
integration_id
required
string
Responses
200

Integration disconnected successfully

401

Unauthorized

403

Forbidden

404

Integration not found

409

Integration is not active

500

Internal server error

post/v3/accounting/integration/{integration_id}/disconnect
Request samples
Response samples
application/json
{
  • "id": "int_abc123",
  • "vendor": "ERP_A",
  • "status": "DISABLED",
  • "created_at": "2025-08-15T10:00:00Z",
  • "vendor_account_id": "vendor_account_id"
}

Reactivate accounting integration

Reactivate a disconnected accounting integration.

  • If integration is DISABLED: Reactivates and returns success
  • If integration ID doesn't exist: Returns 404 error
  • If an active integration already exists: Returns 409 error
Securityoauth2
Request
path Parameters
integration_id
required
string
Responses
200

Integration reactivated successfully

401

Unauthorized

403

Forbidden

404

Integration not found

409

Active integration already exists

500

Internal server error

post/v3/accounting/integration/{integration_id}/reactivate
Request samples
Response samples
application/json
{
  • "id": "int_abc123",
  • "vendor": "ERP_A",
  • "status": "ACTIVE",
  • "created_at": "2025-08-15T10:00:00Z",
  • "vendor_account_id": "vendor_account_id"
}

Accounting Records

View and manage accounting records.

Get accounting record by ID

Retrieve a single accounting record by its unique identifier

Securityoauth2
Request
path Parameters
record_id
required
string
query Parameters
single_entry
boolean

Whether to return single entry line items

Responses
200

Accounting record retrieved successfully

400

Bad request

401

Unauthorized

403

Forbidden

404

Record not found

500

Internal server error

get/v3/accounting/records/{record_id}
Request samples
Response samples
application/json
{
  • "id": "accr_abc123",
  • "amount": {
    },
  • "type": "CARD_EXPENSE_POST",
  • "review_status": "READY_FOR_EXPORT",
  • "source_id": "exp_xyz789",
  • "source_type": "CARD",
  • "erp_posting_date": "2025-04-24T16:13:49.959513Z",
  • "updated_at": "2025-04-24T16:13:49.959513Z",
  • "version": 1,
  • "receipts": [],
  • "user": {
    },
  • "vendor": null,
  • "memo": "Business lunch with client",
  • "posted_at": "2025-04-24T16:13:49.959513Z",
  • "due_at": null,
  • "invoice_number": null,
  • "line_items": [
    ]
}

Query accounting records

Query accounting records by IDs with optional filtering.

Securityoauth2
Request
query Parameters
ids
Array of strings

Filter by accounting record IDs. ID size is limited to 500. Example: ids=accr_xxx&ids=accr_yyy

review_status
string

Filter by review status. Only READY_FOR_EXPORT is supported.

Enum: "IN_REVIEW" "READY_FOR_EXPORT" "EXPORTED" "EXPORTING"
limit
number
Default: 100

Maximum number of records to return

cursor
string

Cursor for pagination

single_entry
boolean

Whether to return single entry line items

Responses
200

Query accounting records response

400

Bad request

401

Unauthorized

403

Forbidden

500

Internal server error

get/v3/accounting/records
Request samples
Response samples
application/json
{
  • "items": [
    ],
  • "next_cursor": null,
  • "has_next_page": false,
  • "total_count": 1
}

Report accounting export results

Report export success or failure for accounting records.

Securityoauth2
Request
Request Body schema: application/json
required
Array of SuccessfulExportResult (object) or FailedExportResult (object) non-empty

Array of export results (must contain at least one result)

Responses
200

Export results processed successfully

404

Not found - Given accounting record id is not found

422

Validation failed (duplicate accounting record ids or records not READY_FOR_EXPORT)

500

Internal server error

post/v3/accounting/records/export-results
Request samples
application/json
{}
Response samples
application/json
{
  • "updated_accounting_record_ids": [
    ]
}
Copyright © Brex 2019–2025. All rights reserved.