API

Interact with your agent programmatically over HTTP

The API deployment lets you connect your agent to any application. Instead of embedding a widget or relying on a messaging channel, you communicate with your agent directly through HTTP requests — send a message, get a response.

The endpoint is https://bot-v5.helvia.ai/api/events. Explore the full API specification:

Why Use the API

webhook

Custom Integrations

Embed your agent into mobile apps, internal tools, CRMs, or any software that speaks HTTP

rectangle-terminal

Backend Automation

Trigger agent workflows from server-side processes without a user interface

gears

Full Control

Manage sessions, pass user metadata, override language, and tag conversations programmatically

subtitles

No UI Dependency

Unlike Webchat or messaging channels, the API gives you raw input/output with no rendering layer

Creating an API Deployment

1

Select the API Channel

Go to Designer > Deployments and click the API icon code in the channel toolbar.

2

Configure General Settings

Give your deployment a Name and optional Description so your team can identify it later. Set the Language the agent will respond in, and toggle Enable User Language Detection to automatically match the user's language.

3

Create the Deployment

Click Create Deployment. The platform generates your Identifier (Agent Handle) and API Token automatically.

Prerequisites

You need two credentials from your API deployment in Designer > Deployments:

  • Deployment Identifier — The deployment's unique identifier (labeled Identifier in the console)

  • API Token — A Bearer JWT for the Authorization header

circle-exclamation

How To Use the API

circle-check

Start a session by sending a greeting postback:

Then send a text message in the same session:

A successful response:

Each item in the responses array is one message from the agent. The type field indicates the response format (text, buttons, carousel, etc.) and altText contains the plain-text version.

Key Concepts

For the full request/response API schemas and detailed error codes, see the Bot API Reference.

chevron-rightHandlehashtag

The handle field is the deployment Identifier from your API deployment settings. It tells the platform which agent and configuration to use for the request.

chevron-rightSender IDhashtag

The sender.id identifies the end user in the conversation. Use a consistent ID (e.g. a UUID) per user to maintain conversation context across messages. If you omit the sender object entirely, the system generates a default ID with the prefix api_subscriber_.

chevron-rightSessionshashtag

Sessions group message exchanges into conversations. A new session is created when:

  • A new sender.id sends its first message

  • You send a greeting postback to explicitly start a new conversation

  • A message arrives from an existing user but the inactivity timeout has elapsed since their last message. The timeout is configurable in Designer Settings > Configuration >.

Within a session, the agent maintains conversational context — collected variables, workflow state, and conversation history carry over between messages.

chevron-rightText vs Payloadhashtag

The message object can contain either a text or payload property, but not both. The text contains the users message and the payload is a postback message that triggers a specific flow node, intent, or action.

chevron-rightAdvanced: Language Overridehashtag

Pass a language field to override the deployment's default language for a specific request. The value is a language code like EN, EL, or DE.

chevron-rightAdvanced: Tag Operationshashtag

Add or remove tags on the current session using the tagOperations field:

chevron-rightAdvanced: Response Optionshashtag

Include additional data in the response using the options field:

Option
Effect

includeMetadata: true

Adds responsesIds and nodesIds arrays to the response

includeStrippedMarkdownTextResponses: true

Adds a responsesStrippedMarkdownText array with plain-text versions (useful for text-to-speech)

Complete Example with All Options

Last updated

Was this helpful?