This tool syncs the expenses from Splitwise to Firefly III using their respective APIs.
This is designed to be run as a cron job to sync the past n
days' transactions.
Set these variables either in the environment or a .env
file along with the script. For docker, the location would be /app/.env
.
SPLITWISE_TOKEN
: Get the token after registering your app as mentioned in their docs.FIREFLY_URL=http://firefly:8080
: Set your Firefly III instance URL.FIREFLY_TOKEN
: Set your Firefly III Personal Access Token as shown in their docs.FIREFLY_DEFAULT_SPEND_ACCOUNT=Amex
: Set the default source account to use when you paid for the expense in Splitwise.FIREFLY_DEFAULT_TRXFR_ACCOUNT=Chase
: Set the default source account to use when someone else paid for the expense in Splitwise.FIREFLY_DEFAULT_CATEGORY
: Set the default category to use. If empty, falls back to the Splitwise category.FIREFLY_DRY_RUN
: Set this to any value to dry run and skip the firefly API call.SPLITWISE_DAYS=1
Enter a note or a comment in the below format on Splitwise:
Firefly[/destination-account][/category][/description][/source-account]
If the destination account is not provided, the expense title will be used, which may create a new expense account on Firefly. The next two use their respective defaults from environment variables. Description, if provided, overrides the Splitwise description. Only the user's comments will be considered, not anyone else. If you update the transaction in any way after someone entered a note (not comment) that matches, it will be considered. Priority is for the latest comment > old comment > notes.
See issues for current drawbacks in the implementation.