Skip to main content
Glama

Create AI Display CreativeDocuments from objective and requestedFormats without pre-existing creatives. Optional outputs requests static JPEG/PNG delivery after save_to_studio while retaining the editable document. Export existing versions with export_creative. Build and save existing Studio creative records. When campaignId or campaignName is supplied, LeanrIQ resolves the complete persisted campaign inventory, uses each saved brief, approved asset set, and eligible global or advertiser template, then runs the canonical Studio Gold build path. Campaign-scoped calls save by default; use persistence preview_only only for an unsaved ad-hoc preview. (deprecated alias)

leanriq_build_ad
Idempotent

Create AI Display CreativeDocuments from objective and requestedFormats without pre-existing creatives. Optional outputs requests static JPEG/PNG delivery after save_to_studio while retaining the editable document. Export existing versions with export_creative. Build and save existing Studio creative records. When campaignId or campaignName is supplied, LeanrIQ resolves the complete persisted campaign inventory, uses each saved brief, approved asset set, and eligible global or advertiser template, then runs the canonical Studio Gold build path. Campaign-scoped calls save by default; use persistence preview_only only for an unsaved ad-hoc preview.. Deprecated alias for build_ad. Classification: creates billable AI usage. Execution: durable. Task support: optional. Mutation modes: validate_only, preview_only, execute. Partial failure policy: completed_items_not_rolled_back. The returned JSON is internal application state for LeanrIQ and ChatGPT orchestration. Use assistantSummary first when responding to the user. Never display raw JSON, data, or meta unless the user explicitly asks for raw JSON. Mention IDs only when useful for follow-up or debugging. Prefer concise, human language, highlight the most useful insight, and suggest the next best LeanrIQ action. If idempotencyKey is omitted on a mutation, the MCP layer derives a deterministic retry key from the tool and business arguments so an accidental identical replay cannot create duplicate work. For a mutation when more than one seat is authorised, seatId or seatName must be supplied on that exact tool call; a remembered or previously selected seat is not sufficient for a write.

Input Schema

NameRequiredDescriptionDefault
briefNo
forceNo
inputNo
assetsNo
promptNo
seatIdNo
taskIdNo
assetIdNo
outputsNoOptional editable/static JPEG/PNG delivery requirements. Studio persistence is required for static output.
audienceNo
campaignNo
creativeNo
flightIdNo
seatNameNo
templateNo
accountIdNo
objectiveNo
advertiserNo
campaignIdNo
creativeIdNo
templateIdNo
creativeIdsNo
persistenceNo
advertiserIdNo
instructionsNo
sourceLocaleNo
targetMarketNo
contentLocaleNo
marketContextNo
targetMarketsNo
contentLocalesNo
idempotencyKeyNo
requestedFormatsNo
defaultContentLocaleNo
marketLanguageProfileNo
resolvedContentLocaleNo
skipTraffickedRebuildNo
languageVariantGroupIdNo
requestedOutputLocalesNo
supportedContentLocalesNo

Output Schema

NameRequiredDescriptionDefault
dataYes
metaYes
errorNo
statusYes
assistantSummaryYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed13 schema fields changed
    • addedInput schema / properties / contentLocale
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / contentLocales
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 20,
      +  "type": "array"
      +}
    • addedInput schema / properties / defaultContentLocale
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / languageVariantGroupId
      Added value: +{
      +  "maxLength": 160,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / marketContext
      Added value: +{
      +  "properties": {
      +    "currency": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "targetMarket": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "targetMarkets": {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "timeZone": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    }
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / marketLanguageProfile
      Added value: +{
      +  "additionalProperties": {},
      +  "propertyNames": {
      +    "type": "string"
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / outputs
      Added value: +{
      +  "description": "Optional editable/static JPEG/PNG delivery requirements. Studio persistence is required for static output.",
      +  "items": {
      +    "anyOf": [
      +      {
      +        "additionalProperties": false,
      +        "properties": {
      +          "type": {
      +            "const": "editable",
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "type"
      +        ],
      +        "type": "object"
      +      },
      +      {
      +        "additionalProperties": false,
      +        "properties": {
      +          "format": {
      +            "enum": [
      +              "jpeg",
      +              "png"
      +            ],
      +            "type": "string"
      +          },
      +          "maxBytes": {
      +            "exclusiveMinimum": 0,
      +            "maximum": 9007199254740991,
      +            "type": "integer"
      +          },
      +          "quality": {
      +            "maximum": 100,
      +            "minimum": 1,
      +            "type": "integer"
      +          },
      +          "type": {
      +            "const": "static",
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "type"
      +        ],
      +        "type": "object"
      +      },
      +      {
      +        "enum": [
      +          "editable",
      +          "static_jpeg",
      +          "static_png"
      +        ],
      +        "type": "string"
      +      }
      +    ]
      +  },
      +  "maxItems": 8,
      +  "type": "array"
      +}
    • addedInput schema / properties / requestedOutputLocales
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 20,
      +  "type": "array"
      +}
    • addedInput schema / properties / resolvedContentLocale
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / sourceLocale
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / supportedContentLocales
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 20,
      +  "type": "array"
      +}
    • addedInput schema / properties / targetMarket
      Added value: +{
      +  "maxLength": 160,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / targetMarkets
      Added value: +{
      +  "items": {
      +    "maxLength": 160,
      +    "minLength": 1,
      +    "type": "string"
      +  },
      +  "maxItems": 50,
      +  "type": "array"
      +}
  2. First observed

TDQS

A3.5/5.0
Behavior4/5

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

Goes well beyond the annotations (readOnlyHint=false, idempotentHint=true) by disclosing billable AI usage classification, durable execution, mutation modes (validate_only/preview_only/execute), and a partial-failure policy of completed_items_not_rolled_back. It also explains deterministic idempotencyKey derivation and the requirement that seatId/seatName be supplied on the exact mutation call. Rich and non-obvious.

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

Conciseness3/5

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

The description redundantly reproduces the entire title text verbatim before adding operational metadata, which is wasted space. The appended classification/execution/idempotency content is valuable, but the overall block is a dense wall that is not optimally front-loaded or trimmed.

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

Completeness3/5

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

An output schema exists, so return-value explanation is not required, and the description covers deprecation, campaign resolution, persistence modes, seat requirement, and idempotency. However, for a 40-parameter build tool with 3% schema coverage, the behavioral picture is adequate but the parameter surface is largely unexplained.

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

Parameters2/5

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

With 40 parameters at 3% schema coverage, the schema documents almost nothing, so the description must carry the load. It explains persistence semantics (preview_only vs save_to_studio), seatId/seatName, idempotencyKey, and campaignId/campaignName resolution, but leaves the vast majority of parameters (brief, input, assets, audience, template, outputs shape, locale fields) undefined.

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

Purpose4/5

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

The description states a specific verb and resource (create AI Display CreativeDocuments from objective and requestedFormats) and distinguishes scope against siblings by noting export_creative handles existing versions and build_ad is the canonical non-alias tool. The '(deprecated alias)' and 'Deprecated alias for build_ad' notes are decisive routing information. It is marred only by dense verbosity that buries the core purpose.

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

Usage Guidelines4/5

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

Gives concrete when-to-use conditions: no pre-existing creatives, campaign-scoped resolution when campaignId/campaignName is supplied, and save-by-default with preview_only reserved for unsaved ad-hoc previews. It explicitly routes export of existing versions to export_creative. No explicit when-not conditions beyond the alias/deprecation note, so not a 5.

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