Quickstart
Get started with Moneyline in 5 minutes. Create a submission, upload a bank statement, and get analytics.
Prerequisites
- Moneyline API running (see Self-Hosting) or access to hosted instance
- API key (
ml_live_*for production,ml_test_*for sandbox)
Base URL
# Self-hosted (default)
http://localhost:3100
# Production
https://api.moneyline.aiAll examples below use localhost:3100. Replace with your base URL.
Authentication
Every request needs an API key via Authorization: Bearer <key> or X-Api-Key header.
export ML_KEY="ml_live_your_api_key_here"1. Create a Submission
curl -X POST http://localhost:3100/v1/submissions \
-H "Authorization: Bearer $ML_KEY" \
-H "Content-Type: application/json" \
-d '{
"external_id": "deal-001",
"name": "Acme Corp Application",
"company_info": {
"name": "Acme Corp",
"ein": "12-3456789"
}
}'Response:
{
"data": {
"id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
"tenantId": "...",
"externalId": "deal-001",
"name": "Acme Corp Application",
"status": "new",
"metadata": {},
"companyInfo": { "name": "Acme Corp", "ein": "12-3456789" },
"createdAt": "2026-04-16T00:00:00.000Z"
}
}2. Upload a Document
Upload via multipart/form-data:
curl -X POST http://localhost:3100/v1/submissions/{submission_id}/documents \
-H "Authorization: Bearer $ML_KEY" \
-F "file=@./chase-jan-2024.pdf"The document is automatically classified (bank statement, tax return, P&L, etc.) and queued for parsing.
3. List Transactions
After processing, transactions are extracted and enriched:
curl http://localhost:3100/v1/transactions?submission_id={submission_id} \
-H "Authorization: Bearer $ML_KEY"4. Get Scorecard
curl http://localhost:3100/v1/submissions/{submission_id}/scorecard \
-H "Authorization: Bearer $ML_KEY"5. Get Cashflow Analysis
curl http://localhost:3100/v1/submissions/{submission_id}/cashflow?date_range=last_90_days \
-H "Authorization: Bearer $ML_KEY"6. Search Across Everything
curl "http://localhost:3100/v1/search?q=amazon&type=submissions,transactions" \
-H "Authorization: Bearer $ML_KEY"7. Check Usage
curl http://localhost:3100/v1/usage \
-H "Authorization: Bearer $ML_KEY"8. Portfolio-Level Analytics
curl http://localhost:3100/v1/analytics/portfolio \
-H "Authorization: Bearer $ML_KEY"Error Handling
All errors follow a consistent format with error codes, doc links, and request IDs:
{
"error": {
"type": "invalid_request_error",
"code": "invalid_document_class",
"message": "Invalid document_class 'bank_statment'. Did you mean 'bank_statement'?",
"param": "document_class",
"doc_url": "https://docs.moneyline.ai/errors#invalid-document-class",
"request_id": "req_abc123"
}
}SDKs
Python
from moneyline import Moneyline
client = Moneyline(api_key="ml_live_your_api_key")
sub = client.submissions.create(external_id="deal-001", name="Acme Corp")
scorecard = client.submissions.scorecard(sub.id)Node.js
import { Moneyline } from '@moneyline/sdk';
const client = new Moneyline({ apiKey: 'ml_live_your_api_key' });
const sub = await client.submissions.create({ externalId: 'deal-001' });
const scorecard = await client.submissions.scorecard(sub.id);Go
client := moneyline.New("ml_live_your_api_key")
sub, _ := client.Submissions.Create(ctx, &moneyline.CreateSubmission{
ExternalID: "deal-001",
Name: "Acme Corp",
})
scorecard, _ := client.Submissions.Scorecard(ctx, sub.ID)Next Steps
- API Reference — Full endpoint documentation (200+ endpoints)
- Concepts — Understand the data model
- Webhooks — Real-time event notifications
- SDK Parity — API ↔ SDK method mapping