Skip to main content
Glama

Set Webhook

set_webhook
Destructive

Create or update a business outbound webhook (URL + subscribed events). Returns a webhook secret on first creation only. Mirrors POST /api/v1/webhooks.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoExisting webhook ID to update (omit to create new).
eventsNoEvent types to subscribe to (see get_webhook for the supported list).
presetNoStart the body from a CRM field map. Presets are editable starting points, not exact vendor formats. Ignored when payload_template is also sent.
is_activeNoEnable or disable delivery.
body_formatNojson (default) or form (application/x-www-form-urlencoded, nested keys flattened with dots).
business_idNoBusiness ID (optional only when the token can access exactly one business).
descriptionNoHuman label for this webhook.
http_methodNoHTTP method for delivery (default POST).
webhook_urlYesHTTPS/HTTP destination URL for event delivery.
custom_headersNoExtra headers the CRM needs, as { "Header-Name": "value" } (max 20). A null value keeps the saved value for that name. Content-Type, Host, Content-Length and X-KaiCalls-* cannot be set. Values are never returned.
payload_templateNoShape the body for a CRM: { "fields": { "<their field>": "<path>" | { "value": <fixed> } } }. A path reads the standard event body (e.g. "data.phone", "occurred_at"); "a|b" takes the first with a value; a dot in the field name nests it ("contact.phone"). Missing paths send null. null restores the standard body.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNoPresent when success is false
eventsNo
messageNo
successYesWhether the tool completed successfully
webhookNo
business_idNo
webhook_secretNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / properties / body_format
      Added value: +{
      +  "description": "json (default) or form (application/x-www-form-urlencoded, nested keys flattened with dots).",
      +  "enum": [
      +    "json",
      +    "form"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / custom_headers
      Added value: +{
      +  "description": "Extra headers the CRM needs, as { \"Header-Name\": \"value\" } (max 20). A null value keeps the saved value for that name. Content-Type, Host, Content-Length and X-KaiCalls-* cannot be set. Values are never returned.",
      +  "type": [
      +    "object",
      +    "null"
      +  ]
      +}
    • addedInput schema / properties / http_method
      Added value: +{
      +  "description": "HTTP method for delivery (default POST).",
      +  "enum": [
      +    "POST",
      +    "PUT",
      +    "PATCH"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / payload_template
      Added value: +{
      +  "description": "Shape the body for a CRM: { \"fields\": { \"<their field>\": \"<path>\" | { \"value\": <fixed> } } }. A path reads the standard event body (e.g. \"data.phone\", \"occurred_at\"); \"a|b\" takes the first with a value; a dot in the field name nests it (\"contact.phone\"). Missing paths send null. null restores the standard body.",
      +  "type": [
      +    "object",
      +    "null"
      +  ]
      +}
    • addedInput schema / properties / preset
      Added value: +{
      +  "description": "Start the body from a CRM field map. Presets are editable starting points, not exact vendor formats. Ignored when payload_template is also sent.",
      +  "enum": [
      +    "generic_crm",
      +    "litify",
      +    "filevine",
      +    "clio_grow",
      +    "lead_docket",
      +    "gohighlevel"
      +  ],
      +  "type": "string"
      +}
  2. Added

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnly=false, destructive=true, idempotent=false and openWorld=true, so the safety profile is covered. The description adds genuinely non-structured behavior: the webhook secret is returned only on first creation, and the operation mirrors POST /api/v1/webhooks. It stops short of explaining what an update overwrites or how disabling affects in-flight deliveries.

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

Conciseness5/5

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

Three short sentences, front-loaded with the verb and resource, then the non-obvious secret behavior, then the API mirror. No filler and no redundancy.

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

Completeness4/5

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

With an output schema present, return-value detail is unnecessary, yet the description still flags the one return nuance an agent must know (secret on first creation only). Combined with 100% schema coverage and explicit annotations, the definition is nearly complete; only the create-vs-update overwrite semantics and business scoping guidance are unaddressed.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema carries the parameter semantics (presets, payload_template, custom_headers, body_format, etc.). The description only restates 'URL + subscribed events', adding little beyond the structured field docs; baseline 3 is appropriate.

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?

States a specific verb+resource pair ('Create or update a business outbound webhook') and clarifies the two operational modes (create vs update) plus the payload surface (URL + subscribed events). It does not explicitly differentiate from siblings like get_webhook or delete_webhook, but those are self-evidently distinct names.

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

Usage Guidelines3/5

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

Implied usage is present through the 'create or update' framing and the schema note that omitting id creates a new webhook, but the description itself gives no explicit when-to-use guidance, no prerequisites (auth scope, business_id requirement), and does not route the agent away from get_webhook/delete_webhook.

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.