Overview
This node integrates with the Splitwise API to retrieve multiple expense records based on specified filters and parameters. It is useful for automating workflows that require fetching lists of expenses, such as financial reporting, budgeting, or syncing expense data with other systems.
For example, you can use this node to:
- Retrieve all expenses within a specific group.
- Get expenses involving a particular friend.
- Filter expenses by date ranges (e.g., only recent expenses).
- Limit the number of returned expenses for pagination purposes.
Properties
| Name | Meaning |
|---|---|
| Authentication | Method used to authenticate with the Splitwise API. Options: "API Key" or "OAuth2". |
| Additional Fields | Optional filters and parameters to refine the list of expenses returned. These include: |
| - Group Name or ID | Filter expenses to only those belonging to a specific group. If provided, this overrides the friend filter. |
| - Friend Name or ID | Filter expenses to only those between the current user and the specified friend. Ignored if group filter is set. |
| - Dated After | Only return expenses dated after this date/time. |
| - Dated Before | Only return expenses dated before this date/time. |
| - Updated After | Only return expenses updated after this date/time. |
| - Updated Before | Only return expenses updated before this date/time. |
| - Limit | Maximum number of expense records to return. Default is 50. |
| - Offset | Number of expense records to skip (useful for pagination). Default is 0. |
Output
The node outputs an array of expense objects in the json output field. Each object represents an individual expense with details as provided by the Splitwise API, such as cost, description, currency, category, group association, and timestamps.
No binary data is output by this node.
Dependencies
- Requires access to the Splitwise API.
- Requires either an API key credential or OAuth2 authentication configured in n8n.
- The base URL for API requests is
https://secure.splitwise.com/api/v3.0. - The node uses internal helper functions to make authenticated HTTP requests to the API.
Troubleshooting
- Authentication errors: Ensure that the correct authentication method is selected and that valid credentials are provided.
- Empty results: Check that the filters (group, friend, dates) are correctly set and correspond to existing data in your Splitwise account.
- Limit and offset usage: If paginating through large datasets, verify that
limitandoffsetvalues are set appropriately to avoid missing or duplicate records. - API rate limits: Excessive requests may be throttled by Splitwise; consider adding delays or handling rate limit errors gracefully.
- Error messages from API: The node surfaces error messages returned by the API, such as invalid IDs or permission issues. Review these messages to adjust input parameters accordingly.
Links and References
- Splitwise API Documentation
- n8n Expressions Documentation (for using expressions in property fields)