create_contact
Create a contact manually — for imports or externally-sourced audiences; contacts who message a bot are created automatically. Requires the manage_broadcasts permission. platformId must be unique within the bot (duplicate fails with 409); botId may be omitted only when the application has exactly one bot. The variables map takes variable NAMES (or full folder paths when a name is ambiguous) — not ids — and unknown names fail with 422. NOT idempotent: retrying a success creates nothing new only because the duplicate platformId is rejected.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| botId | No | Bot the contact belongs to. Optional only when the application has exactly one bot; otherwise the call fails listing the candidate bots. | |
| No | Email address. | ||
| phone | No | Phone number. | |
| status | No | Initial subscription status. Defaults to "subscribed". | |
| lastName | No | Last name. | |
| username | No | Platform username, without @. | |
| firstName | No | First name. | |
| variables | No | Contact variable values to set, as { "variableName": "value" }. Keys are variable NAMES or full folder paths (not ids); an unknown or ambiguous name fails the whole call before the contact is created. | |
| platformId | Yes | Required. Platform-side user id (e.g. the Telegram user id). Must be unique within the bot. | |
| applicationId | No | Application (workspace) id. Optional: an application-scoped key (app_...) defaults to its own application, but a personal key (usr_...) has no default and omitting it fails with MCP_APPLICATION_REQUIRED. Call list_applications to get the id. |