Get Recommendation
POST
/v1/core/entities/{id}/recommendGenerates a behavioral recommendation based on historical interaction data.
WARNING
This API is restricted to the Builder and Enterprise billing tiers.
Request
json
{
"intent": "payment_recovery",
"lookback_days": 90,
"min_success_count": 1,
"agent_id": "billing-bot-v2"
}Parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | (In Path) The Entity UUID |
intent | string | Yes | Optionally filter history by a specific intent |
lookback_days | integer | No | Default: 90 |
min_success_count | integer | No | Minimum successes required for a confident recommendation (Default: 1) |
Response
json
{
"recommendation_id": "rec_01A2B3C",
"entity_id": "ent_550e...",
"intent": "payment_recovery",
"lookback_days": 90,
"data_sufficient": true,
"confidence_score": 0.85,
"primary": {
"api": "sendgrid",
"action_type": "send_email",
"raw_success_rate": 0.85,
"success_count": 17,
"total_count": 20,
"composite_score": 0.85,
"is_primary": true
},
"opportunity_set": [
{
"api": "sendgrid",
"action_type": "send_email",
"composite_score": 0.85
},
{
"api": "twilio",
"action_type": "send_sms",
"composite_score": 0.05
}
]
}