Skip to main content
Glama

Create a Microsoft Advertising conversion goal (page visit or event)

msads_create_conversion_goal
Idempotent

Create a conversion goal tied to a UET tag (see msads_get_conversion_tracking for tag ids). goalType Url (default) counts a visit to a page (for example a thank-you page, via urlExpression); goalType Event counts a UET event whose action matches actionExpression (for example sign_up, which Caybl sends server-side through the UET Conversions API). 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 (duration, pages per visit, app install) are not offered here. Use dryRun to review.

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>",
      "tagId": "<tagId>",
      "category": "<category>"
    },
    "name": "msads_create_conversion_goal"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesGoal name, up to 100 characters, unique for the customer.
tagIdYesThe UET tag id that will record it, from msads_get_conversion_tracking.
dryRunNoPreview 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.
categoryYesWhat kind of conversion this is, e.g. Purchase or SubmitLeadForm.
goalTypeNoUrl (default) counts a page visit; Event counts a UET event by its action.Url
accountIdNoMicrosoft 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.
countTypeNoAll counts every conversion; Unique counts one per click.All
fixedValueNoOptional fixed value per conversion, in the account currency.
urlOperatorNoHow to match: Equals (default), BeginsWith, Contains or RegularExpression.Equals
urlExpressionNoUrl goals: the page address to match, e.g. /thank-you.
actionOperatorNoEvent goals: how to match the action. Default Equals.Equals
actionExpressionNoEvent goals: the event action to match, e.g. sign_up.
acknowledgeAutoTaggingNoMust be true: confirms you know adding a goal turns on automatic click tagging.
conversionWindowMinutesNoHow long after a click a visit still counts, in minutes. Default 43200 (30 days).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / properties / actionExpression
      Added value: +{
      +  "description": "Event goals: the event action to match, e.g. sign_up.",
      +  "type": "string"
      +}
    • addedInput schema / properties / actionOperator
      Added value: +{
      +  "default": "Equals",
      +  "description": "Event goals: how to match the action. Default Equals.",
      +  "enum": [
      +    "Equals",
      +    "BeginsWith",
      +    "RegularExpression",
      +    "Contains"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / goalType
      Added value: +{
      +  "default": "Url",
      +  "description": "Url (default) counts a page visit; Event counts a UET event by its action.",
      +  "enum": [
      +    "Url",
      +    "Event"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / urlExpression / description
      Previous value: -"The page address to match, e.g. /thank-you."New value: +"Url goals: the page address to match, e.g. /thank-you."
    • changedInput schema / required
      Previous value: -[
      -  "name",
      -  "tagId",
      -  "category",
      -  "urlExpression"
      -]New value: +[
      +  "name",
      +  "tagId",
      +  "category"
      +]
  2. Added

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=true): it discloses that the goal is created PAUSED and records nothing until enabled, that account scope is immutable, and that adding a goal triggers account-level automatic click tagging (msclkid) which is why acknowledgeAutoTagging: true is mandatory. It also explains that dryRun exists because Microsoft offers no validate-only mode and that it is free and cannot affect spend.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Dense but front-loaded: the goal-type decision comes first, followed by lifecycle/side-effect facts, then the required acknowledgement, then scope limits. A few clauses (the msclkid parenthetical, the dryRun sentence) could be tightened, but no sentence is filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 14-parameter, non-idempotent-looking mutation with an account-wide side effect and no output schema, the description covers the essentials: prerequisite tag source, mode selection, paused-on-create state, immutable scope, mandatory acknowledgement flag, and preview behavior. An agent can call this correctly without further discovery.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3; the description still adds real meaning by tying goalType to urlExpression/actionExpression, giving a concrete action example (`sign_up` via the UET Conversions API), and explaining the mandatory acknowledgeAutoTagging confirmation. It does not add much on the remaining enum/value params (countType, fixedValue, conversionWindowMinutes) beyond what the schema already says.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Create a conversion goal tied to a UET tag') and immediately splits the two supported modes, goalType Url vs Event, with the parameter each uses. It also names the sibling that supplies tag ids (msads_get_conversion_tracking), so an agent can distinguish it from update/status siblings without opening schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-to-use routing ('goalType Url (default) counts a visit... goalType Event counts a UET event') plus explicit exclusions ('Other goal types (duration, pages per visit, app install) are not offered here'). It also points to msads_set_conversion_goal_status as the follow-up required to activate the goal and recommends dryRun for review.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources