Get User Action Recommendations
GET /users/{user_id}/actionsGet a list recommended actions for a given user. Growth actions are weighted by expected impact. Higher weights means greater expected impact. Base weights reflect the influence of the action on the growth calculations based on past engagement.
Request Parameters
Path Parameters
| Name | Type | Description |
|---|---|---|
user_id required | string |
Query Parameters
| Name | Type | Description |
|---|---|---|
limit | integer | Default: 10 |
allow_repeats | boolean | Default: True |
Header Parameters
| Name | Type | Description |
|---|---|---|
program-id required | string |
Responses
200 Successful Response
UserNextActionList | application/json
| Name | Type | Properties |
|---|---|---|
actions required | array | items: {'$ref': '#/components/schemas/UserNextAction'} |
UserNextAction | application/json
| Name | Type | Properties |
|---|---|---|
event_type required | string | description: The behavior recommended in the action |
asset_id required | string | |
asset_name required | string | |
growth_weight required | number | description: The strength of the action recommendation for the given user. Higher values mean stronger recommendation. |
base_weight required | number | description: The historical weight of the action for the given user, accounting for recency and frequency. Higher values mean greater impact on the recommendations. NOTE: exclude values > 0 to recommend new actions only |
Response Example
{
"actions": [
{
"event_type": "string",
"asset_id": "string",
"asset_name": "string",
"growth_weight": "number",
"base_weight": "number"
}
]
}
404 User history not found
ErrorMessage | application/json
| Name | Type | Properties |
|---|---|---|
detail required | string |
422 Validation Error
HTTPValidationError | application/json
| Name | Type | Properties |
|---|---|---|
detail | array | items: {'$ref': '#/components/schemas/ValidationError'} |
ValidationError | application/json
| Name | Type | Properties |
|---|---|---|
loc required | array | items: {'anyOf': [{'type': 'string'}, {'type': 'integer'}]} |
msg required | string | |
type required | string |