Download OpenAPI specification:Download
Hey there! We're glad you're interested in the Splitwise API. This documentation will help you to fetch information on users, expenses, groups, and much more.
If something in the API is confusing you, you can open an issue about it on GitHub. We're a small team, so we may not have an instant fix, but we'll get back to you as soon as we're able. (If you spot an issue in our API documentation itself, feel free to open a pull request to update this website!)
The development community has built a number of unofficial, third-party SDKs for Splitwise in a variety of different languages.
If you've built a third-party SDK for Splitwise and you'd like to see it included in this list, then please open a pull request to update this section and add a new link. Thank you for your work!
Note: These links are provided for convenience. These libraries have not been reviewed or endorsed by Splitwise, and Splitwise cannot vouch for their quality. If you have questions or bug reports, please direct your feedback to the authors of these libraries.
Splitwise provides this Self-Serve API to facilitate integrations with third-party applications, as well as open-up functionality for hobbyists and power users to programmatically interact with their own Splitwise account and build plugins or other tools.
If you’re interested in integrating your commercial application with Splitwise, we strongly encourage you to contact developers@splitwise.com so our development team can help discuss your use case, provide private APIs and Enterprise support, and offer an appropriate commercial license for the integration. The Self-Serve API documented here may be suitable for internal prototyping and other exploratory work.
If you are developing a non-commercial plugin application or personal project, we recommend you make use of the Self-Serve API documented here under the API Terms Of Use. Please be aware that our Self-Serve API has conservative rate and access limits, which are subject to change at any time and not well suited to commercial projects. If this is a problem for your use case, please contact us at developers@splitwise.com to discuss your needs.
All Self-Service API users are subject to the API Terms of Use below.
These API Terms of Use describe your rights and responsibilities when accessing our publicly available Application Programming Interface (API) and related API documentation. Please review them carefully.
Splitwise may modify this Agreement at any time by posting a revised version on our website. The revised version will be effective at the time that it is posted.
These API terms form a binding contract between you and us. In these terms "you," and "your," refers to the individual, company or legal entity and/or entities that you represent while accessing the API. “We”, “us”, “our” and “Splitwise” refers to Splitwise Inc. By accepting these API terms, either by accessing or using the API, or authorizing or permitting any individual to access or use the API, you agree to be bound by this contract.
Splitwise uses OAuth 2 with the authorization code flow. To connect via OAuth 2, you'll need to register your app. When you register, you'll be given a key and secret.
Note: OAuth can be a very confusing protocol to implement correctly, and we strongly recommend that you use an existing OAuth library to connect to Splitwise. You can find a list of OAuth client libraries at the OAuth community site.
For more information on using OAuth, check out the following resources:
Security Scheme Type | OAuth2 |
---|---|
authorizationCode OAuth Flow | Authorization URL: /oauth/authorize Token URL: /oauth/token Scopes: |
For speed and ease of prototyping, you can generate a personal API key on your app's details page. You should present this key to the server via the Authorization header as a Bearer token. The API key is an access token for your personal account, so keep it as safe as you would a password. If your key becomes compromised or you want to invalidate your existing key for any other reason, you can do so on the app details page by generating a new key.
Security Scheme Type | HTTP |
---|---|
HTTP Authorization Scheme | bearer |
Bearer format | "API key" |
{- "user": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "notifications_read": "2017-06-02T20:21:57Z",
- "notifications_count": 12,
- "notifications": {
- "added_as_friend": true
}, - "default_currency": "USD",
- "locale": "en"
}
}
{- "user": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}
}
id required | integer |
first_name | string |
last_name | string |
string | |
password | string |
locale | string |
default_currency | string |
{- "first_name": "string",
- "last_name": "string",
- "email": "string",
- "password": "string",
- "locale": "string",
- "default_currency": "string"
}
{- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}
A Group represents a collection of users who share expenses together. For example, some users use a Group to aggregate expenses related to a home. Others use it to represent a trip. Expenses assigned to a group are split among the users of that group. Importantly, two users in a Group can also have expenses with one another outside of the Group.
Note: Expenses that are not associated with a group are listed in a group with ID 0.
{- "groups": [
- {
- "id": 321,
- "name": "Housemates 2020",
- "group_type": "home",
- "updated_at": "2019-08-24T14:15:22Z",
- "simplify_by_default": true,
- "members": [
- {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "-5.02"
}
]
}
], - "original_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "simplified_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "avatar": {
- "original": null,
}, - "custom_avatar": true,
}
]
}
{- "group": {
- "id": 321,
- "name": "Housemates 2020",
- "group_type": "home",
- "updated_at": "2019-08-24T14:15:22Z",
- "simplify_by_default": true,
- "members": [
- {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "-5.02"
}
]
}
], - "original_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "simplified_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "avatar": {
- "original": null,
}, - "custom_avatar": true,
}
}
Creates a new group. Adds the current user to the group by default.
Note: group user parameters must be flattened into the format users__{index}__{property}
, where
property
is user_id
, first_name
, last_name
, or email
.
The user's email or ID must be provided.
name required | string |
group_type | string Enum: "home" "trip" "couple" "other" "apartment" "house" What is the group used for? Note: It is recommended to use |
simplify_by_default | boolean Turn on simplify debts? |
users__{index}__{property}* | string |
{- "name": "The Brain Trust",
- "group_type": "trip",
- "users__0__first_name": "Alan",
- "users__0__last_name": "Turing",
- "users__0__email": "alan@example.org",
- "users__1__id": 5823
}
{- "group": {
- "id": 321,
- "name": "Housemates 2020",
- "group_type": "home",
- "updated_at": "2019-08-24T14:15:22Z",
- "simplify_by_default": true,
- "members": [
- {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "-5.02"
}
]
}
], - "original_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "simplified_debts": [
- {
- "from": 18523,
- "to": 90261,
- "amount": "414.5",
- "currency_code": "USD"
}
], - "avatar": {
- "original": null,
}, - "custom_avatar": true,
}
}
Restores a deleted group.
Note: 200 OK does not indicate a successful response. You must check the success
value of the response.
id required | integer |
{- "success": true
}
Note: 200 OK does not indicate a successful response. You must check the success
value of the response.
group_id required | integer |
user_id required | integer |
{- "group_id": 49012,
- "user_id": 7999632
}
{- "success": true,
- "user": { },
- "errors": { }
}
Remove a user from a group. Does not succeed if the user has a non-zero balance.
Note: 200 OK does not indicate a successful response. You must check the success value of the response.
group_id required | integer |
user_id required | integer |
{- "group_id": 4012,
- "user_id": 940142
}
{- "success": true,
- "errors": { }
}
Note: group
objects only include group balances with that friend.
{- "friends": [
- {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "groups": [
- {
- "group_id": 571,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
]
}
], - "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
], - "updated_at": "2019-08-24T14:15:22Z"
}
]
}
id required | integer User ID of the friend |
{- "friend": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "groups": [
- {
- "group_id": 571,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
]
}
], - "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
], - "updated_at": "2019-08-24T14:15:22Z"
}
}
Adds a friend. If the other user does not exist, you must supply user_first_name
.
If the other user exists, user_first_name
and user_last_name
will be ignored.
user_email | string |
user_first_name | string |
user_last_name | string |
{- "user_email": "ada@example.com",
- "user_first_name": "Ada",
- "user_last_name": "Lovelace"
}
{- "friend": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "groups": [
- {
- "group_id": 571,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
]
}
], - "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
], - "updated_at": "2019-08-24T14:15:22Z"
}
}
Add multiple friends at once.
For each user, if the other user does not exist, you must supply friends__{index}__first_name
.
Note: user parameters must be flattened into the format friends__{index}__{property}
, where
property
is first_name
, last_name
, or email
.
friends__{index}__{property}* | string |
{- "friends__0__first_name": "Alan",
- "friends__0__last_name": "Turing",
- "friends__0__email": "alan@example.org",
- "friends__1__email": "existing_user@example.com"
}
{- "users": [
- {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false,
- "groups": [
- {
- "group_id": 571,
- "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
]
}
], - "balance": [
- {
- "currency_code": "USD",
- "amount": "414.5"
}
], - "updated_at": "2019-08-24T14:15:22Z"
}
], - "errors": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}
Given a friend ID, break off the friendship between the current user and the specified user.
Note: 200 OK does not indicate a successful response. You must check the success
value of the response.
id required | integer User ID of the friend |
{- "success": true,
- "errors": [ ]
}
{- "expense": {
- "cost": "25.0",
- "description": "Brunch",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "id": 51023,
- "group_id": 391,
- "friendship_id": 4818,
- "expense_bundle_id": 491030,
- "repeats": true,
- "email_reminder": true,
- "email_reminder_in_advance": null,
- "next_repeat": "string",
- "comments_count": 0,
- "payment": true,
- "transaction_confirmed": true,
- "repayments": [
- {
- "from": 6788709,
- "to": 270896089,
- "amount": "25.0"
}
], - "created_at": "2012-07-27T06:17:09Z",
- "created_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "updated_at": "2012-12-23T05:47:02Z",
- "updated_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "deleted_at": "2012-12-23T05:47:02Z",
- "deleted_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "category": {
- "id": 5,
- "name": "Electricity"
}, - "users": [
- {
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}, - "user_id": 491923,
- "paid_share": "8.99",
- "owed_share": "4.5",
- "net_balance": "4.49"
}
], - "comments": [
- {
- "id": 79800950,
- "content": "John D. updated this transaction: - The cost changed from $6.99 to $8.99",
- "comment_type": "System",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
]
}
}
group_id | integer If provided, only expenses in that group will be returned, and |
friend_id | integer ID of another user. If provided, only expenses between the current and provided user will be returned. |
dated_after | string <date-time> |
dated_before | string <date-time> |
updated_after | string <update-time> |
updated_before | string <date-time> |
limit | integer Default: 20 |
offset | integer Default: 0 |
{- "expenses": [
- {
- "cost": "25.0",
- "description": "Brunch",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "id": 51023,
- "group_id": 391,
- "friendship_id": 4818,
- "expense_bundle_id": 491030,
- "repeats": true,
- "email_reminder": true,
- "email_reminder_in_advance": null,
- "next_repeat": "string",
- "comments_count": 0,
- "payment": true,
- "transaction_confirmed": true,
- "repayments": [
- {
- "from": 6788709,
- "to": 270896089,
- "amount": "25.0"
}
], - "created_at": "2012-07-27T06:17:09Z",
- "created_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "updated_at": "2012-12-23T05:47:02Z",
- "updated_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "deleted_at": "2012-12-23T05:47:02Z",
- "deleted_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "category": {
- "id": 5,
- "name": "Electricity"
}, - "users": [
- {
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}, - "user_id": 491923,
- "paid_share": "8.99",
- "owed_share": "4.5",
- "net_balance": "4.49"
}
], - "comments": [
- {
- "id": 79800950,
- "content": "John D. updated this transaction: - The cost changed from $6.99 to $8.99",
- "comment_type": "System",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
]
}
]
}
Creates an expense. You may either split an expense equally (only with group_id
provided),
or supply a list of shares.
When splitting equally, the authenticated user is assumed to be the payer.
When providing a list of shares, each share must include paid_share
and owed_share
, and must be identified by one of the following:
email
, first_name
, and last_name
user_id
Note: 200 OK does not indicate a successful response. The operation was successful only if errors
is empty.
cost required | string A string representation of a decimal value, limited to 2 decimal places |
description required | string A short description of the expense |
details | string or null Also known as "notes." |
date | string <date-time> The date and time the expense took place. May differ from |
repeat_interval | string Enum: "never" "weekly" "fortnightly" "monthly" "yearly" |
currency_code | string A currency code. Must be in the list from |
category_id | integer A category id from |
group_id required | integer The group to put this expense in. |
split_equally required | boolean Value: true |
{- "cost": "25",
- "description": "Grocery run",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "group_id": 0,
- "split_equally": true
}
{- "expenses": [
- {
- "cost": "25.0",
- "description": "Brunch",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "id": 51023,
- "group_id": 391,
- "friendship_id": 4818,
- "expense_bundle_id": 491030,
- "repeats": true,
- "email_reminder": true,
- "email_reminder_in_advance": null,
- "next_repeat": "string",
- "comments_count": 0,
- "payment": true,
- "transaction_confirmed": true,
- "repayments": [
- {
- "from": 6788709,
- "to": 270896089,
- "amount": "25.0"
}
], - "created_at": "2012-07-27T06:17:09Z",
- "created_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "updated_at": "2012-12-23T05:47:02Z",
- "updated_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "deleted_at": "2012-12-23T05:47:02Z",
- "deleted_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "category": {
- "id": 5,
- "name": "Electricity"
}, - "users": [
- {
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}, - "user_id": 491923,
- "paid_share": "8.99",
- "owed_share": "4.5",
- "net_balance": "4.49"
}
], - "comments": [
- {
- "id": 79800950,
- "content": "John D. updated this transaction: - The cost changed from $6.99 to $8.99",
- "comment_type": "System",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
]
}
], - "errors": { }
}
Updates an expense. Parameters are the same as in create_expense
, but you only need to include parameters
that are changing from the previous values. If any values is supplied for users__{index}__{property}
, all
shares for the expense will be overwritten with the provided values.
Note: 200 OK does not indicate a successful response. The operation was successful only if errors
is empty.
id required | integer ID of the expense to update |
cost required | string A string representation of a decimal value, limited to 2 decimal places |
description required | string A short description of the expense |
details | string or null Also known as "notes." |
date | string <date-time> The date and time the expense took place. May differ from |
repeat_interval | string Enum: "never" "weekly" "fortnightly" "monthly" "yearly" |
currency_code | string A currency code. Must be in the list from |
category_id | integer A category id from |
group_id required | integer The group to put this expense in, or |
users__0__user_id | integer |
users__0__paid_share | string Decimal amount as a string with 2 decimal places. The amount this user paid for the expense |
users__0__owed_share | string Decimal amount as a string with 2 decimal places. The amount this user owes for the expense |
users__1__first_name | string |
users__1__last_name | string |
users__1__email | string |
users__1__paid_share | string Decimal amount as a string with 2 decimal places. The amount this user paid for the expense |
users__1__owed_share | string Decimal amount as a string with 2 decimal places. The amount this user owes for the expense |
users__{index}__{property}* | string |
{- "cost": "25",
- "description": "Grocery run",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "group_id": 0,
- "users__0__user_id": 54123,
- "users__0__paid_share": "25",
- "users__0__owed_share": "13.55",
- "users__1__first_name": "Neu",
- "users__1__last_name": "Yewzer",
- "users__1__email": "neuyewxyz@example.com",
- "users__1__paid_share": "0",
- "users__1__owed_share": "11.45",
- "users__{index}__{property}1": "string",
- "users__{index}__{property}2": "string"
}
{- "expenses": [
- {
- "cost": "25.0",
- "description": "Brunch",
- "details": "string",
- "date": "2012-05-02T13:00:00Z",
- "repeat_interval": "never",
- "currency_code": "USD",
- "category_id": 15,
- "id": 51023,
- "group_id": 391,
- "friendship_id": 4818,
- "expense_bundle_id": 491030,
- "repeats": true,
- "email_reminder": true,
- "email_reminder_in_advance": null,
- "next_repeat": "string",
- "comments_count": 0,
- "payment": true,
- "transaction_confirmed": true,
- "repayments": [
- {
- "from": 6788709,
- "to": 270896089,
- "amount": "25.0"
}
], - "created_at": "2012-07-27T06:17:09Z",
- "created_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "updated_at": "2012-12-23T05:47:02Z",
- "updated_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "deleted_at": "2012-12-23T05:47:02Z",
- "deleted_by": {
- "id": 0,
- "first_name": "Ada",
- "last_name": "Lovelace",
- "email": "ada@example.com",
- "registration_status": "confirmed",
- "picture": {
- "small": "string",
- "medium": "string",
- "large": "string"
}, - "custom_picture": false
}, - "category": {
- "id": 5,
- "name": "Electricity"
}, - "users": [
- {
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}, - "user_id": 491923,
- "paid_share": "8.99",
- "owed_share": "4.5",
- "net_balance": "4.49"
}
], - "comments": [
- {
- "id": 79800950,
- "content": "John D. updated this transaction: - The cost changed from $6.99 to $8.99",
- "comment_type": "System",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
]
}
], - "errors": { }
}
Note: 200 OK does not indicate a successful response. The operation was successful only if success
is true.
id required | integer ID of the expense to delete |
{- "success": true
}
expense_id required | integer Example: expense_id=4193 |
{- "comments": [
- {
- "id": 79800950,
- "content": "John D. updated this transaction: - The cost changed from $6.99 to $8.99",
- "comment_type": "System",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
]
}
expense_id | integer |
content | string |
{- "expense_id": 5123,
- "content": "Does this include the delivery fee?"
}
{- "comment": {
- "id": 79800950,
- "content": "Does this include the delivery fee?",
- "comment_type": "User",
- "relation_type": "ExpenseComment",
- "relation_id": 5123,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
}
Deletes a comment. Returns the deleted comment.
id required | integer |
{- "comment": {
- "id": 79800950,
- "content": "Does this include the delivery fee?",
- "comment_type": "User",
- "relation_type": "ExpenseComment",
- "relation_id": 855870953,
- "created_at": "2019-08-24T14:15:22Z",
- "deleted_at": "2019-08-24T14:15:22Z",
- "user": {
- "id": 491923,
- "first_name": "Jane",
- "last_name": "Doe",
- "picture": {
- "medium": "image_url"
}
}
}
}
Return a list of recent activity on the users account with the most recent items first.
content
will be suitable for display in HTML and uses only the <strong>
, <strike>
, <small>
,
<br>
and <font color="#FFEE44">
tags.
The type
value indicates what the notification is about. Notification types may be added in the future
without warning. Below is an incomplete list of notification types.
Type | Meaning |
---|---|
0 | Expense added |
1 | Expense updated |
2 | Expense deleted |
3 | Comment added |
4 | Added to group |
5 | Removed from group |
6 | Group deleted |
7 | Group settings changed |
8 | Added as friend |
9 | Removed as friend |
10 | News (a URL should be included) |
11 | Debt simplification |
12 | Group undeleted |
13 | Expense undeleted |
14 | Group currency conversion |
15 | Friend currency conversion |
Note: While all parameters are optional, the server sets arbitrary (but large) limits
on the number of notifications returned if you set a very old updated_after
value or limit
of 0
for a
user with many notifications.
updated_after | string <date-time> Example: updated_after=2020-07-28T20:46:00Z If provided, returns only notifications after this time. |
limit | integer Default: 0 Omit (or provide |
{- "notifications": [
- {
- "id": 32514315,
- "type": 0,
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": 2,
- "source": {
- "type": "Expense",
- "id": 865077,
- "url": "string"
}, - "image_shape": "square",
- "content": "<strong>You</strong> paid <strong>Jon H.</strong>.<br><font color=\\\"#5bc5a7\\\">You paid $23.45</font>"
}
]
}
Returns a list of all currencies allowed by the system. These are mostly ISO 4217 codes, but we do sometimes use pending codes or unofficial, colloquial codes (like BTC instead of XBT for Bitcoin).
{- "currencies": [
- {
- "currency_code": "BRL",
- "unit": "R$"
}
]
}
Returns a list of all categories Splitwise allows for expenses. There are parent categories that represent groups of categories with subcategories for more specific categorization. When creating expenses, you must use a subcategory, not a parent category. If you intend for an expense to be represented by the parent category and nothing more specific, please use the "Other" subcategory.
{- "categories": [
- {
- "id": 1,
- "name": "Utilities",
- "icon_types": {
}, - "subcategories": [
- {
- "id": 48,
- "name": "Cleaning",
- "icon_types": {
}
}
]
}
]
}