Skip to content

Commit 368c3e7

Browse files
authored
Merge pull request #40 from splitwise/jas14/api-keys
Document API keys
2 parents ab0595c + 3bb0077 commit 368c3e7

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

source/index.html.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,18 @@ For more information on using OAuth, check out the following resources:
266266
- The term.ie [OAuth test server](http://term.ie/oauth/example/) (great for debugging authorization issues)
267267
- This old [Splitwise blog post](https://blog.splitwise.com/2013/07/15/setting-up-oauth-for-the-splitwise-api/) about OAuth
268268

269+
## API keys
270+
271+
```http
272+
GET /api/v3.0/get_current_user HTTP/1.1
273+
Host: www.splitwise.com
274+
Authorization: Bearer <your_token_here>
275+
```
276+
277+
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.
278+
279+
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.
280+
269281
# An important note about nested parameters
270282

271283
Due to a quirk in Splitwise's servers, nested parameters (e.g. `users[1][first_name]`) cannot currently be used when submitting a request. Instead, to indicate nested parameters, use double underscores (e.g. `users__1__first_name`). We hope to support proper nested parameters in future API versions.

0 commit comments

Comments
 (0)