create_agent
Creates a node-based Convocore agent with a main system prompt, default Claude Haiku model, auto RAG knowledge base, optional UI Engine flags, and lead-scoring funnel configuration.
Instructions
Create a Convocore agent (advanced/raw). Prefer create_agent_from_template for website/branded agents. Always node-based: enableNodes is forced true; put the main prompt in systemPrompt (or nodes[0].instructions) — do NOT use vg_instructions (API rejects that field). Default chat model is always claude-haiku-4-5-20251001 (Claude Haiku 4.5) on vg_defaultModel + nodes[0].llmConfig.modelId. UI Engine flags optional via vg_enableUIEngine*. Lead notify: use funnelConfig (AI Funnel + lead scoring + email recipients) — do NOT create custom HTTP webhook tools for sales alerts. Sets nodes[0].kb.enabled for auto RAG with maxChunks=3 and vgOptions.maxChunkSize=512 — still bake critical facts into systemPrompt. Do not raise chunk size or chunk count unless the user asks.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| light | No | Enable light mode (no chat history retention for privacy) | |
| nodes | No | Optional nodes. If omitted with systemPrompt, MCP creates the start node. Main prompt MUST be nodes[0].instructions. | |
| theme | No | Visual theme (e.g., blue-light, custom-blue-dark) | |
| title | Yes | The title of the agent | |
| disabled | No | Whether the agent should be disabled | |
| description | No | A brief description of the agent | |
| voiceConfig | No | Agent voiceConfig for voice-capable agents. Integrations/API keys generally live at workspace/org level; this config selects providers, models, voices, and call behavior for the agent. | |
| enableVertex | No | Enable Vertex AI for the agent | |
| funnelConfig | No | AI Funnel & Lead Scoring (built-in). Use this instead of a custom HTTP “notify sales team” webhook. enabled + steps (id/name/description/condition/points/category) + notificationRules (type score_threshold|steps_completed|data_collected, recipients emails, cooldownStrategy). Runtime scores the conversation and emails recipients when a rule fires. | |
| systemPrompt | No | Main behavior prompt → written to nodes[0].instructions (enableNodes always true). | |
| autoOpenWidget | No | Auto-open widget when agent loads | |
| additionalConfig | No | Extra agent fields: same as update_agent additionalConfig (see that tool for each field's type and meaning). Fields: roundedImageURL, branding, customThemeJSONString, chatBgURL, lang, fontFamily, rectangeImageURL, avatarImageUrl, headerImageUrl, bannerImageUrl, enableNodes, nodesSettings, vg_systemPrompt, vg_initPrompt, vg_initMessages, vg_prompt, vg_temperature, vg_defaultModel, vg_maxTokens, vg_max_messages_history, vg_enableAboutContext, ifKnowsThreshold, enableFallback, fallbackSettings, enableAudioSupport, captureIGStories, metaHumanTakeover, vg_kb_llm, vg_kbDefaultDimension, vg_kbTopChunks, vg_kbCharCount, vg_kbDocsNum, proactiveMessage, autoStartWidget, messageDelayMS, scrollAnimation, disableSmoothScroll, buttonsLayout, buttonVariant, inputVariant, ui, ADVANCED_customCSS, disableRating, chatEndMessage, aiIntroductionMessage, enableAIIntroductionMessage, privacyDisclaimer, gdprCompliance, disableModelAutoUpgrade, acceptFileUpload, disableFileUpload, enableQuickFileUpload, soundEffectUrl, soundEffectEnabled, agentPlatform, AITranslateTo, enableAITranslate, disableHumanHandoff, alwaysShowHandoff, manualControl, enableVGHandoff, fixedHandoffPopup, UIhandoffTitle, UIhandoffSubtitle, showHandoffEvenIfOffline, persistHandoffOnRefresh, blockInputDuringHandoffRequest, disableHandoffMessages, handoffNowChattingMessage, handoffBackToAiMessage, handoffCancelButtonLabel, disableHandoffStatusMessages, convoTags, topicsConfig, starred, enableGeoAnalytics, hideVoiceflowAnalytics, hideCallAnalytics, hideConversationMetrics, hideCustomAnalytics, hideVapiAnalytics, hideFunnelAnalytics, marketplace, autoTest, customButtonJSON_STRING. Do not put the main prompt here. Unknown fields are rejected up front with the valid names. | |
| allowRemoveTools | No | Default false: toolsIds in a nodes patch are unioned with the live list. Set true only to intentionally remove tools. | |
| vg_enableUIEngine | No | MASTER SWITCH for UI Engine. When true the agent can emit structured UI (text, choice/buttons, visual, cardV2, carousel, iFrame, and — if their flags are on — form/input, invoice, calendarBooking). Call get_ui_engine_spec for payloads. Prefer enabling this before toggling individual elements. | |
| leadCollectionRules | No | When to persist a CRM lead. Default: collect when email, phone, or phone_number is present. | |
| vg_maxImagesPerCard | No | Max images per cardV2/carousel card: 1 = imageUrl only; 2–3 allow images[] gallery. Omit for platform default. | |
| vg_enableUIEngineForms | No | Allow form + input UI Engine elements (typically web). Set true to let the agent collect structured fields. Also set vg_uiEngineChannelConfig.web.form / .input as needed. | |
| vg_enableUIEngineInvoice | No | Allow invoice card UI Engine elements (web). Use with vg_uiEngineInvoiceConfig for click notifications. | |
| vg_uiEngineChannelConfig | No | Per-channel allowlist of which UI Engine elements the agent may show. Channels: web, whatsapp, instagram, messenger, telegram. Each channel is an object of type→boolean (choice, visual, cardV2, carousel, iFrame, form, input, invoice, calendarBooking, file, VoiceNote, locationRequest, ctaUrl). Missing type = enabled. Example: { "web": { "choice": true, "cardV2": true, "form": true, "invoice": false }, "whatsapp": { "choice": true, "cardV2": true, "form": false } }. Forms/invoice/calendar still need their global vg_enableUIEngine* flags. | |
| vg_uiEngineInvoiceConfig | No | Invoice card notification settings. | |
| vg_uiEngineCalendarConfig | No | Calendar booking widget config (Google Calendar connection + booking rules). | |
| vg_uiEngineFormNotifyConfig | No | Email notify settings when forms/inputs are submitted. | |
| vg_enableUIEngineCalendarBooking | No | Allow interactive calendar booking widget (web). Requires Google Calendar connectionIds in vg_uiEngineCalendarConfig. |