{
  "name": "coldbirds-sequence",
  "version": "1.0.0",
  "description": "Control your cold email campaigns, contacts, and mailboxes from AI assistants like Claude Desktop, Cursor, and Windsurf.",
  "command": "npx",
  "args": [
    "-y",
    "@coldbirds/mcp-server"
  ],
  "capabilities": {
    "tools": {
      "listChanged": false
    }
  },
  "env": {
    "COLDBIRDS_API_KEY": {
      "description": "Your API key from Settings → API Keys (format: sk_live_...)",
      "required": true
    },
    "COLDBIRDS_API_URL": {
      "description": "API base URL (defaults to https://sequencer.coldbirds.com)",
      "required": false,
      "default": "https://sequencer.coldbirds.com"
    }
  },
  "tools": [
    {
      "name": "get_dashboard",
      "title": "Get Dashboard",
      "description": "Returns the high-level account dashboard: active campaign count, sends today, 7-day open/reply/bounce rates, a 14-day daily-send series, and the top 5 campaigns by sent volume. Use this for 'how is my outreach doing?' style questions.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "timezone": {
            "type": "string",
            "description": "IANA timezone (e.g. America/New_York) used to compute the 'sends today' boundary. Defaults to the account's preference, or UTC."
          }
        },
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "activeCampaigns": { "type": "integer", "description": "Campaigns currently in ACTIVE status." },
          "sendsToday": { "type": "integer", "description": "Emails sent since local midnight." },
          "sentLast7d": { "type": "integer" },
          "repliedLast7d": { "type": "integer", "description": "Distinct send jobs with at least one reply (last 7d)." },
          "openedLast7d": { "type": "integer", "description": "Distinct send jobs with at least one open (last 7d)." },
          "bouncedLast7d": { "type": "integer" },
          "replyRate": { "type": "number", "description": "repliedLast7d / sentLast7d (0..1)." },
          "openRate": { "type": "number", "description": "openedLast7d / sentLast7d (0..1)." },
          "dailySends": {
            "type": "array",
            "description": "14 daily buckets, oldest first.",
            "items": {
              "type": "object",
              "properties": {
                "date": { "type": "string", "description": "UTC YYYY-MM-DD." },
                "sent": { "type": "integer" },
                "replied": { "type": "integer" }
              },
              "required": ["date", "sent", "replied"]
            }
          },
          "topCampaigns": {
            "type": "array",
            "description": "Up to 5 campaigns ranked by sent volume in the last 7d.",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string" },
                "name": { "type": "string" },
                "sent": { "type": "integer" },
                "opened": { "type": "integer" },
                "replied": { "type": "integer" }
              },
              "required": ["id", "name", "sent", "opened", "replied"]
            }
          }
        },
        "required": [
          "activeCampaigns",
          "sendsToday",
          "sentLast7d",
          "repliedLast7d",
          "openedLast7d",
          "bouncedLast7d",
          "replyRate",
          "openRate",
          "dailySends",
          "topCampaigns"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/dashboard"
      }
    },
    {
      "name": "get_contact_list_analytics",
      "title": "Get Contact List Analytics",
      "description": "Returns deliverability, segmentation, and hygiene analytics for a contact list — the same multi-deck snapshot the in-app list dashboard shows. Includes the stoplight (sendable / risky / unsendable / unverified), validation status breakdown, provider mix (Google / Microsoft / other / unknown), validation freshness, top sending domains and free-mail count, suppression count, campaigns currently enrolling these contacts elsewhere (collision warning), standard + custom field coverage, top job titles, and contact-age cohorts. Use this to answer 'is this list ready to send?' or 'what does this list look like?' questions.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "listId": {
            "type": "string",
            "description": "Contact list ID."
          }
        },
        "required": ["listId"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "listId": { "type": "string" },
          "listName": { "type": "string" },
          "total": { "type": "integer", "description": "Total non-deleted contacts in the list." },
          "stoplight": {
            "type": "object",
            "description": "High-level decision-driving counts.",
            "properties": {
              "total": { "type": "integer" },
              "sendable": { "type": "integer", "description": "VALID contacts." },
              "risky": { "type": "integer", "description": "CATCH_ALL + ROLE + DISPOSABLE." },
              "unsendable": { "type": "integer", "description": "INVALID + BOUNCED + FAILED + UNSUBSCRIBED + COMPLAINED." },
              "unverified": { "type": "integer", "description": "UNKNOWN + PENDING." }
            },
            "required": ["total", "sendable", "risky", "unsendable", "unverified"]
          },
          "validationStatus": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "status": { "type": "string", "description": "ContactStatus enum value." },
                "count": { "type": "integer" }
              },
              "required": ["status", "count"]
            }
          },
          "providers": {
            "type": "array",
            "description": "Email provider mix derived from MX lookups.",
            "items": {
              "type": "object",
              "properties": {
                "provider": { "type": "string", "enum": ["GOOGLE", "MICROSOFT", "OTHER", "UNKNOWN"] },
                "count": { "type": "integer" }
              },
              "required": ["provider", "count"]
            }
          },
          "freshness": {
            "type": "array",
            "description": "How recently each contact's email was validated.",
            "items": {
              "type": "object",
              "properties": {
                "bucket": { "type": "string", "enum": ["LT_30D", "D30_90", "GT_90D", "NEVER"] },
                "count": { "type": "integer" }
              },
              "required": ["bucket", "count"]
            }
          },
          "topDomains": {
            "type": "array",
            "description": "Top 10 email domains by contact count.",
            "items": {
              "type": "object",
              "properties": {
                "domain": { "type": "string" },
                "count": { "type": "integer" }
              },
              "required": ["domain", "count"]
            }
          },
          "freeMailCount": { "type": "integer", "description": "Contacts on free providers (gmail/yahoo/outlook/...)." },
          "suppressedCount": { "type": "integer", "description": "Suppressed (UNSUBSCRIBED / COMPLAINED / global suppression)." },
          "activeEnrollmentsElsewhere": {
            "type": "array",
            "description": "Campaigns currently enrolling some of this list's contacts — useful to avoid collision.",
            "items": {
              "type": "object",
              "properties": {
                "campaignId": { "type": "string" },
                "campaignName": { "type": "string" },
                "status": { "type": "string", "description": "CampaignStatus enum (DRAFT, ACTIVE, PAUSED)." },
                "dailyLimit": { "type": "integer", "description": "Per-mailbox daily send cap. Total daily volume = this value times the attached mailbox count." },
                "contactCount": { "type": "integer" }
              },
              "required": ["campaignId", "campaignName", "status", "dailyLimit", "contactCount"]
            }
          },
          "fieldCoverage": {
            "type": "array",
            "description": "Standard field population counts.",
            "items": {
              "type": "object",
              "properties": {
                "field": { "type": "string", "enum": ["firstName", "lastName", "company", "title"] },
                "populated": { "type": "integer" }
              },
              "required": ["field", "populated"]
            }
          },
          "customFields": {
            "type": "array",
            "description": "Custom field coverage and value distribution.",
            "items": {
              "type": "object",
              "properties": {
                "key": { "type": "string" },
                "populated": { "type": "integer" },
                "distinct": { "type": "integer" },
                "topValues": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "value": { "type": "string" },
                      "count": { "type": "integer" }
                    },
                    "required": ["value", "count"]
                  }
                },
                "categorical": { "type": "boolean", "description": "True when distinct <= 20." },
                "numeric": {
                  "type": "object",
                  "nullable": true,
                  "description": "Set when >= 80% of values parse as numbers.",
                  "properties": {
                    "min": { "type": "number" },
                    "max": { "type": "number" },
                    "median": { "type": "number" },
                    "bins": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "from": { "type": "number" },
                          "to": { "type": "number" },
                          "count": { "type": "integer" }
                        },
                        "required": ["from", "to", "count"]
                      }
                    }
                  },
                  "required": ["min", "max", "median", "bins"]
                }
              },
              "required": ["key", "populated", "distinct", "topValues", "categorical", "numeric"]
            }
          },
          "topTitles": {
            "type": "array",
            "description": "Top 20 job titles by contact count.",
            "items": {
              "type": "object",
              "properties": {
                "title": { "type": "string" },
                "count": { "type": "integer" }
              },
              "required": ["title", "count"]
            }
          },
          "addedAt": {
            "type": "array",
            "description": "When contacts were added to the list.",
            "items": {
              "type": "object",
              "properties": {
                "bucket": { "type": "string", "enum": ["THIS_WEEK", "THIS_MONTH", "M1_3", "M3_6", "GT_6M"] },
                "count": { "type": "integer" }
              },
              "required": ["bucket", "count"]
            }
          },
          "computedAt": { "type": "string", "description": "ISO timestamp when this snapshot was computed (cached for 5 minutes)." }
        },
        "required": [
          "listId",
          "listName",
          "total",
          "stoplight",
          "validationStatus",
          "providers",
          "freshness",
          "topDomains",
          "freeMailCount",
          "suppressedCount",
          "activeEnrollmentsElsewhere",
          "fieldCoverage",
          "customFields",
          "topTitles",
          "addedAt",
          "computedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/lists/{listId}/analytics"
      }
    },
    {
      "name": "get_account",
      "title": "Get Account",
      "description": "Returns the authenticated account (name, email, ID) for the current API key.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Account ID."
          },
          "name": {
            "type": [
              "string",
              "null"
            ],
            "description": "Display name."
          },
          "email": {
            "type": "string",
            "format": "email",
            "description": "Account email."
          }
        },
        "required": [
          "id",
          "email"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/me"
      }
    },
    {
      "name": "list_campaigns",
      "title": "List Campaigns",
      "description": "Lists email campaigns for the account. Supports filtering by status and cursor-based pagination. Pass the returned nextCursor to fetch the next page.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "DRAFT",
              "ACTIVE",
              "PAUSED",
              "COMPLETED",
              "ARCHIVED"
            ],
            "description": "Filter campaigns by status."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from the previous response's nextCursor."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 25,
            "description": "Number of campaigns to return per page."
          }
        },
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "DRAFT",
                    "ACTIVE",
                    "PAUSED",
                    "COMPLETED",
                    "ARCHIVED"
                  ]
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "name",
                "status",
                "createdAt",
                "updatedAt"
              ]
            }
          },
          "pagination": {
            "type": "object",
            "properties": {
              "nextCursor": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Pass this value as the cursor parameter to fetch the next page. Null when no more pages."
              },
              "hasMore": {
                "type": "boolean"
              }
            },
            "required": [
              "nextCursor",
              "hasMore"
            ]
          }
        },
        "required": [
          "data"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns"
      }
    },
    {
      "name": "get_campaign",
      "title": "Get Campaign",
      "description": "Returns full details of a single campaign by ID including configuration, steps count, and scheduling settings.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "DRAFT",
              "ACTIVE",
              "PAUSED",
              "COMPLETED",
              "ARCHIVED"
            ]
          },
          "stepsCount": {
            "type": "integer"
          },
          "dailyLimit": {
            "type": "integer",
            "description": "Per-mailbox daily send cap. Total daily volume = this value times the attached mailbox count."
          },
          "trackOpens": {
            "type": "boolean"
          },
          "trackClicks": {
            "type": "boolean"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "status",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{id}"
      }
    },
    {
      "name": "get_campaign_stats",
      "title": "Get Campaign Stats",
      "description": "Returns aggregate email performance metrics for a campaign: sent, opened, clicked, replied, bounced counts and calculated rates.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string"
          },
          "sent": {
            "type": "integer",
            "description": "Total emails sent."
          },
          "opened": {
            "type": "integer",
            "description": "Unique opens."
          },
          "clicked": {
            "type": "integer",
            "description": "Unique clicks."
          },
          "replied": {
            "type": "integer",
            "description": "Reply count."
          },
          "bounced": {
            "type": "integer",
            "description": "Bounce count."
          },
          "openRate": {
            "type": "number",
            "description": "Open rate as percentage (0-100)."
          },
          "clickRate": {
            "type": "number",
            "description": "Click rate as percentage (0-100)."
          },
          "replyRate": {
            "type": "number",
            "description": "Reply rate as percentage (0-100)."
          },
          "bounceRate": {
            "type": "number",
            "description": "Bounce rate as percentage (0-100)."
          }
        },
        "required": [
          "campaignId",
          "sent",
          "opened",
          "clicked",
          "replied",
          "bounced",
          "openRate",
          "clickRate",
          "replyRate",
          "bounceRate"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{id}/stats"
      }
    },
    {
      "name": "pause_campaign",
      "title": "Pause Campaign",
      "description": "Transitions an ACTIVE campaign to PAUSED. All pending sends are held until resumed.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID to pause."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "PAUSED"
            ]
          }
        },
        "required": [
          "id",
          "status"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{id}/pause"
      }
    },
    {
      "name": "resume_campaign",
      "title": "Resume Campaign",
      "description": "Transitions a PAUSED campaign back to ACTIVE. Sending resumes from where it left off.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID to resume."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "ACTIVE"
            ]
          }
        },
        "required": [
          "id",
          "status"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{id}/resume"
      }
    },
    {
      "name": "duplicate_campaign",
      "title": "Duplicate Campaign",
      "description": "Creates a DRAFT copy of an existing campaign including all primary steps. Variants are not copied.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID to duplicate."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "New campaign ID."
          },
          "name": {
            "type": "string",
            "description": "Name with ' (copy)' suffix."
          },
          "status": {
            "type": "string",
            "enum": [
              "DRAFT"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "status",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{id}/duplicate"
      }
    },
    {
      "name": "list_contacts",
      "title": "List Contacts",
      "description": "Lists contacts with optional filtering by email substring or status. Supports cursor-based pagination. Pass the returned nextCursor to fetch the next page.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "description": "Case-insensitive email substring filter."
          },
          "status": {
            "type": "string",
            "description": "Filter contacts by status."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from the previous response."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 25,
            "description": "Number of contacts to return per page."
          }
        },
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "email": {
                  "type": "string",
                  "format": "email"
                },
                "firstName": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "lastName": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "company": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "title": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "status": {
                  "type": "string"
                },
                "customFields": {
                  "type": [
                    "object",
                    "null"
                  ],
                  "additionalProperties": true
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "email",
                "status",
                "createdAt",
                "updatedAt"
              ]
            }
          },
          "pagination": {
            "type": "object",
            "properties": {
              "nextCursor": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Pass this value as cursor to fetch the next page. Null when no more pages."
              },
              "hasMore": {
                "type": "boolean"
              }
            },
            "required": [
              "nextCursor",
              "hasMore"
            ]
          }
        },
        "required": [
          "data",
          "pagination"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/contacts"
      }
    },
    {
      "name": "get_contact",
      "title": "Get Contact",
      "description": "Returns a single contact by ID including all fields and custom fields.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Contact ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "firstName": {
            "type": [
              "string",
              "null"
            ]
          },
          "lastName": {
            "type": [
              "string",
              "null"
            ]
          },
          "company": {
            "type": [
              "string",
              "null"
            ]
          },
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string"
          },
          "customFields": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "email",
          "status",
          "createdAt",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/contacts/{id}"
      }
    },
    {
      "name": "create_contact",
      "title": "Create Contact",
      "description": "Creates a single contact. Returns 409 if a contact with the same email already exists.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "description": "Contact email address. Must be unique."
          },
          "firstName": {
            "type": "string",
            "description": "First name."
          },
          "lastName": {
            "type": "string",
            "description": "Last name."
          },
          "company": {
            "type": "string",
            "description": "Company name."
          },
          "title": {
            "type": "string",
            "description": "Job title."
          },
          "customFields": {
            "type": "object",
            "additionalProperties": true,
            "description": "Arbitrary key-value custom fields."
          }
        },
        "required": [
          "email"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "firstName": {
            "type": [
              "string",
              "null"
            ]
          },
          "lastName": {
            "type": [
              "string",
              "null"
            ]
          },
          "company": {
            "type": [
              "string",
              "null"
            ]
          },
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "email",
          "status",
          "createdAt",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/contacts"
      }
    },
    {
      "name": "update_contact",
      "title": "Update Contact",
      "description": "Updates mutable fields on a contact. Only provided fields are changed; omitted fields are left untouched.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Contact ID to update."
          },
          "firstName": {
            "type": [
              "string",
              "null"
            ],
            "description": "New first name, or null to clear."
          },
          "lastName": {
            "type": [
              "string",
              "null"
            ],
            "description": "New last name, or null to clear."
          },
          "company": {
            "type": [
              "string",
              "null"
            ],
            "description": "New company, or null to clear."
          },
          "title": {
            "type": [
              "string",
              "null"
            ],
            "description": "New job title, or null to clear."
          },
          "customFields": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true,
            "description": "Replace custom fields object."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "firstName": {
            "type": [
              "string",
              "null"
            ]
          },
          "lastName": {
            "type": [
              "string",
              "null"
            ]
          },
          "company": {
            "type": [
              "string",
              "null"
            ]
          },
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string"
          },
          "customFields": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "email",
          "status",
          "createdAt",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/contacts/{id}"
      }
    },
    {
      "name": "delete_contact",
      "title": "Delete Contact",
      "description": "Soft-deletes a contact. The contact is hidden from lists but retained internally for audit. Returns 204 with no body on success.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Contact ID to delete."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": true,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/contacts/{id}"
      }
    },
    {
      "name": "list_enrollments",
      "title": "List Campaign Enrollments",
      "description": "Lists all enrollments (contact progressions) for a specific campaign.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID to list enrollments for."
          }
        },
        "required": [
          "campaignId"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "campaignId": {
                  "type": "string"
                },
                "contactId": {
                  "type": "string"
                },
                "contactEmail": {
                  "type": "string",
                  "format": "email"
                },
                "status": {
                  "type": "string"
                },
                "currentStep": {
                  "type": "integer"
                },
                "scheduledAt": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "campaignId",
                "contactId",
                "status",
                "currentStep",
                "createdAt"
              ]
            }
          }
        },
        "required": [
          "data"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{campaignId}/enrollments"
      }
    },
    {
      "name": "enroll_contacts",
      "title": "Enroll Contact Lists",
      "description": "Enrolls all contacts from one or more contact lists into a campaign. Contacts already enrolled are skipped.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID to enroll contacts into."
          },
          "listIds": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "minItems": 1,
            "description": "Contact list IDs whose members will be enrolled."
          }
        },
        "required": [
          "campaignId",
          "listIds"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "additionalProperties": true,
        "description": "Enrollment summary with counts of enrolled and skipped contacts."
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{campaignId}/enrollments"
      }
    },
    {
      "name": "get_campaign_sync",
      "title": "Get Campaign Sync Overview",
      "description": "Returns the rolling-enrollment state of a campaign: the lists it draws from (each with its auto-sync toggle and live member count) and the review buffer — synced-list members awaiting validation that have not yet been auto-enrolled. Use to inspect which lists keep the sequence in sync and who is waiting.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "additionalProperties": true,
        "description": "Sync overview with `lists` (listId, name, autoSync, memberCount) and `pendingLeads` (contactId, email, firstName, lastName, status)."
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{id}/sync"
      }
    },
    {
      "name": "set_list_auto_sync",
      "title": "Toggle Rolling Enrollment for a List",
      "description": "Turns rolling enrollment (auto-sync) on or off for one of a campaign's lists. When on, new VALID members added to that list are enrolled into the campaign automatically by the sync cron; unverified members wait in the review buffer. When off, the list is a static snapshot.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          },
          "listId": {
            "type": "string",
            "description": "Contact list ID to toggle."
          },
          "autoSync": {
            "type": "boolean",
            "description": "true to enable rolling enrollment, false to disable."
          }
        },
        "required": ["id", "listId", "autoSync"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "autoSync": {
            "type": "boolean",
            "description": "The new auto-sync state for the list."
          }
        },
        "required": ["autoSync"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/campaigns/{id}/sync"
      }
    },
    {
      "name": "release_pending_lead",
      "title": "Release a Buffered Lead",
      "description": "Manually enrolls a contact sitting in a campaign's rolling-enrollment review buffer, regardless of validation status. Use to push an unverified-but-wanted lead into the sequence immediately instead of waiting for validation.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          },
          "contactId": {
            "type": "string",
            "description": "Contact ID to release from the buffer and enroll."
          }
        },
        "required": ["id", "contactId"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "enrolled": {
            "type": "boolean",
            "description": "True when a new enrollment was created."
          }
        },
        "required": ["enrolled"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{id}/sync/release"
      }
    },
    {
      "name": "get_enrollment",
      "title": "Get Enrollment",
      "description": "Returns one enrollment by ID, including the contact email, current step, and scheduling info.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Enrollment ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "campaignId": {
            "type": "string"
          },
          "contactId": {
            "type": "string"
          },
          "contactEmail": {
            "type": "string",
            "format": "email"
          },
          "status": {
            "type": "string"
          },
          "currentStep": {
            "type": "integer"
          },
          "scheduledAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "campaignId",
          "contactId",
          "contactEmail",
          "status",
          "currentStep",
          "createdAt",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/enrollments/{id}"
      }
    },
    {
      "name": "pause_enrollment",
      "title": "Pause Enrollment",
      "description": "Pauses an ACTIVE enrollment. The contact will not receive further emails until resumed.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Enrollment ID to pause."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "PAUSED"
            ]
          }
        },
        "required": [
          "id",
          "status"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/enrollments/{id}/pause"
      }
    },
    {
      "name": "resume_enrollment",
      "title": "Resume Enrollment",
      "description": "Resumes a PAUSED enrollment. The contact will continue receiving emails from the next scheduled step.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Enrollment ID to resume."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "ACTIVE"
            ]
          }
        },
        "required": [
          "id",
          "status"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/enrollments/{id}/resume"
      }
    },
    {
      "name": "list_mailboxes",
      "title": "List Mailboxes",
      "description": "Lists sender mailboxes connected to the account. Supports filtering by status, provider, label, warmup state, connection health (SMTP/IMAP), DNS issues, and free-text search across email + display name. Cursor-paginated — pass the returned nextCursor to fetch the next page.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from the previous response's nextCursor."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 25,
            "description": "Number of mailboxes to return per page."
          },
          "search": {
            "type": "string",
            "description": "Case-insensitive substring match on email address or display name."
          },
          "labelId": {
            "type": "string",
            "description": "Filter to a single label."
          },
          "provider": {
            "type": "string",
            "description": "Comma-separated provider list. Allowed values: GSUITE, MICROSOFT365, SMTP."
          },
          "status": {
            "type": "string",
            "description": "Comma-separated mailbox status list. Allowed values: ACTIVE, PAUSED, DISCONNECTED, SUSPENDED, DISGARDED."
          },
          "warmupEnabled": {
            "type": "boolean",
            "description": "Filter by warmup-enabled flag."
          },
          "isWarmupSeed": {
            "type": "boolean",
            "description": "Filter by warmup-seed flag."
          },
          "smtp": {
            "type": "string",
            "enum": ["ok", "failed"],
            "description": "SMTP connection health filter."
          },
          "imap": {
            "type": "string",
            "enum": ["ok", "failed"],
            "description": "IMAP connection health filter."
          },
          "dnsIssues": {
            "type": "string",
            "description": "Comma-separated DNS records flagged as missing or broken. Allowed values: mx, spf, dkim, a."
          }
        },
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string" },
                "emailAddress": { "type": "string", "format": "email" },
                "displayName": { "type": ["string", "null"] },
                "provider": {
                  "type": "string",
                  "enum": ["GSUITE", "MICROSOFT365", "SMTP"]
                },
                "status": {
                  "type": "string",
                  "enum": ["ACTIVE", "PAUSED", "DISCONNECTED", "SUSPENDED", "DISGARDED"]
                },
                "labelId": { "type": ["string", "null"] },
                "isWarmupSeed": { "type": "boolean" },
                "warmupEnabled": { "type": "boolean" },
                "warmupLastSendAt": { "type": ["string", "null"], "format": "date-time" },
                "smtpOk": { "type": ["boolean", "null"] },
                "imapOk": { "type": ["boolean", "null"] },
                "dnsMxOk": { "type": ["boolean", "null"] },
                "dnsSpfOk": { "type": ["boolean", "null"] },
                "dnsDkimOk": { "type": ["boolean", "null"] },
                "dnsRecordOk": { "type": ["boolean", "null"] },
                "connectionFailCount": { "type": "integer" },
                "createdAt": { "type": "string", "format": "date-time" },
                "updatedAt": { "type": "string", "format": "date-time" }
              },
              "required": ["id", "emailAddress", "provider", "status", "createdAt", "updatedAt"]
            }
          },
          "pagination": {
            "type": "object",
            "properties": {
              "nextCursor": { "type": ["string", "null"] },
              "hasMore": { "type": "boolean" }
            },
            "required": ["nextCursor", "hasMore"]
          }
        },
        "required": ["data"]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/mailboxes"
      }
    },
    {
      "name": "get_mailbox",
      "title": "Get Mailbox",
      "description": "Returns mailbox details including SMTP/IMAP connection health and DNS record status (MX, SPF, DKIM).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Mailbox ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "emailAddress": {
            "type": "string",
            "format": "email"
          },
          "displayName": {
            "type": [
              "string",
              "null"
            ]
          },
          "provider": {
            "type": "string",
            "enum": [
              "GOOGLE",
              "MICROSOFT",
              "SMTP"
            ]
          },
          "status": {
            "type": "string"
          },
          "smtpOk": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "SMTP connectivity status."
          },
          "imapOk": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "IMAP connectivity status."
          },
          "dnsMxOk": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "MX record validation."
          },
          "dnsSpfOk": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "SPF record validation."
          },
          "dnsDkimOk": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "DKIM record validation."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "emailAddress",
          "provider",
          "status",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/mailboxes/{id}"
      }
    },
    {
      "name": "create_mailbox",
      "title": "Create SMTP Mailbox",
      "description": "Connects a new SMTP/IMAP mailbox to the account. Validates SMTP and IMAP credentials before saving. OAuth mailboxes (Google, Microsoft) can only be connected via the frontend OAuth flow. Pass labelId to assign the mailbox to an existing label group.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "emailAddress": {
            "type": "string",
            "format": "email",
            "description": "Sender email address."
          },
          "displayName": {
            "type": "string",
            "description": "Optional display name shown in the From header."
          },
          "labelId": {
            "type": "string",
            "description": "Optional label/group ID to assign this mailbox to."
          },
          "smtpHost": {
            "type": "string",
            "description": "SMTP server hostname (e.g. smtp.gmail.com)."
          },
          "smtpPort": {
            "type": "integer",
            "minimum": 1,
            "maximum": 65535,
            "description": "SMTP port (465 for SSL, 587 for TLS)."
          },
          "smtpUsername": {
            "type": "string",
            "description": "SMTP authentication username (usually the email address)."
          },
          "smtpPassword": {
            "type": "string",
            "description": "SMTP authentication password or app password."
          },
          "imapHost": {
            "type": "string",
            "description": "IMAP server hostname (e.g. imap.gmail.com)."
          },
          "imapPort": {
            "type": "integer",
            "minimum": 1,
            "maximum": 65535,
            "description": "IMAP port (993 for SSL)."
          },
          "imapUsername": {
            "type": "string",
            "description": "IMAP authentication username (usually the email address)."
          },
          "imapPassword": {
            "type": "string",
            "description": "IMAP authentication password or app password."
          }
        },
        "required": [
          "emailAddress",
          "smtpHost",
          "smtpPort",
          "smtpUsername",
          "smtpPassword",
          "imapHost",
          "imapPort",
          "imapUsername",
          "imapPassword"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "emailAddress": {
            "type": "string",
            "format": "email"
          },
          "displayName": {
            "type": [
              "string",
              "null"
            ]
          },
          "provider": {
            "type": "string",
            "enum": [
              "SMTP"
            ]
          },
          "status": {
            "type": "string"
          },
          "smtpOk": {
            "type": [
              "boolean",
              "null"
            ]
          },
          "imapOk": {
            "type": [
              "boolean",
              "null"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "emailAddress",
          "provider",
          "status",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/mailboxes"
      }
    },
    {
      "name": "update_mailbox",
      "title": "Update Mailbox",
      "description": "Updates a mailbox. For SMTP mailboxes: pass all connection fields (hosts/ports/usernames are required; passwords are optional — omit to keep stored value). For OAuth mailboxes (Google, Microsoft): only displayName can be changed via API; use the frontend to reconnect OAuth credentials.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Mailbox ID."
          },
          "displayName": {
            "type": "string",
            "nullable": true,
            "description": "Display name for the From header. Pass null to clear."
          },
          "smtpHost": {
            "type": "string",
            "description": "SMTP hostname (SMTP mailboxes only, required when updating connection)."
          },
          "smtpPort": {
            "type": "integer",
            "minimum": 1,
            "maximum": 65535,
            "description": "SMTP port (SMTP mailboxes only)."
          },
          "smtpUsername": {
            "type": "string",
            "description": "SMTP username (SMTP mailboxes only)."
          },
          "smtpPassword": {
            "type": "string",
            "description": "SMTP password (SMTP mailboxes only). Omit to keep stored value."
          },
          "imapHost": {
            "type": "string",
            "description": "IMAP hostname (SMTP mailboxes only, required when updating connection)."
          },
          "imapPort": {
            "type": "integer",
            "minimum": 1,
            "maximum": 65535,
            "description": "IMAP port (SMTP mailboxes only)."
          },
          "imapUsername": {
            "type": "string",
            "description": "IMAP username (SMTP mailboxes only)."
          },
          "imapPassword": {
            "type": "string",
            "description": "IMAP password (SMTP mailboxes only). Omit to keep stored value."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "emailAddress": {
            "type": "string",
            "format": "email"
          },
          "displayName": {
            "type": [
              "string",
              "null"
            ]
          },
          "provider": {
            "type": "string",
            "enum": [
              "GOOGLE",
              "MICROSOFT",
              "SMTP"
            ]
          },
          "status": {
            "type": "string"
          },
          "smtpOk": {
            "type": [
              "boolean",
              "null"
            ]
          },
          "imapOk": {
            "type": [
              "boolean",
              "null"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "emailAddress",
          "provider",
          "status",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/mailboxes/{id}"
      }
    },
    {
      "name": "delete_mailbox",
      "title": "Delete Mailbox",
      "description": "Soft-deletes a mailbox. The mailbox is removed from active sending but retained internally for audit. Returns no body on success.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Mailbox ID to delete."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": true,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/mailboxes/{id}"
      }
    },
    {
      "name": "get_mailbox_warmup",
      "title": "Get Mailbox Warmup Analytics",
      "description": "Returns warmup performance analytics for a single mailbox: today's score, trailing-window score, day-over-day delta, daily counters (sent / delivered / spam / rescued / bounced / opened / replied / marked), and per-ESP placement stats. Use this to diagnose why a mailbox's warmup is degrading.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Mailbox ID."
          },
          "windowDays": {
            "type": "integer",
            "minimum": 1,
            "maximum": 90,
            "description": "Trailing window in days for daily counters and trailing score (default 30)."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "mailboxId": { "type": "string" },
          "windowDays": { "type": "integer" },
          "today": {
            "type": "object",
            "properties": {
              "score": { "type": "integer" },
              "placementRate": { "type": "number" },
              "replyRate": { "type": "number" },
              "openRate": { "type": "number" },
              "markRate": { "type": "number" },
              "bounceRate": { "type": "number" },
              "placed": { "type": "integer" }
            }
          },
          "trailing": {
            "type": "object",
            "properties": {
              "score": { "type": "integer" },
              "placementRate": { "type": "number" },
              "replyRate": { "type": "number" },
              "openRate": { "type": "number" },
              "markRate": { "type": "number" },
              "bounceRate": { "type": "number" },
              "placed": { "type": "integer" }
            }
          },
          "yesterday": {
            "type": "object",
            "properties": {
              "score": { "type": "integer" }
            }
          },
          "delta": { "type": "integer" },
          "daily": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "day": { "type": "string", "format": "date-time" },
                "sent": { "type": "integer" },
                "delivered": { "type": "integer" },
                "landedSpam": { "type": "integer" },
                "rescued": { "type": "integer" },
                "bounced": { "type": "integer" },
                "opened": { "type": "integer" },
                "replied": { "type": "integer" },
                "marked": { "type": "integer" }
              }
            }
          },
          "espStats": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "esp": { "type": "string", "enum": ["GMAIL", "OUTLOOK", "OTHER"] },
                "delivered": { "type": "integer" },
                "landedSpam": { "type": "integer" },
                "rescued": { "type": "integer" },
                "overridden": { "type": "integer" }
              }
            }
          }
        },
        "required": ["mailboxId", "windowDays", "today", "trailing", "delta", "daily", "espStats"]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/mailboxes/{id}/warmup"
      }
    },
    {
      "name": "get_mailbox_deliverability",
      "title": "Get Mailbox Canary Deliverability",
      "description": "Returns seed-canary deliverability signals for a single mailbox across all inbox providers (Outlook, Gmail / GSuite, Other). For each scanned day and seed ESP it reports DKIM pass/fail counts, landed folder (inbox vs spam), and — for Microsoft seeds only — SCL score and CompAuth result. Also includes the warmup-mesh inbox/spam breakdown per ESP. Use this to diagnose where a mailbox is landing across providers.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Mailbox ID."
          },
          "windowDays": {
            "type": "integer",
            "minimum": 1,
            "maximum": 90,
            "description": "Trailing window in days (default 30)."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "mailboxId": { "type": "string" },
          "windowDays": { "type": "integer" },
          "canary": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "day": { "type": "string", "format": "date-time" },
                "seedEsp": { "type": "string", "enum": ["OUTLOOK", "GMAIL", "OTHER"] },
                "sclScore": { "type": ["integer", "null"] },
                "dkimPassesCount": { "type": "integer" },
                "dkimFailsCount": { "type": "integer" },
                "landedFolder": { "type": ["string", "null"] },
                "compauthResult": { "type": ["string", "null"] }
              }
            }
          },
          "warmup": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "day": { "type": "string", "format": "date-time" },
                "esp": { "type": "string", "enum": ["GMAIL", "OUTLOOK", "OTHER"] },
                "delivered": { "type": "integer" },
                "landedSpam": { "type": "integer" },
                "rescued": { "type": "integer" },
                "overridden": { "type": "integer" }
              }
            }
          }
        },
        "required": ["mailboxId", "windowDays", "canary", "warmup"]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/mailboxes/{id}/deliverability"
      }
    },
    {
      "name": "list_labels",
      "title": "List Mailbox Labels",
      "description": "Lists all mailbox labels for the account along with each label's mailbox count. Labels group mailboxes (e.g. by client, by domain, by campaign theme) for filtering and warmup analytics.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string" },
                "name": { "type": "string" },
                "mailboxCount": { "type": "integer" },
                "createdAt": { "type": "string", "format": "date-time" },
                "updatedAt": { "type": "string", "format": "date-time" }
              },
              "required": ["id", "name", "mailboxCount", "createdAt", "updatedAt"]
            }
          }
        },
        "required": ["data"]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/labels"
      }
    },
    {
      "name": "create_label",
      "title": "Create Mailbox Label",
      "description": "Creates a new mailbox label. Label names must be unique per account (case-insensitive).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Label name. Must be unique within the account."
          }
        },
        "required": ["name"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": { "type": "string" },
          "name": { "type": "string" },
          "mailboxCount": { "type": "integer" },
          "createdAt": { "type": "string", "format": "date-time" },
          "updatedAt": { "type": "string", "format": "date-time" }
        },
        "required": ["id", "name", "createdAt", "updatedAt"]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/labels"
      }
    },
    {
      "name": "update_label",
      "title": "Rename Mailbox Label",
      "description": "Renames an existing mailbox label. Returns 409 if the new name collides with another label.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Label ID to rename."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "New label name."
          }
        },
        "required": ["id", "name"],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": { "type": "string" },
          "name": { "type": "string" },
          "mailboxCount": { "type": "integer" },
          "createdAt": { "type": "string", "format": "date-time" },
          "updatedAt": { "type": "string", "format": "date-time" }
        },
        "required": ["id", "name", "createdAt", "updatedAt"]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/labels/{id}"
      }
    },
    {
      "name": "delete_label",
      "title": "Delete Mailbox Label",
      "description": "Deletes a mailbox label. Mailboxes that were tagged with this label are unassigned (not deleted). Returns no body on success.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Label ID to delete."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": true,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/labels/{id}"
      }
    },
    {
      "name": "get_label_warmup",
      "title": "Get Label Warmup Analytics",
      "description": "Returns aggregated warmup analytics for every mailbox inside a label: headline KPIs (inbox placement %, median score, bounce rate, 24h volume), red-flag alerts (no-sends, score drop, bounce spike, connection failures, seed degradation), daily counter rollup, per-ESP breakdown, sender-provider mix, and per-mailbox worklist for triage. Use this for fleet-level analysis.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Label ID."
          },
          "maturity": {
            "type": "string",
            "enum": ["all", "mature", "new", "seeds"],
            "description": "Restrict the analytics population: `all` (default) includes every mailbox, `mature` only mailboxes warming for 14+ days, `new` mailboxes warming under 14 days, `seeds` only seed mailboxes."
          },
          "windowDays": {
            "type": "integer",
            "minimum": 1,
            "maximum": 90,
            "description": "Trailing window in days for daily counters and scoring (default 30)."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/labels/{id}/warmup"
      }
    },
    {
      "title": "List Events",
      "description": "Lists tracked email events (SENT, OPENED, CLICKED, REPLIED, BOUNCED, etc.) with optional filters. Supports cursor-based pagination.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Filter events by campaign ID."
          },
          "contactId": {
            "type": "string",
            "description": "Filter events by contact ID."
          },
          "type": {
            "type": "string",
            "enum": [
              "SENT",
              "DELIVERED",
              "OPENED",
              "CLICKED",
              "REPLIED",
              "BOUNCED",
              "COMPLAINED",
              "UNSUBSCRIBED"
            ],
            "description": "Filter events by type."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from the previous response."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 25,
            "description": "Number of events to return per page."
          }
        },
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "sendJobId": {
                  "type": "string"
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "SENT",
                    "DELIVERED",
                    "OPENED",
                    "CLICKED",
                    "REPLIED",
                    "BOUNCED",
                    "COMPLAINED",
                    "UNSUBSCRIBED"
                  ]
                },
                "metadata": {
                  "type": [
                    "object",
                    "null"
                  ],
                  "additionalProperties": true
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "sendJobId",
                "type",
                "createdAt"
              ]
            }
          },
          "pagination": {
            "type": "object",
            "properties": {
              "nextCursor": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Pass this value as cursor to fetch the next page. Null when no more pages."
              },
              "hasMore": {
                "type": "boolean"
              }
            },
            "required": [
              "nextCursor",
              "hasMore"
            ]
          }
        },
        "required": [
          "data",
          "pagination"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "name": "list_events",
      "_http": {
        "method": "GET",
        "path": "/api/v1/events"
      }
    },
    {
      "name": "list_webhooks",
      "title": "List Webhooks",
      "description": "Lists all webhook subscriptions configured in the account settings.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "targetUrl": {
                  "type": "string",
                  "format": "uri"
                },
                "eventType": {
                  "type": "string"
                },
                "active": {
                  "type": "boolean"
                },
                "failCount": {
                  "type": "integer"
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "targetUrl",
                "eventType",
                "active",
                "failCount",
                "createdAt"
              ]
            }
          }
        },
        "required": [
          "data"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/webhooks"
      }
    },
    {
      "name": "get_webhook",
      "title": "Get Webhook",
      "description": "Returns one webhook subscription by ID.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Webhook subscription ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "targetUrl": {
            "type": "string",
            "format": "uri"
          },
          "eventType": {
            "type": "string"
          },
          "active": {
            "type": "boolean"
          },
          "failCount": {
            "type": "integer"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "targetUrl",
          "eventType",
          "active",
          "failCount",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/webhooks/{id}"
      }
    },
    {
      "name": "test_webhook",
      "title": "Send Test Webhook",
      "description": "Sends a test event payload to a webhook subscription URL and returns the HTTP status code from the target server.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Webhook subscription ID to test."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "httpStatus": {
            "type": "integer",
            "description": "HTTP status code returned by the webhook target."
          }
        },
        "required": [
          "httpStatus"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": true
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/webhooks/{id}/test"
      }
    },
    {
      "name": "update_campaign",
      "title": "Update Campaign",
      "description": "Updates a campaign's name, status, or assigned mailboxes. Status transitions: DRAFT→ACTIVE (requires at least one step), ACTIVE↔PAUSED, any→ARCHIVED (terminal). Omit fields to leave them unchanged.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "New campaign name."
          },
          "status": {
            "type": "string",
            "enum": [
              "DRAFT",
              "ACTIVE",
              "PAUSED",
              "ARCHIVED"
            ],
            "description": "Target campaign status. DRAFT→ACTIVE requires at least one step. ARCHIVED is terminal."
          },
          "mailboxIds": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "maxItems": 200,
            "description": "Replace the full set of mailboxes assigned to this campaign."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "DRAFT",
              "ACTIVE",
              "PAUSED",
              "COMPLETED",
              "ARCHIVED"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "status",
          "createdAt",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/campaigns/{id}"
      }
    },
    {
      "name": "list_campaign_steps",
      "title": "List Campaign Steps",
      "description": "Returns all steps for a campaign in order (primary steps by position, then variants).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "campaignId"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "campaignId": {
                  "type": "string"
                },
                "order": {
                  "type": "integer"
                },
                "variantOf": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variantLabel": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "subject": {
                  "type": "string"
                },
                "bodyHtml": {
                  "type": "string"
                },
                "delayDays": {
                  "type": "integer"
                },
                "delayHours": {
                  "type": "integer"
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "campaignId",
                "order",
                "subject",
                "bodyHtml",
                "delayDays",
                "delayHours",
                "createdAt",
                "updatedAt"
              ]
            }
          }
        },
        "required": [
          "data"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{campaignId}/steps"
      }
    },
    {
      "name": "create_campaign_step",
      "title": "Create Campaign Step",
      "description": "Appends a new step to a campaign sequence. To add an A/Z variant, pass the parent step's ID in variantOf.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID to add the step to."
          },
          "variantOf": {
            "type": "string",
            "description": "Parent step ID — creates this step as an A/Z variant of the parent."
          },
          "subject": {
            "type": "string",
            "maxLength": 255,
            "default": "",
            "description": "Email subject line."
          },
          "bodyHtml": {
            "type": "string",
            "maxLength": 200000,
            "default": "",
            "description": "Email body as HTML."
          },
          "delayDays": {
            "type": "integer",
            "minimum": 0,
            "maximum": 365,
            "description": "Days to wait after the previous step before sending (default 0)."
          },
          "delayHours": {
            "type": "integer",
            "minimum": 0,
            "maximum": 23,
            "description": "Additional hours to wait (default 0)."
          },
          "variantLabel": {
            "type": "string",
            "maxLength": 40,
            "description": "Short display label for this variant (e.g. 'Version B')."
          }
        },
        "required": [
          "campaignId"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "campaignId": {
            "type": "string"
          },
          "order": {
            "type": "integer"
          },
          "subject": {
            "type": "string"
          },
          "bodyHtml": {
            "type": "string"
          },
          "delayDays": {
            "type": "integer"
          },
          "delayHours": {
            "type": "integer"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "campaignId",
          "order",
          "subject",
          "bodyHtml",
          "delayDays",
          "delayHours",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/campaigns/{campaignId}/steps"
      }
    },
    {
      "name": "update_campaign_step",
      "title": "Update Campaign Step",
      "description": "Updates subject, body, delay, or variant label on an existing campaign step. Omit fields to leave them unchanged.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID (for URL routing)."
          },
          "stepId": {
            "type": "string",
            "description": "Step ID to update."
          },
          "subject": {
            "type": "string",
            "maxLength": 255,
            "description": "Email subject line."
          },
          "bodyHtml": {
            "type": "string",
            "maxLength": 200000,
            "description": "Email body as HTML."
          },
          "delayDays": {
            "type": "integer",
            "minimum": 0,
            "maximum": 365,
            "description": "Days to wait before this step."
          },
          "delayHours": {
            "type": "integer",
            "minimum": 0,
            "maximum": 23,
            "description": "Additional hours to wait."
          },
          "variantLabel": {
            "type": "string",
            "maxLength": 40,
            "nullable": true,
            "description": "Variant label. Pass null to clear."
          }
        },
        "required": [
          "campaignId",
          "stepId"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "bodyHtml": {
            "type": "string"
          },
          "delayDays": {
            "type": "integer"
          },
          "delayHours": {
            "type": "integer"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "subject",
          "bodyHtml",
          "delayDays",
          "delayHours",
          "updatedAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/campaigns/{campaignId}/steps/{stepId}"
      }
    },
    {
      "name": "delete_campaign_step",
      "title": "Delete Campaign Step",
      "description": "Permanently deletes a campaign step and all its A/Z variants. Returns no body on success.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID."
          },
          "stepId": {
            "type": "string",
            "description": "Step ID to delete."
          }
        },
        "required": [
          "campaignId",
          "stepId"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": true,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/campaigns/{campaignId}/steps/{stepId}"
      }
    },
    {
      "name": "get_campaign_settings",
      "title": "Get Campaign Settings",
      "description": "Returns the options and schedule settings for a campaign (behaviour flags, daily limits, A/Z config, CC/BCC, schedule).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "description": "Full settings object. See CampaignSettings schema for all fields.",
        "additionalProperties": true
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{id}/settings"
      }
    },
    {
      "name": "update_campaign_settings",
      "title": "Update Campaign Settings",
      "description": "Updates campaign options (behaviour, sending pattern, A/Z testing, deliverability) and/or schedule. All fields optional — omit to leave unchanged.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          },
          "pauseOnReply": {
            "type": "boolean"
          },
          "pauseOnAutoReply": {
            "type": "boolean"
          },
          "stopCompanyOnReply": {
            "type": "boolean"
          },
          "trackOpens": {
            "type": "boolean"
          },
          "trackClicks": {
            "type": "boolean"
          },
          "deliveryOptimization": {
            "type": "boolean"
          },
          "includeUnsubscribe": {
            "type": "boolean"
          },
          "insertUnsubscribeHeader": {
            "type": "boolean"
          },
          "allowRiskyEmails": {
            "type": "boolean"
          },
          "providerMatching": {
            "type": "boolean"
          },
          "prioritizeNewLeads": {
            "type": "boolean"
          },
          "dailyLimit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 10000,
            "description": "Per-mailbox daily send cap. Total daily volume = this value times the attached mailbox count."
          },
          "minMinutesBetweenSends": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1440
          },
          "randomAdditionalMinutes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1440
          },
          "maxNewLeadsPerDay": {
            "type": "integer",
            "minimum": 1,
            "maximum": 10000,
            "nullable": true
          },
          "abAutoOptimize": {
            "type": "boolean"
          },
          "abWinningMetric": {
            "type": "string",
            "enum": [
              "OPENS",
              "CLICKS",
              "REPLIES"
            ],
            "nullable": true
          },
          "ccEmails": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "email"
            },
            "maxItems": 20
          },
          "bccEmails": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "email"
            },
            "maxItems": 20
          },
          "limitEmailsPerCompany": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1000,
            "nullable": true
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "maxItems": 50
          },
          "scheduleId": {
            "type": "string",
            "nullable": true
          },
          "startAt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "endAt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "description": "Updated settings object.",
        "additionalProperties": true
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/campaigns/{id}/settings"
      }
    },
    {
      "name": "get_campaign_intelligence",
      "title": "Get Campaign Intelligence",
      "description": "Returns the ICP (ideal customer profile) description and prospect website configured for AI copy generation.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "icpDescription": {
            "type": [
              "string",
              "null"
            ],
            "description": "ICP description used for AI copy generation."
          },
          "prospectWebsite": {
            "type": [
              "string",
              "null"
            ],
            "format": "uri",
            "description": "Prospect website URL used for AI copy generation."
          }
        },
        "required": [
          "icpDescription",
          "prospectWebsite"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{id}/intelligence"
      }
    },
    {
      "name": "update_campaign_intelligence",
      "title": "Update Campaign Intelligence",
      "description": "Updates the ICP description and/or prospect website used by the AI copy generator. Pass null to clear a field.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Campaign ID."
          },
          "icpDescription": {
            "type": "string",
            "maxLength": 10000,
            "nullable": true,
            "description": "ICP description. Pass null to clear."
          },
          "prospectWebsite": {
            "type": "string",
            "format": "uri",
            "maxLength": 2048,
            "nullable": true,
            "description": "Prospect website URL. Pass null to clear."
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "icpDescription": {
            "type": [
              "string",
              "null"
            ]
          },
          "prospectWebsite": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [
          "icpDescription",
          "prospectWebsite"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/campaigns/{id}/intelligence"
      }
    },
    {
      "name": "list_contact_lists",
      "title": "List Contact Lists",
      "description": "Returns all contact lists for the account, including the count of active contacts in each list.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "contactCount": {
                  "type": "integer",
                  "description": "Number of active (non-deleted) contacts."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "name",
                "contactCount",
                "createdAt",
                "updatedAt"
              ]
            }
          }
        },
        "required": [
          "data"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/lists"
      }
    },
    {
      "name": "create_contact_list",
      "title": "Create Contact List",
      "description": "Creates a new empty contact list.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "List name."
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "createdAt"
        ]
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/lists"
      }
    },
    {
      "name": "list_contacts_in_list",
      "title": "List Contacts in List",
      "description": "Returns contacts that are members of a given contact list, cursor-paginated. Supports search across email, name, and company.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "listId": {
            "type": "string",
            "description": "Contact list ID."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from the previous response."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 25,
            "description": "Number of contacts to return."
          },
          "search": {
            "type": "string",
            "description": "Case-insensitive substring search across email, first name, last name, company."
          }
        },
        "required": [
          "listId"
        ],
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "email": {
                  "type": "string",
                  "format": "email"
                },
                "firstName": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "lastName": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "company": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "title": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "status": {
                  "type": "string"
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "id",
                "email",
                "status",
                "createdAt"
              ]
            }
          },
          "pagination": {
            "type": "object",
            "properties": {
              "nextCursor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "hasMore": {
                "type": "boolean"
              }
            },
            "required": [
              "nextCursor",
              "hasMore"
            ]
          }
        },
        "required": [
          "data",
          "pagination"
        ]
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/lists/{listId}/contacts"
      }
    },
    {
      "name": "remove_contact_from_list",
      "title": "Remove Contact from List",
      "description": "Removes a contact's membership from a list (removes the 'label'). The contact record is preserved and can be re-added later. Returns no body on success.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "listId": {
            "type": "string",
            "description": "Contact list ID."
          },
          "contactId": {
            "type": "string",
            "description": "Contact ID to remove."
          }
        },
        "required": [
          "listId",
          "contactId"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/lists/{listId}/contacts/{contactId}"
      }
    },
    {
      "name": "get_campaign_variables",
      "title": "Get Campaign Template Variables",
      "description": "Returns every variable and snippet available for a campaign step: contact fields (standard + custom from enrolled contacts), mailbox signature, date/time tokens, spintax presets, and Liquid snippets. Use this to know what tokens you can insert when writing or editing a step subject or body.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "campaignId": {
            "type": "string",
            "description": "Campaign ID."
          }
        },
        "required": [
          "campaignId"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/campaigns/{campaignId}/variables"
      }
    },
    {
      "name": "list_inbox_messages",
      "title": "List Inbox Messages",
      "description": "Lists inbound email messages across all connected mailboxes. Supports folder filtering (inbox, replies, auto-replies, bounces, spam, starred, archived, all, warmup), free-text search, sender filter, mailbox/label filtering, read/unread state, starred flag, and date range. Cursor-paginated by receivedAt.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "folder": {
            "type": "string",
            "enum": ["inbox", "replies", "auto-replies", "bounces", "spam", "starred", "archived", "all", "warmup"],
            "default": "inbox",
            "description": "Folder to list. Virtual folders (starred, archived, all, warmup) filter across real folders."
          },
          "cursor": {
            "type": "string",
            "format": "date-time",
            "description": "ISO-8601 cursor from the previous page's nextCursor."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 50,
            "description": "Number of messages per page."
          },
          "q": {
            "type": "string",
            "description": "Free-text search across subject, snippet, body, and sender."
          },
          "from": {
            "type": "string",
            "description": "Filter by sender name or email (substring match)."
          },
          "mailboxIds": {
            "type": "string",
            "description": "Comma-separated mailbox IDs to restrict results."
          },
          "labelIds": {
            "type": "string",
            "description": "Comma-separated label IDs to filter by (OR semantics)."
          },
          "read": {
            "type": "string",
            "enum": ["read", "unread"],
            "description": "Filter by read status."
          },
          "starred": {
            "type": "string",
            "enum": ["true"],
            "description": "When 'true', only return starred messages."
          },
          "dateFrom": {
            "type": "string",
            "format": "date-time",
            "description": "Inclusive lower bound on receivedAt (ISO-8601)."
          },
          "dateTo": {
            "type": "string",
            "format": "date-time",
            "description": "Inclusive upper bound on receivedAt (ISO-8601)."
          }
        },
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/messages"
      }
    },
    {
      "name": "get_inbox_message",
      "title": "Get Inbox Message",
      "description": "Returns full details of a single inbound message including HTML/text body, headers, and a presigned download URL for the raw RFC822. Automatically marks the message as read on first access.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Inbound message ID."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/messages/{id}"
      }
    },
    {
      "name": "update_inbox_message",
      "title": "Update Inbox Message",
      "description": "Updates mutable fields on an inbound message: mark as read/unread, star/unstar, archive/unarchive, or assign/clear a label. Only provided fields are changed.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Inbound message ID."
          },
          "read": {
            "type": "boolean",
            "description": "Set true to mark as read, false to mark unread."
          },
          "starred": {
            "type": "boolean",
            "description": "Set true to star, false to unstar."
          },
          "archived": {
            "type": "boolean",
            "description": "Set true to archive, false to unarchive."
          },
          "labelId": {
            "type": ["string", "null"],
            "description": "Inbox label ID to assign, or null to clear the label."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/inbox/messages/{id}"
      }
    },
    {
      "name": "reply_to_message",
      "title": "Reply to Inbox Message",
      "description": "Sends a reply to an inbound message using the mailbox that originally received it. Automatically threads via In-Reply-To/References headers and includes quoted context.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Inbound message ID to reply to."
          },
          "body": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50000,
            "description": "Reply body in HTML."
          },
          "subject": {
            "type": "string",
            "maxLength": 998,
            "description": "Optional subject override. Defaults to 'Re: <original subject>'."
          }
        },
        "required": ["id", "body"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": true
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/inbox/messages/{id}/reply"
      }
    },
    {
      "name": "list_message_replies",
      "title": "List Message Replies",
      "description": "Lists all outbound replies sent for a specific inbound message, ordered chronologically. Useful for viewing the full reply thread.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Inbound message ID."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/messages/{id}/replies"
      }
    },
    {
      "name": "list_sent_messages",
      "title": "List Sent Messages",
      "description": "Lists outbound replies and composed emails sent by the user, collapsed by thread (toEmail + normalized subject). Cursor-paginated by sentAt.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "cursor": {
            "type": "string",
            "format": "date-time",
            "description": "ISO-8601 cursor from the previous page's nextCursor."
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 50,
            "description": "Number of threads per page."
          },
          "q": {
            "type": "string",
            "description": "Free-text search across subject, body, and recipient."
          }
        },
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/sent"
      }
    },
    {
      "name": "compose_email",
      "title": "Compose Email",
      "description": "Compose and send a new email from a connected mailbox. Not a reply — creates a fresh thread. The email is sent immediately via the mailbox's configured transport (SMTP / Google / Microsoft).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "mailboxId": {
            "type": "string",
            "description": "ID of the sender mailbox to use."
          },
          "to": {
            "type": "string",
            "format": "email",
            "description": "Recipient email address."
          },
          "subject": {
            "type": "string",
            "minLength": 1,
            "maxLength": 998,
            "description": "Email subject line."
          },
          "body": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50000,
            "description": "Email body in HTML."
          },
          "cc": {
            "type": "array",
            "items": { "type": "string", "format": "email" },
            "description": "CC recipients."
          },
          "bcc": {
            "type": "array",
            "items": { "type": "string", "format": "email" },
            "description": "BCC recipients."
          }
        },
        "required": ["mailboxId", "to", "subject", "body"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": true
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/inbox/compose"
      }
    },
    {
      "name": "get_inbox_counts",
      "title": "Get Inbox Counts",
      "description": "Returns total and unread message counts per folder (inbox, replies, auto-replies, bounces, spam, starred, archived, all, warmup, sent) plus per-label message counts. Powers the sidebar badges.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/counts"
      }
    },
    {
      "name": "trigger_inbox_scan",
      "title": "Trigger Inbox Scan",
      "description": "Triggers an immediate IMAP scan to check for new messages. Optionally scope to a single mailbox by passing mailboxId; omit to scan all eligible mailboxes.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "mailboxId": {
            "type": "string",
            "description": "Optional mailbox ID to scan. Omit to scan all mailboxes."
          }
        },
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/inbox/scan"
      }
    },
    {
      "name": "list_inbox_labels",
      "title": "List Inbox Labels",
      "description": "Lists the user's inbox message labels (Auto-reply, OOO, Opportunity, Positive reply, Negative reply, custom labels) with message counts and classification rule counts.",
      "inputSchema": {
        "type": "object",
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "GET",
        "path": "/api/v1/inbox/labels"
      }
    },
    {
      "name": "create_inbox_label",
      "title": "Create Inbox Label",
      "description": "Creates a new inbox message label. Names must be unique per account.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Label name."
          },
          "color": {
            "type": "string",
            "description": "Hex color code (e.g. '#6b7280'). Defaults to gray."
          }
        },
        "required": ["name"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      },
      "_http": {
        "method": "POST",
        "path": "/api/v1/inbox/labels"
      }
    },
    {
      "name": "update_inbox_label",
      "title": "Update Inbox Label",
      "description": "Renames or recolors an inbox message label.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Label ID."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "New label name."
          },
          "color": {
            "type": "string",
            "description": "New hex color code."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "PATCH",
        "path": "/api/v1/inbox/labels/{id}"
      }
    },
    {
      "name": "delete_inbox_label",
      "title": "Delete Inbox Label",
      "description": "Deletes an inbox message label. Messages tagged with this label will have their label cleared.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Label ID to delete."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": true,
        "idempotentHint": true,
        "openWorldHint": false
      },
      "_http": {
        "method": "DELETE",
        "path": "/api/v1/inbox/labels/{id}"
      }
    }
  ]
}
