Custom agents via REST
MCP is optional. Any agent, script, or backend can use the REST API with the same organizations, credits, and double-entry rules.
When to use REST
- Your runtime does not speak MCP
- You want deterministic HTTP calls in CI or workers
- You are wrapping Crane Ledger inside your own agent framework
Bootstrap
curl -s https://api.craneledger.ai/accounts/master \
-H "Content-Type: application/json" \
-d '{"name":"Agent Org","base_currency_code":"USD"}'
Save api_key and organization_id. Authenticate every request:
Authorization: Bearer ha_live_…
Minimal example
curl "https://api.craneledger.ai/organizations/ORG_ID/accounts" \
-H "Authorization: Bearer ha_live_…"
Writes (create account, post transaction, create invoice) cost 1 credit each. Reads and reports are free.
Next steps
- Quick Start — AI-first path, with optional REST section
- Your First Transaction — full REST walkthrough
- API Reference
- Authentication
- Agent-oriented overview: llms.txt and pricing.md
Related
- Connect your AI overview — prefer MCP when your client supports it
- Drafts & Approval
Need help?
Create a free account (GitHub, Google, Apple, or email) to access our support portal. Once signed in, use the Support tab in your dashboard to submit a support ticket — no GitHub account required. Our team typically responds within 24 hours.
- ✨ For LLMs/AI assistants: Read our structured API reference
- Legal: Terms of Service · Privacy Policy