Activate Agent for Widget
ethora-agent-activateMake an agent the app's ACTIVE widget bot: sets App.defaultBotInstanceId (and botStatus: on), which is what POST /v2/widget/sessions uses to decide who answers website visitors. Required before an embedded widget can answer on an API-created app. Preconditions: the agent was invited into a room of this app with ethora-agent-invite (that creates its bot instance). Works in user auth (app update route); falls back to the app-token /v2/agents/:id/activate route when an appToken is stored.
Requires: an agent already invited into a room of the selected app (ethora-agent-create -> ethora-chat-create -> ethora-agent-invite); the invite creates the bot instance this tool binds as the app's default responder.
Auth: user session (owner of the app). Errors: 404 no bot instance for this agent in the app (invite first); 403 not the app owner. Related: ethora-widget-snippet-get next, ethora-bot-instance-list to inspect.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| appId | No | App to activate the agent for. Defaults to the app from `ethora-app-select`. | |
| agentId | No | Id (or address) of the agent to activate. Get it from `ethora-agent-list` / `ethora-agent-create`. | |
| chatJid | No | Room JID `${appId}_${chatId}` (with or without `@conference...`) that becomes the widget chat. Required for API-created apps; omit only for dashboard-created apps that already have an AI Widget chat bound. | |
| agentIdOrAddress | No | Alias for `agentId` - either name is accepted, pass whichever you have. |