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

# Create an IVR flow

> Creates the flow with draft_revision 1, no published revision, and a single `entry` node. The flow takes no calls until it is published.



## OpenAPI

````yaml /api-reference/openapi-public.json post /ivr-flows
openapi: 3.0.3
info:
  description: >-
    The API your own systems use: place and follow calls, have an AI agent call
    someone, run campaigns and get their results, keep contacts in step with
    your CRM, and receive signed webhooks. Authenticate with an integration key
    (Authorization: Bearer ft_...), used only from the IP addresses it allows.
  title: FireTone API
  version: 0.1.0
servers:
  - description: Your platform's API host
    url: https://{host}/api/v1
    variables:
      host:
        default: api.firet.one
security:
  - bearerAuth: []
tags:
  - name: Auth
  - description: >-
      Live calls and what can be done to them: hang up, hold, transfer, park,
      merge, monitor, whisper; the Desk's own call.
    name: Calls
  - description: 'Outbound campaigns: contacts, attempts, outcomes.'
    name: Campaigns
  - description: 'Customers: who called, what is known about them, and their memory.'
    name: Contacts
  - description: What was said on an AI call, and the review of it.
    name: Conversations
  - name: IVR
  - description: >-
      Your own systems: HTTP connections an IVR calls mid-call, and webhooks for
      call events. Tenant URLs must be public https addresses.
    name: Integrations
  - name: Live
  - name: Provisioning
  - name: Reporting
  - description: Tickets raised by people, agents and the API.
    name: Tickets
  - description: Messages left for an extension or a queue.
    name: Voicemail
paths:
  /ivr-flows:
    post:
      tags:
        - IVR
      summary: Create an IVR flow
      description: >-
        Creates the flow with draft_revision 1, no published revision, and a
        single `entry` node. The flow takes no calls until it is published.
      operationId: postIvrFlows
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateIVRFlowRequest'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IVRFlow'
          description: Created
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '409':
          $ref: '#/components/responses/Conflict'
components:
  schemas:
    CreateIVRFlowRequest:
      description: >-
        A new flow is created with draft_revision 1, no published revision, and
        a single `entry` node, so it opens as a valid canvas rather than a blank
        one the designer cannot start from.
      properties:
        campaign_kind:
          description: >-
            Only valid with direction=outbound; sending it on an inbound flow is
            refused rather than ignored. Omit it to make the flow usable by both
            campaign kinds.
          enum:
            - voice_broadcast
            - auto_dial
          type: string
        description:
          description: A note for the people who maintain it.
          type: string
        direction:
          default: inbound
          description: >-
            Defaults to inbound. An outbound flow's entry node is labelled for
            the moment a campaign's contact answers rather than for an incoming
            call.
          enum:
            - inbound
            - outbound
          type: string
        name:
          description: What the IVR is called, in lists and in the designer.
          type: string
        organisation_id:
          description: >-
            The organisation the number belongs to. May be left out by a caller
            with exactly one organisation.
          format: uuid
          type: string
        team_id:
          description: The team that owns the IVR, if any.
          format: uuid
          type: string
      required:
        - name
      type: object
    IVRFlow:
      description: >-
        A call flow as a graph. `published_revision` is the revision answering
        calls; a flow with none takes no traffic. `draft_revision` is what the
        designer edits.
      properties:
        campaign_kind:
          description: >-
            Which campaign kind an outbound flow was drawn for. Null means it
            suits both, and is the only valid value on an inbound flow.
          enum:
            - voice_broadcast
            - auto_dial
          nullable: true
          type: string
        created_at:
          format: date-time
          type: string
        description:
          nullable: true
          type: string
        direction:
          description: >-
            Which way the call is going when this graph runs. An inbound flow
            answers a number; an outbound one runs after a campaign's contact
            picks up. A campaign will not accept an inbound flow.
          enum:
            - inbound
            - outbound
          type: string
        draft_revision:
          type: integer
        id:
          format: uuid
          type: string
        name:
          type: string
        organisation_id:
          format: uuid
          type: string
        published_revision:
          description: >-
            The revision currently answering calls. Null means the flow has
            never been published and must not receive traffic.
          nullable: true
          type: integer
        team_id:
          format: uuid
          nullable: true
          type: string
        test_caller:
          description: >-
            Who a test call tells the flow is calling, E.164 (read in the
            organisation's region when typed without +). Null for the tester's
            own extension.
          type: string
        test_number:
          description: >-
            3-8 digits any extension of the organisation dials to walk through
            this flow as a test. Never reachable from outside. Refused if it is
            an extension, a park slot (701-799) or another flow's test number.
            Null to remove.
          type: string
        test_revision:
          description: Which version a test call runs. Default draft.
          enum:
            - draft
            - published
          type: string
        updated_at:
          format: date-time
          type: string
      required:
        - id
        - organisation_id
        - name
        - direction
        - draft_revision
        - created_at
        - updated_at
      type: object
    Error:
      properties:
        error:
          properties:
            code:
              enum:
                - invalid_request
                - invalid_credentials
                - unauthenticated
                - forbidden
                - not_found
                - conflict
                - internal
              type: string
            message:
              type: string
          required:
            - code
            - message
          type: object
      required:
        - error
      type: object
  responses:
    BadRequest:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
      description: The request is not valid. The message names every field that is wrong.
    Unauthorized:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
      description: Missing, invalid or expired token
    Forbidden:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
      description: Outside the caller's scope, or insufficient role
    Conflict:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
      description: >-
        The row is still referenced, or a unique value is taken. The message
        names what still points at it.
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT or API key
      description: >-
        Every request sends `Authorization: Bearer <token>`. The token is either
        a panel session (a JWT from /auth/login, 12 hours) or an API key
        `ft_<id>_<secret>`. An API key is accepted only from an address on its
        IP allowlist (403 ip_not_allowed otherwise; 403 ip_allowlist_required
        for an old key that has none), is limited to its rate per minute (429
        rate_limited with Retry-After; X-RateLimit-Limit/Remaining/Reset on
        every response), and at most 60 call placements a minute.
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.