SendApp Docs
Log in

Compute a contact's AI fields

POST https://app.sendapp.ai/api/contacts/{id}/ai-fields
The AI reads the contact's conversations and fills in their custom fields of type ai, like the button in the contact card. Each computed field uses the account's AI credit.
Without async the answer comes once the computation is done (a few seconds per field) with the new values. With async: true the answer is 202 at once and the computation runs in the background: read the values later with GET /api/contacts/{id}/ai-fields.
To have them updated on their own after each conversation, choose the minutes in Custom fields → “Update AI fields automatically”.
Common errors: 401 API key missing or wrong — 403 plan expired, no API access or AI switched off for the account (code: account_ai_off) — 404 contact not found — 422 no AI field, unknown field or invalid language — 429 more than 30 AI requests a minute for the account: retry after the seconds given in Retry-After — 502 the AI did not answer (check the AI credit).

Parameters

5 · 2 required
apikey required
Your API Key (the X-API-Key header also works).
id required
Contact ID (integer, in the path). Use GET /api/contacts to find it.
fields optional
Only these AI fields: a list of names or IDs (comma-separated also works). If missing, all AI fields.
async optional
true to get the 202 answer at once and compute in the background.
locale optional
Language of the answers: it, en, es, fr, de, pt. If missing, the one chosen in Custom fields, otherwise Italian.
Need help with the integration? info@sendapp.live