What you can call
JSON under v1/. Money is integer minor units (cents) in USD, EUR, or GBP. Writes need a scope. The reader login and the public read-only API key cannot write.
Shared read-only tenant
- Username
reader - Password
reader-demo - Scopes
*:read - API key
ll_demo_read_0000000000000000
Sandbox
- Username
sandbox - Password
sandbox-demo - Each login gets its own tenant, copied from the seed
- Quota: 25 customers, 50 invoices, 100 payments
- Deleted 60 minutes after creation
curl
BASE is the URL of this page with no extra path. Behind the portfolio proxy that is the /portfolio/ledgerlite prefix. On a local process it is the origin, for example http://127.0.0.1:18809.
curl -s -X POST "$BASE/v1/auth/token" \ -H "Content-Type: application/x-www-form-urlencoded" \ -d "username=sandbox&password=sandbox-demo"
curl -s "$BASE/v1/invoices?limit=25" \ -H "Authorization: Bearer $TOKEN"
Endpoints
| Method | Path | Scope |
|---|---|---|
| POST | v1/auth/token | public |
| POST | v1/auth/refresh | public |
| GET | v1/me | any authenticated |
| GET, POST | v1/customers | customers:read / write |
| GET, PATCH, DELETE | v1/customers/{id} | customers:read / write |
| GET | v1/invoices and v1/invoices.csv | invoices:read |
| POST | v1/invoices | invoices:write, Idempotency-Key |
| POST | v1/invoices/{id}/payments | payments:write, Idempotency-Key |
| GET | v1/events | invoices:read |
| GET | v1/reports/aging | reports:read |
Build-time test report
Recorded by scripts/record_tests.py into results/test_report.json. These figures are that run, not a performance claim.
- Command
- python -m pytest -q --cov=app
- Exit code
- 0
- Summary
- 57 passed, 29 warnings in 36.18s
- Coverage
- TOTAL 1994 83 96%