About the Containers Chat API

The Containers Chat API manages conversations and messages for the Wix AI coding agent. Use this API to integrate the coding agent's chat experience into your app, allowing users to send requests, track the agent's progress, and read the full response.

With the Containers Chat API, you can:

  • Create and manage conversations for a project.
  • Send user messages to trigger the coding agent.
  • Read a conversation's full message history, including in-progress assistant responses.

The turn lifecycle

When you call Send Message, two things happen immediately:

  1. The user message is persisted with DONE status.
  2. An assistant turn is opened with WORKING status. This turn represents the agent's in-progress response.

As the agent works, the assistant turn's tasks field is updated with a live checklist of work items. When the agent finishes, the turn transitions to DONE with the final response in its parts field. If the agent fails, the turn transitions to ERROR.

Tracking the assistant's response

The API doesn't support real-time streaming. After calling Send Message, poll Query Messages to check the assistant turn's status. When the status changes from WORKING to DONE, the final response is available in the parts field.

Before you begin

It's important to note the following points before starting to code:

  • This API is in Beta.
  • Conversations are scoped to a project. You need a projectId to create a conversation.
  • Send Message requires an idempotencyKey. Use a unique key per user message and reuse the same key if retrying a failed request.

Use cases

Terminology

  • Conversation: A chat thread for a project. A project can have multiple conversations. Conversations hold thread metadata; messages are returned separately via Query Messages.
  • Message: A single turn in a conversation. Messages have a role of USER or ASSISTANT and a status of WORKING, DONE, or ERROR.
  • Task: A work item shown as a live checklist on an assistant turn while the agent is processing. Returned in the tasks field of the assistant message.

Last updated: 3 August 2026

Did this help?