Expensify Connector
Description
Expensify provides an industry leading expense management system.
Use the Expensify component to programmatically download expense report data for analysis or insertion into an accounting package, provision accounts for new hires, and much more.
API Documentation
This component was built using the Expensify API Reference.
Connections
Basic Connection
key: basicCreate a new authentication connection. Refer to the following guide for more information.
Prerequisites
- Access to the Expensify integrations page at
https://www.expensify.com/tools/integrations/
Setup Steps
- Navigate to
https://www.expensify.com/tools/integrations/and select the option that creates a new set of credentials. - A pair of credentials,
partnerUserIDandpartnerUserSecret, is generated and shown on the page.- Store the
partnerUserIDandpartnerUserSecretpair in a secure location, as they are not shown again.
- Store the
Configure the Connection
Create a connection of type Basic Connection and enter the following values:
- Enter the
partnerUserIDvalue into Partner User ID. - Enter the
partnerUserSecretvalue into Partner User Secret.
| Input | Notes | Example |
|---|---|---|
| Partner User ID | The partnerUserID generated on the Expensify Integrations page. See the Integration Server documentation for how to generate it. | _REPLACE_ |
| Partner User Secret | The partnerUserSecret generated together with the Partner User ID. Expensify shows it only once, so store it securely when it is generated. | _REPLACE_ |
Triggers
New Policies
Checks for new policies in Expensify on a configured schedule. | key: pollChangesTrigger
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Show New Records | When true, newly created records are included in trigger results. | true |
This trigger polls the Expensify Integration Server API for new policies on a configured schedule.
How It Works
- The trigger runs on the configured schedule (e.g., every 5 minutes)
- It fetches the complete list of policies from the Expensify account
- The returned policy IDs are compared against the set of previously known IDs; only newly appearing policies are captured
- The trigger updates its internal state after each poll, storing the current set of known policy IDs
Returned Data
The trigger returns an object with two arrays: created for new policies and updated for modified policies. Because change detection is ID-based, updated is always an empty array.
Example Response
{
"data": {
"created": [
{
"id": "0123456789ABCDEF",
"name": "Engineering Team Policy",
"type": "corporate",
"owner": "admin@example.com"
}
],
"updated": []
}
}
Notes
- On the first poll, the trigger captures a baseline snapshot of all existing policy IDs. No records are returned on the first execution. Subsequent polls detect additions against that baseline
- ID-based tracking cannot detect updates to existing policies. Only the appearance of new policy IDs is reported
- The Expensify API returns the full policy list on every request; the trigger performs the new/known comparison locally
Example Payload for New Policies⤓
Data Sources
List Cards
Returns all Cards. | key: listCards | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Domain | The name of the domain to list the Cards for. | domain.com |
| Type | Specifies to the job that it has to list the Cards of a domain. | domainCardList |
Example Payload for List Cards⤓
List Policies
Returns all Policies. | key: listPolicies | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Type | Specifies to the job that it has to get a policy summary list. | policyList |
Example Payload for List Policies⤓
Actions
Create Expense
Create expenses in a user’s account. | key: createExpense
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Employee Email | The email address of the Expensify user whose account the job runs against. | employee@domain.com |
| Transaction List | The transactions to add to the report. | |
| Type | Specifies to the job that it has to create expenses. | expenses |
Example Payload for Create Expense⤓
Create Expense Rule
Create expense rules for a given employee on a given policy. | key: createExpenseRule
| Input | Notes | Example |
|---|---|---|
| Actions | The actions to perform on the expense rule. | |
| Connection | ||
| Employee Email | The email address of the Expensify user whose account the job runs against. | employee@domain.com |
| Policy ID | The unique identifier for the policy (workspace) the job runs against. The policy must be owned or shared by the user. | E40D9B8DF456E233 |
| Type | Specifies to the job that it has to create an expense rule. | expenseRules |
Create Policy
Creates a policy. | key: createPolicy
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Plan | Specifies the plan of the policy. If not specified, the new policy will be created under the team plan. | |
| Policy Name | The name of the policy to create. | Marketing Team |
| Type | Specifies to the job that it has to create a policy. | policy |
Example Payload for Create Policy⤓
Create Report
Creates a report, with transactions, in a user’s account. | key: createReport
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Employee Email | The email address of the Expensify user whose account the job runs against. | employee@domain.com |
| Expenses | The expenses to add to the report. | |
| Policy ID | The unique identifier for the policy (workspace) the job runs against. The policy must be owned or shared by the user. | E40D9B8DF456E233 |
| Report | The report to create. | |
| Type | Specifies to the job that it has to create a report. | report |
Example Payload for Create Report⤓
Download Report
Download reports that were generated with the Report Exporter job. | key: downloadReport
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| File Name | The name of a file generated from the exporter job. | exporteba3c95b-f302-4d74-a41a-6127c9088551-5650745444954548.pdf |
| File System | The file system the exporter job stored the file on. Use the same value the file was generated with. | integrationServer |
Export Report
Export expense or report data in a configurable format for analysis or insertion into an accounting package. | key: exportReport
| Input | Notes | Example |
|---|---|---|
| Additional Fields | Additional optional fields: includes File Basename, Include Full Page Receipts PDF, Limit, and Test. | |
| Approved After | Filters out all reports approved before, or on, the given date. Only applies to reports that have been approved. yyyy-mm-dd formatted date. | 2016-01-01 |
| Connection | ||
| Employee Email | The email address of the Expensify user whose account the job runs against. | employee@domain.com |
| End Date | Filters out all reports submitted or created after the given date, whichever occurred last (inclusive). yyyy-mm-dd formatted date. | 2016-12-31 |
| File Extension | Specifies the format of the generated report. Note: if the 'pdf' option is chosen, one PDF file will be generated for each report exported. | json |
| Mark as Exported Label Filter | Filters out reports that have already been exported with this label. | Expensify Export |
| On Finish | The actions Expensify runs when the job finishes, such as emailing a summary of the changes to a list of recipients. | |
| Policy ID List | The IDs of the policies to get information for. | E40D9B8DF456E233 |
| Report ID List | The IDs of the reports to get information for. | R006AseGxMka |
| Start Date | Filters out all reports submitted or created before the given date, whichever occurred last (inclusive). yyyy-mm-dd formatted date. | 2016-01-01 |
| Report State | The report state to filter on. Only reports in this state are exported. | REIMBURSED |
| Template | The template parameter is used to format the Expensify data as you wish. It is based on the Freemarker language's syntax. |
Example Payload for Export Report⤓
Get Policy
Gets specific information about listed policies. | key: getPolicy
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Fields | Specifies the fields of the policy to gather information for. | |
| Policy ID List | The IDs of the policies to get information for. | E40D9B8DF456E233 |
| Type | Specifies to the job that it has to get information specific to policies. | policy |
| User Email | Specifies the user to gather the policy list for. Third-party access must have been granted by that user/company domain beforehand. | employee@domain.com |
Example Payload for Get Policy⤓
List Cards
Gets the list of credit cards that are assigned at the domain level. | key: listCards
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Domain | The name of the domain to get the cards for. | domain.com |
| Type | Specifies to the job that it has to list the cards of a domain. | domainCardList |
Example Payload for List Cards⤓
List Policies
Gets a list of policies with some relevant information about them. | key: listPolicies
| Input | Notes | Example |
|---|---|---|
| Admin Only | When true, only returns the policies the user is an admin of. | false |
| Connection | ||
| Type | Specifies to the job that it has to get a policy summary list. | policyList |
| User Email | Specifies the user to gather the policy list for. Third-party access must have been granted by that user/company domain beforehand. | employee@domain.com |
Example Payload for List Policies⤓
Raw Request
Send a raw HTTP request to the Expensify API. | key: rawRequest
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Data | The HTTP body payload to send to the URL. | {"exampleKey": "Example Data"} |
| File Data | File Data to be sent as a multipart form upload. | [{key: "example.txt", value: "My File Contents"}] |
| File Data File Names | File names to apply to the file data inputs. Keys must match the file data keys above. | |
| Form Data | The Form Data to be sent as a multipart form upload. | [{"key": "Example Key", "value": new Buffer("Hello World")}] |
| Header | A list of headers to send with the request. | User-Agent: curl/7.64.1 |
| Max Retry Count | The maximum number of retries to attempt. Specify 0 for no retries. | 0 |
| Method | The HTTP method to use. | |
| Query Parameter | A list of query parameters to send with the request. This is the portion at the end of the URL similar to ?key1=value1&key2=value2. | |
| Response Type | The type of data you expect in the response. You can request json, text, or binary data. | json |
| Retry On All Errors | If true, retries on all erroneous responses regardless of type. This is helpful when retrying after HTTP 429 or other 3xx or 4xx errors. Otherwise, only retries on HTTP 5xx and network errors. | false |
| Retry Delay (ms) | The delay in milliseconds between retries. This is used when 'Use Exponential Backoff' is disabled. | 0 |
| Timeout | The maximum time that a client will await a response to its request | 2000 |
| URL | This input is not required as the Expensify API is a single endpoint. | |
| Use Exponential Backoff | Specifies whether to use a pre-defined exponential backoff strategy for retries. When enabled, 'Retry Delay (ms)' is ignored. | false |
Update Employee
Add, update or remove policy members. | key: updateEmployee
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Employees | Replace or update the existing employees of the policy with the ones provided. If the employee does not exist, it will be created. | |
| On Finish | The actions Expensify runs when the job finishes, such as emailing a summary of the changes to a list of recipients. | |
| Provisioning Options | Options that control how the employee update is applied: dry run, primary policy assignment, and approval chain fixes. | |
| Type | Specifies to the job that it has to update an employee | employees |
The advanced employee updater is designed to allow dynamic and customizable employee provisioning and de-provisioning in Expensify. Supported operations:
- Provision employees into Expensify policies based on customizable fields, such as employee department, country, job code, etc.
- De-provision employees from Expensify, based on customizable fields, such as termination date
- Assign employees to Expensify domain groups based on customizable fields, such as employee department, country, job code, etc.
- Automatically invite managers to policies they have subordinates on
- Automatically detect employee email address changes, and merge both addresses into the same account
- Import additional information from the employee feed into Expensify, to reuse for custom data export
Example Payload for Update Employee⤓
Update Expense Rules
Update a preexisting expense rule for a given employee on a given policy. | key: updateExpenseRule
| Input | Notes | Example |
|---|---|---|
| Actions | The actions to perform on the expense rule. | |
| Connection | ||
| Employee Email | The email address of the Expensify user whose account the job runs against. | employee@domain.com |
| Policy ID | The unique identifier for the policy (workspace) the job runs against. The policy must be owned or shared by the user. | E40D9B8DF456E233 |
| Rule ID | The rule to update. | Any valid Expensify rule ID, owned or shared by the user |
| Type | Specifies to the job that it has to update an expense rule. | expenseRules |
Update Policy
Manage categories, tags and report fields on a policy. | key: updatePolicy
| Input | Notes | Example |
|---|---|---|
| Categories | Replace or update the existing categories of the policy with the ones provided. | |
| Connection | ||
| Policy ID | The unique identifier for the policy (workspace) the job runs against. The policy must be owned or shared by the user. | E40D9B8DF456E233 |
| Policy ID List | The IDs of the policies to get information for. | E40D9B8DF456E233 |
| Report Fields | Replace or update the existing report fields of the policy with the ones provided. | |
| Tags | Replace the existing tags of the policy with the ones provided. | |
| Type | Specifies to the job that it has to update a policy. | policy |
Example Payload for Update Policy⤓
Update Report Status
Update the status of a report. | key: updateReportStatus
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Filters | The filters to apply to the report list. | |
| Status | The status to change the reports to. At the moment, only Reimbursed is supported. Only reports in the Approved status can be updated to Reimbursed. All other reports will be ignored. | REIMBURSED |
| Type | Specifies to the job that it has to update the status of a list of reports. | reportStatus |
Example Payload for Update Report Status⤓
Changelog
2026-11-11
Updated the component description to better summarize what the component does
2026-11-10
Published the component as an npm package, so code-native integrations can install it and call its actions, triggers and data sources from code with TypeScript types
2026-11-03
Improved reliability and the configuration experience across actions
- Fixed actions other than Raw Request reporting success when Expensify rejected a job; the step now fails with an error containing the response code and message
- Fixed Raw Request sending the Data input as numbered character entries instead of its JSON content; the JSON is now merged into the request
- Fixed optional JSON inputs such as On Finish, Filters, Categories, Tags, Report Fields, and Employees prefilling sample data that was sent to Expensify unless cleared; the samples now appear only as examples
- Fixed Update Employee ignoring a disabled Fix Approval Chains input (previously labeled Admin Only), which left Expensify fixing approval chains; turning it off now takes effect
- Updated Export Report to group its optional inputs into Additional Fields and Update Employee to group its provisioning inputs into Provisioning Options
- Added inline action calling support to 11 actions for improved example output during configuration
- Added output schemas to 10 actions for improved field mapping during configuration
2026-04-30
Updated spectral version
2026-04-21
Added New Policies polling trigger that checks for new policies in Expensify on a configured schedule, using ID-based change detection
2026-04-07
Added global debug support across all actions for improved troubleshooting