Linking Brex as a source
Alpha release
This source is currently in alpha. The interface and available tables may change.
The Brex connector syncs your spend data – card and cash transactions, expenses, users, departments, locations, vendors, and budgets – into PostHog.
Adding a data source
- Go to the sources tab of the data pipeline section in PostHog.
- Click + New source and then click Link next to Brex.
- Next, you need an API user token from Brex. In your Brex dashboard under Settings > Developer, create a new token. Grant read access to the scopes for the data you want to sync: Transactions and Accounts, Expenses, Team, Payments, and Budgets.
- Back in PostHog, enter your token in the API user token field and click Next.
- Select the tables you want to sync, set the sync method and frequency, then click Import.
Once the syncs are complete, you can start using Brex data in PostHog.
Token expiration
Brex API user tokens expire after 90 days without API activity. If your syncs start failing with authentication errors, generate a new token in your Brex dashboard and reconnect the source.
Available tables
| Table | Description | Sync method |
|---|---|---|
card_transactions | Card transactions on your primary card account | Incremental |
cash_transactions | Cash transactions across all cash accounts | Incremental |
expenses | Expenses submitted in Brex | Incremental |
users | Users in your Brex account | Full refresh |
departments | Departments in your organization | Full refresh |
locations | Locations in your organization | Full refresh |
vendors | Vendors in your Brex account | Full refresh |
budgets | Budgets configured in Brex | Full refresh |
Incremental tables sync only new or updated records on each run. Full refresh tables reload all data on each sync.
Configuration
| Option | Type | Required |
|---|---|---|
API user token | password | Yes |