Skip to main content
Ця сторінка також доступна українською.

Overview

When the AI assistant performs actions during a chat conversation, the backend signals the frontend via frontend_actions — an array of string values included in every chat message response.
The array can contain zero or more actions per message. Handle each one independently.

All actions

enable_submit_button and disable_submit_button are used exclusively in the onboarding flow. They are not related to campaign creation. Do not confuse them with campaign wizard actions.

Handling details

update_campaign_draft

This is the most common action. It fires whenever the assistant creates, updates, or deletes any part of a draft — ad groups, keywords, RSAs, extensions, bidding strategy, etc. Expected behavior: re-fetch the full draft via GET /api/v1/campaigns/drafts/{id} and update the wizard UI with the fresh data.

enable_submit_button / disable_submit_button

These actions are onboarding-specific. The assistant toggles the submit button during the onboarding conversation flow. They are not sent during campaign creation.

set_campaign_draft_step_N (new)

Pure navigation signals. The assistant sends these when it wants to direct the user’s attention to a specific wizard tab — e.g., after editing keywords it may navigate to Step 2 so the user can review. Expected behavior: switch the active tab to step N (1–4). No data refetch needed — these are often sent alongside update_campaign_draft, which already handles the data refresh.

Example: multiple actions in one message

The assistant can send several actions at once. For example, after editing keywords and wanting to show the Ad Groups tab:
Process both: re-fetch the draft and switch to step 2.