Create goal
create_goalCreate a conversion goal. Each matching event records a conversion credited to the last email sent or clicked within window_days. Returns the goal. Errors: goal_exists, invalid_window (1 to 90), invalid_event_name. Next: track_event to convert, then goal_stats.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>",
"event_name": "<event_name>"
},
"name": "create_goal"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | A unique name, such as "Upgraded to pro". | |
| conditions | No | Optional property conditions, same shape as for sync rules. | |
| event_name | Yes | The event that counts as a conversion. | |
| window_days | No | Attribution window in days, 1 to 90 (default 7): an email sent or clicked this long before gets the credit. | |
| value_property | No | Property holding the revenue of the event, such as "amount". |