Wire Agent to Topics — Final Step (Create GenAiPlanner)
sf_create_agent_plannerCreate a planner that links an Agentforce agent to its topics, finalizing setup. This step is required for the agent to route any requests; without it, the agent cannot use its topics or actions.
Instructions
Creates a GenAiPlanner that connects an Agentforce Agent (Bot) to its Topics — STEP 4 (FINAL) of the agent setup sequence. Without this step the agent cannot route ANY request regardless of how many topics and actions were created. Also known as: linking topics to agent, connecting topics, finishing agent setup, wiring topics, registering topics. CRITICAL: topicNames must be the COMPLETE list of all topics — this REPLACES any existing planner, so omitting a topic removes it from the agent. When adding a new topic to an existing agent, include ALL previous topic names plus the new one. Only AFTER this step succeeds should you report completion to the user.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | No | Planner display label (defaults to agentName) | |
| agentName | Yes | Agent API name — must exactly match the agentName used in sf_create_agent (no underscores). | |
| topicNames | Yes | COMPLETE list of topic API names to wire to this agent. WARNING: This REPLACES any existing planner — if you add a new topic to an existing agent, include ALL previous topic names plus the new one. Omitting a topic here removes it from the agent. | |
| actionNames | No | Action API names to attach directly to the planner rather than through a topic (e.g. a knowledge action). Most agents leave this empty and put actions in topics. | |
| description | No | Planner description. Required by Salesforce — defaults to a generated description if omitted. |