> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ryzeapi.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# Start flow

> Manually starts a Typebot flow for a number, triggering the startChat

**Auth:** `TokenAccount` or `TokenInstance` • **Rate limit:** `Global` (100/min) • **Idempotent:** no

## Description

Manually starts a Typebot flow for a number, without waiting for a trigger message. RyzeAPI fires the `startChat` of the indicated bot and persists the session. Useful for outbound campaigns and to resume a conversation from your backend.

<Info>
  The instance must already have at least one registered bot (an active integration).
</Info>

## Example

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST "https://ryzeapi.cloud/api/typebot/start/suporte" \
    -H "token: $Token_Account" \
    -H "Content-Type: application/json" \
    -d '{
      "number":  "5511999999999",
      "botId":   "8f3a1c2e-...-b7d9",
      "variables": { "nome": "João", "plano": "premium" }
    }'
  ```

  ```javascript JavaScript theme={null}
  await fetch("https://ryzeapi.cloud/api/typebot/start/suporte", {
    method: "POST",
    headers: {
      "token":        process.env.Token_Account,
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      number:  "5511999999999",
      botId:   "8f3a1c2e-...-b7d9",
      variables: { nome: "João", plano: "premium" }
    })
  });
  ```

  ```python Python theme={null}
  import os, requests

  requests.post(
      "https://ryzeapi.cloud/api/typebot/start/suporte",
      headers={
          "token":        os.environ["Token_Account"],
          "Content-Type": "application/json"
      },
      json={
          "number":  "5511999999999",
          "botId":   "8f3a1c2e-...-b7d9",
          "variables": { "nome": "João", "plano": "premium" }
      }
  )
  ```

  ```go Go theme={null}
  package main

  import (
      "net/http"
      "os"
      "strings"
  )

  func main() {
      body := strings.NewReader(`{
          "number":  "5511999999999",
          "botId":   "8f3a1c2e-...-b7d9",
          "variables": { "nome": "João", "plano": "premium" }
      }`)
      req, _ := http.NewRequest("POST", "https://ryzeapi.cloud/api/typebot/start/suporte", body)
      req.Header.Set("token", os.Getenv("Token_Account"))
      req.Header.Set("Content-Type", "application/json")
      http.DefaultClient.Do(req)
  }
  ```
</CodeGroup>

## Success response

```json 200 OK theme={null}
{
  "success": true,
  "message": "typebot flow started"
}
```

| Field     | Description                                          |
| --------- | ---------------------------------------------------- |
| `success` | Always `true` on success.                            |
| `message` | Fixed confirmation message (`typebot flow started`). |

## Path parameters

<ParamField path="instance" type="string" required>
  Instance name (e.g., `suporte`).
</ParamField>

## Headers

<ParamField header="token" type="string" required>
  `TokenAccount` or `TokenInstance`.
</ParamField>

<ParamField header="Content-Type" type="string" required>
  `application/json`
</ParamField>

## Request body

<ParamField body="number" type="string" required>
  Destination number in E.164 format without the `+` (e.g., `5511999999999`).
</ParamField>

<ParamField body="botId" type="string" required>
  UUID of the bot to start, obtained from [`GET /api/typebot/list/:instance`](/en/api/typebot/list).
</ParamField>

<ParamField body="variables" type="object">
  Prefilled variables passed to Typebot (`string → string` map). Ex.: `{ "nome": "João", "plano": "premium" }`.
</ParamField>

## Errors

| HTTP | `error.message`                                                | Cause                                                 |
| :--: | -------------------------------------------------------------- | ----------------------------------------------------- |
|  400 | `invalid body: ...`                                            | Malformed body or missing `number` / `botId`.         |
|  404 | `instance not found`                                           | Instance does not exist in RyzeAPI.                   |
|  404 | `no typebot integration for this instance, create a bot first` | The instance does not have any bot/integration yet.   |
|  404 | `bot not found for this instance`                              | The `botId` provided does not exist in this instance. |
|  500 | `start flow: ...`                                              | Failure while starting the flow.                      |
|  503 | `integration gateway not configured`                           | Integration service unavailable on the server.        |

## Next

<CardGroup cols={2}>
  <Card title="List bots" icon="list" href="/en/api/typebot/list">
    Find the `botId` to use with `GET /api/typebot/list/:instance`.
  </Card>

  <Card title="Register bot" icon="robot" href="/en/api/typebot/set">
    Configure a bot before starting flows manually.
  </Card>
</CardGroup>
