Registry / crm-productivity / splitwise

splitwise

JSON →
library3.0.0pypypi✓ verified 83d ago

Unofficial Python SDK for the Splitwise API. Version 3.0.0 includes fixes for updateExpense and getExpenses. Release cadence is irregular.

pip install splitwise
INSTALL
IMPORT
SIG · SPLITWISE
S
splitwise
crm-productivitypythonv3.0.0
Install
2.3s avg
Import
714ms
Disk
22MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v3.0.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.770s · 23.3MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 2.3s · import 0.658s · 24MB
22MB installed
● package 22MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Splitwise
from splitwise import Splitwise
import splitwise
splitwise is a module; the class is Splitwise.
Expense
from splitwise.expense import Expense

Initialize the SDK and fetch the current user.

from splitwise import Splitwise splt = Splitwise(consumer_key='YOUR_KEY', consumer_secret='YOUR_SECRET') # For OAuth2, use access token # splt = Splitwise(consumer_key='YOUR_KEY', consumer_secret='YOUR_SECRET', access_token='ACCESS_TOKEN') print(splt.getCurrentUser())
Debug
Known issues
breakingIn v2.0.0, OAuth2 support was added. The constructor signature changed: OAuth1 uses consumer_key/consumer_secret, OAuth2 also requires access_token.
fix
Update code to match new constructor signature. For OAuth1, use setAccessToken() after authorization.
affects: <2.0.0 -> >=2.0.0
breakingIn v3.0.0, updateExpense() and getExpenses() were fixed. Behavior may have changed from v2.x.
fix
Review expense update and expense listing logic after upgrading.
affects: 2.x -> 3.0.0
gotchaThe SDK does not support Splitwise OAuth2 token refresh automatically. If your access token expires, you must re-authorize.
fix
Implement token refresh logic yourself by catching authorization errors and re-authorizing.
affects: all
Errors
Common errors & fixes
ImportError: cannot import name 'splitwise'
Using import splitwise instead of from splitwise import Splitwise.
fix
Use: from splitwise import Splitwise
splitwise.SplitwiseException: Invalid consumer key or consumer secret
Consumer key/secret are incorrect or swapped with API key.
fix
Ensure you are using the correct consumer key and secret from your Splitwise app settings.
AttributeError: 'Splitwise' object has no attribute 'getExpenses'
Using an older version (<3.0.0) where getExpenses was broken or not available.
fix
Upgrade to splitwise>=3.0.0: pip install --upgrade splitwise
Upgrade
Version history
3.0.0latest on PyPI · released Jun 19, 2023
Audit
Dependencies

No dependency data recorded yet.

Agent activity
33 hits · last 30 days
node
30
OpenAI (training)
1
Resources
splitwise — pip install splitwise · libregistry