Create a Microsoft Advertising page-visit conversion goal
msads_create_conversion_goalCreate a conversion goal that counts a visit to a page (for example a thank-you page) as a conversion, tied to a UET tag (see msads_get_conversion_tracking for tag ids). It is created PAUSED, so it records nothing until turned on with msads_set_conversion_goal_status. The goal's scope is the account and cannot be changed later. Microsoft turns on automatic click tagging (an msclkid parameter on your landing page URLs) for the account when a conversion goal is added. Because that changes a setting beyond the goal, you must pass acknowledgeAutoTagging: true. Other goal types (events, duration, pages per visit) are not offered here. Use dryRun to review.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Goal name, up to 100 characters, unique for the customer. | |
| tagId | Yes | The UET tag id that will record it, from msads_get_conversion_tracking. | |
| dryRun | No | Preview only. Microsoft has no validate-only mode, so Caybl reads the current value and shows exactly what would change (before and after) without sending anything. Free, and cannot affect spend. | |
| category | Yes | What kind of conversion this is, e.g. Purchase or SubmitLeadForm. | |
| accountId | No | Microsoft Advertising account id or account number (e.g. 'F123ABCD'), as listed by msads_list_accounts. Only needed when the sign-in can reach more than one account. | |
| countType | No | All counts every conversion; Unique counts one per click. | All |
| fixedValue | No | Optional fixed value per conversion, in the account currency. | |
| urlOperator | No | How to match: Equals (default), BeginsWith, Contains or RegularExpression. | Equals |
| urlExpression | Yes | The page address to match, e.g. /thank-you. | |
| acknowledgeAutoTagging | No | Must be true: confirms you know adding a goal turns on automatic click tagging. | |
| conversionWindowMinutes | No | How long after a click a visit still counts, in minutes. Default 43200 (30 days). |