Authentication Required
This endpoint requires API key authentication via Bearer token in the Authorization header.
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Path Parameters
Unique identifier for the customer to get recommendations for
Query Parameters
Whether to include segment-based recommendations in the response. Defaults to
false.
Filter recommendations by region (e.g., “BH” for Bahrain). Comma-separated
values for multiple regions.
Response
The API returns a JSON array of recommendation objects:
[
{
"recommendation_id": "00000000-1234-5678-9abc-def012345678",
"name": "Recommended For you",
"student_id": "00000000-9779-438e-ae0d-b52099f6be51",
"offers": [
"00000000-e9c5-4b43-9d46-4cd02baabc6a",
"00000002-c1f0-44d4-af13-32028f522f31",
"00000001-4d21-4206-8ced-ff2a11162bf0"
],
"type": "SELF"
}
]
| Field | Type | Description |
recommendation_id | string | Unique identifier for the recommendation |
name | string | Human-readable name for the recommendation set |
student_id | string | UUID of the customer (matches the path parameter) |
offers | array | Array of offer UUIDs that are recommended |
type | string | Type of recommendation (SELF or SEGMENT) |
Error Codes
| Status Code | Description |
| 200 | Recommendations retrieved successfully |
| 400 | Invalid customer_id format |
| 401 | Unauthorized - Invalid or missing API key |
| 404 | Customer not found |
| 500 | Internal server error |
Example
curl -X GET "https://api.hellocobi.com/v1/recommendations/customers/00000000-9779-438e-ae0d-b52099f6be51?includeSegments=false®ions=BH" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json"
Best Practices
- Caching: Cache recommendations for frequently requested customers to improve performance
- Error Handling: Implement proper error handling for cases where no recommendations are available
- Rate Limiting: Be mindful of API rate limits (1000 requests per minute)
- Validation: Validate the customer_id format before making the request
Need help? Contact our support team at [email protected]