API Reference
A single, versioned REST API for every Fleximinds engine. Base URL: https://api.fleximinds.dev/v1
Introduction
The Fleximinds API is organized around REST. It has predictable, resource-oriented URLs, accepts JSON and form-encoded request bodies, returns JSON responses, and uses standard HTTP response codes, authentication and verbs. Every response includes a confidence score and, where relevant, explainable reason codes.
Authentication
Authenticate with your secret API key in the Authorization header. Use sk_test_ keys in the sandbox and sk_live_ keys in production. Never expose a secret key in client-side code.
curl https://api.fleximinds.dev/v1/statements/parse \
-H "Authorization: Bearer sk_live_••••"Making requests
Send an idempotency key with any write request to safely retry without duplicating work. Responses always include a request id for support and audit.
POST /v1/risk/score
Content-Type: application/json
Idempotency-Key: idem_9f2
{
"amount": 4200,
"device_id": "dvc_9f2"
}200 OK
x-request-id: req_a1b2
{
"decision": "review",
"risk_score": 62,
"latency_ms": 41
}Endpoints
Each engine exposes a primary endpoint. Full schemas are available in the OpenAPI spec.
| Method | Endpoint | Product |
|---|---|---|
| POST | /v1/statements/parse | Statement Intelligence |
| POST | /v1/risk/score | Fraud & Risk Engine |
| POST | /v1/credit/decision | Credit Decisioning |
| POST | /v1/documents/extract | Document Intelligence |
Errors
Fleximinds uses conventional HTTP status codes. Codes in the 2xx range indicate success, 4xx indicate a client error, and 5xx indicate a server error.
Rate limits
Sandbox keys are limited to 60 requests/minute. Production limits scale with your plan; every response includes x-ratelimit-remaining headers so you can back off gracefully.
Webhooks
Subscribe to events for async jobs and review outcomes. Payloads are signed with your webhook secret so you can verify authenticity.
{
"type": "document.extracted",
"id": "evt_71c",
"data": { "document_id": "doc_9f2", "confidence": 0.986 }
}SDKs
Official SDKs wrap the API with types, retries and pagination.