API documentation
Run the same analysis as the workspace from your own software. Every successful call costs €0.05 and is charged to the Sensifai wallet of the person who created the key. Unsuccessful calls are free.
1. Create a key
Sign in, open the workspace and go to API keys. Give the key a name and, if you like, a monthly cap. The key is shown once. It looks like brewdial_live_… and only works for BrewDial.
2. Call the endpoint
POST https://brewdial.sensifai.com/api/v1/run
Authorization: Bearer YOUR_KEY (or X-API-Key: YOUR_KEY)
Content-Type: application/json
{
"mode": "diagnose",
"method": "espresso",
"tasteSourBitter": 2,
"tasteBody": 2,
"doseGrams": 18,
"yieldGrams": 38,
"brewTimeSeconds": 22,
"notes": "Sour taste with fast 22 second shot"
}3. Read the result
{
"id": "run_8b4e1f20",
"result": {
"mode": "diagnose",
"headline": "Channeled Fast Flow via Edge Bypass",
"confidence": "High",
"oneThingNext": {
"category": "Grind",
"title": "Grind 2 clicks finer",
"instruction": "Adjust your grinder 2 clicks finer and use a WDT tool to break clumps before tamping.",
"why": "Water found an easy path through loose edge channels, causing under-extracted sour notes in only 22 seconds."
},
"diagnosis": "The shot ran too fast (22s) with visible edge cratering in the spent puck.",
"visualEvidence": [
"Visible depression along puck outer perimeter",
"Thin pale crema ring indicating uneven extraction"
],
"unverifiedNote": "Could not verify tamp pressure or basket water distribution from photo alone.",
"metrics": {
"extractionBalance": 58,
"flowUniformity": 44,
"bodyClarity": 72
},
"targetRecipe": {
"brewer": "Espresso",
"doseGrams": 18,
"yieldGrams": 36,
"ratio": "1:2.0",
"waterTempC": 93,
"grindDescription": "Fine espresso grind with no visible clumps",
"totalTimeSeconds": 28
},
"timerSteps": [
{
"name": "Pre-infusion",
"durationSeconds": 6,
"targetGrams": 4,
"instruction": "Gentle low-pressure soak to saturate the puck evenly"
},
{
"name": "Full pressure pull",
"durationSeconds": 22,
"targetGrams": 36,
"instruction": "Maintain steady extraction stream into pre-warmed cup"
}
]
},
"charge": {
"amountEur": 0.05,
"currency": "EUR"
}
}Every response has an X-Request-Id header. Quote it when you contact support. Rate limit: 60 calls per minute per key, reported in X-RateLimit-Limit and X-RateLimit-Remaining.
Errors
Errors use one shape: {"error": {"code", "message", "requestId"}}.
| Status | Code | Meaning |
|---|---|---|
| 400 | INVALID_JSON, INPUT_TOO_SHORT, INPUT_TOO_LONG, CONSENT_REQUIRED | Fix the request. Not charged. |
| 401 | INVALID_API_KEY | Missing, malformed, revoked, or a key from another app. |
| 402 | PAYMENT_REQUIRED, KEY_SPEND_CAP_REACHED | Add funds or raise the key's cap. Not charged. |
| 413 | PAYLOAD_TOO_LARGE | Body over 256 KB. |
| 429 | RATE_LIMITED, TOO_MANY_PARALLEL_RUNS | Wait for the Retry-After seconds. |
| 502 | BILLING_UNAVAILABLE | The charge failed, so no result was returned. Not charged. |
| 503 | AI_UNAVAILABLE, WALLET_UNAVAILABLE | Temporary. Retry with backoff. Not charged. |
OpenAPI
Machine-readable description: https://brewdial.sensifai.com/api/v1/openapi
Privacy
Inputs and results are not stored. Responses never include the key owner’s identity. If your input contains personal data, you are responsible for having a legal basis to send it.