API Reference
Solvory API v1 — REST + JSON, Bearer-token auth via Laravel Sanctum.
Base URL
https://your-domain.com/api/v1
Authentication
Every authenticated request must include an Authorization: Bearer <token> header. Get a token by POSTing to /auth/login. Tokens issued by /auth/login have no expiry; impersonation tokens issued by admins expire in 30 minutes.
curl -H "Authorization: Bearer YOUR_TOKEN" \
https://your-domain.com/api/v1/auth/me
On the menu
Auth
Body: { name, email, password, password_confirmation }. Returns { token, user }. Sends a verification email.
Body: { email, password }. Returns { token, user }. Throttled at 5 attempts/min.
Returns the authenticated user.
Revokes the current token.
Body: { current_password, password, password_confirmation }. Revokes all other sessions on success.
Debts
Paginated list. Filters: status, type_id, currency_code, archived, per_page.
Required: type_id, currency_code, amount, direction, counterpart_name. Direction is owed_by_me or owed_to_me.
Single debt with payments and settlement proposals.
Update any field except the id.
Soft-delete. Reversible for 30 days.
Hide without deleting.
CSV download of every debt for the user. UTF-8 + BOM.
Payments
Body: { amount, currency_code?, paid_at?, method?, notes? }. Method: cash | transfer | gift | written_off | mutual_agreement | other. Status flips to paid when remaining balance reaches zero.
Settlements
Propose a partial settlement. Body: { proposed_amount, message? }.
Attachments
List attachments (receipts, screenshots, IOUs). Each item has a public url.
Multipart with file field. Max 10 MB, types: jpg, png, webp, heic, pdf. Limit 10 per debt.
Removes the file from disk and the row from the DB.
Notifications
Recent in-app notifications, newest first. Includes unread count.
Mark every unread notification as read.
Reports
Body: { target_type, target_id, category, description? }. Limited to 10 per user per day.
Sync (mobile offline-first)
Upload local mutations. Body: array of { entity, op, payload, client_updated_at }. Server applies last-write-wins.
Query: since (ISO 8601). Returns rows changed after that timestamp.
Reference data
Active locales. Public — no auth required.
Full UI translation map for a locale. Cached aggressively.
Supported currencies with codes and symbols. Public.
Built-in debt categories (food, rent, loan, etc.). Public.
Errors
All errors return JSON: { "message": "..." }. Validation errors include an errors object with field-keyed arrays. Standard codes:
- 401 — missing or invalid token
- 403 — authenticated but not allowed (wrong owner, not admin)
- 404 — resource not found
- 422 — validation failed
- 429 — rate-limited
Need help?
Try the FAQ or drop us a line.