Endpoints exposed by this deployment. Every endpoint below accepts an API key, so it can be called from a script or another app without a logged-in browser session — generate one from Settings.
Authenticating
Send your key as a bearer token:
curl -H "Authorization: Bearer dk_..." https://duitduit.vercel.app/api/exportKeys are shown once at creation and can be revoked any time from Settings. Treat a key like a password — anyone holding it can read your data.
Endpoints marked Planned aren't callable yet — they're the roadmap for an upcoming mobile app. Only endpoints marked Live work today.
/api/exportLiveExports the authenticated user's transactions as a CSV file. Optional ?from=YYYY-MM-DD&to=YYYY-MM-DD query params filter by date (inclusive on both ends); omit either or both for an unfiltered export.
Auth: Browser session cookie, or an API key via Authorization: Bearer <key>.
Response: text/csv
/api/transactionsLiveList transactions, most recent first. Optional ?from=YYYY-MM-DD&to=YYYY-MM-DD filters by date (inclusive), ?category_id filters by category, ?limit (default 100, max 500) and ?offset paginate.
Auth: Browser session cookie, or an API key via Authorization: Bearer <key>.
Response: application/json
/api/transactionsPlannedLog a new transaction.
/api/transactions/{id}PlannedEdit a transaction.
/api/transactions/{id}PlannedDelete a transaction.
/api/transactions/importPlannedBulk-import transactions from a CSV file.
/api/categoriesPlannedList categories.
/api/categoriesPlannedCreate a category.
/api/categories/{id}PlannedRename a category or change its LHDN relief link.
/api/categories/{id}PlannedDelete a category.
/api/budgetsPlannedGet budget amounts for a given month.
/api/budgetsPlannedSet a category's budget for one month.
/api/budgets/defaultPlannedSet a category's default budget (all months).
/api/installments/providersPlannedList installment providers.
/api/installments/providersPlannedAdd an installment provider.
/api/installments/providers/{id}PlannedRename an installment provider.
/api/installments/providers/{id}PlannedDelete an installment provider.
/api/installments/plansPlannedList installment plans and their payment schedules.
/api/installments/plansPlannedAdd an installment plan.
/api/installments/plans/{id}PlannedDelete an installment plan.
/api/installments/payments/{id}PlannedMark a payment paid or unpaid.
/api/installments/providers/{provider}/pay-this-monthPlannedMark every unpaid payment due this month for a provider as paid, in one call.
/api/recurringPlannedList recurring bills.
/api/recurringPlannedAdd a recurring bill.
/api/recurring/{id}PlannedEdit a recurring bill.
/api/recurring/{id}PlannedDelete a recurring bill.
/api/recurring/{id}/logPlannedLog this month's occurrence as a transaction and roll the due date forward.
/api/recurring/{id}/activePlannedPause or resume a recurring bill.
/api/payslipsPlannedList payslips.
/api/payslipsPlannedAdd a payslip.
/api/payslips/{id}PlannedEdit a payslip.
/api/payslips/{id}PlannedDelete a payslip.
/api/tax/relief-typesPlannedList LHDN relief types for a given assessment year.
/api/tax/relief-typesPlannedAdd a relief type.
/api/tax/relief-types/{id}PlannedEdit a relief type.
/api/tax/relief-types/{id}PlannedDelete a relief type.
/api/tax/relief-types/starter-setPlannedAdd LHDN's standard relief types for the year.
/api/receiptsPlannedList scanned receipts.
/api/receipts/scanPlannedOCR-scan a receipt image or PDF.
/api/receipts/scan-textPlannedExtract structured data from pasted receipt text.
/api/receipts/{id}PlannedEdit a receipt's extracted details.
/api/receipts/{id}PlannedDelete a receipt.
/api/receipts/{id}/attachPlannedAttach a receipt to a transaction.
/api/accountsPlannedList accounts (bank, e-wallet, cash, ...).
/api/accountsPlannedAdd an account.
/api/accounts/{id}PlannedEdit an account.
/api/accounts/{id}PlannedDelete an account.
/api/keysPlannedList your API keys (without their secret values).
/api/keysPlannedCreate a new API key.
/api/keys/{id}PlannedRevoke an API key.
/api/dataPlannedPermanently delete all of your data.
/api/auth/loginPlannedLog in with email and password.
/api/auth/signupPlannedCreate an account.
/api/auth/logoutPlannedEnd the current session.
/api/auth/passwordPlannedChange your password.