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

# Create a call with inline configuration

> Run a call without a saved agent — the whole configuration travels in
the request. Nothing is stored and nothing is reused.

Use it for per-user personas, generated agents, or testing a prompt
without leaving a record behind. If the same configuration is used
repeatedly, create a real agent instead: you gain version history, tool
assignment, a phone number, corpora, and the dashboard.




## OpenAPI

````yaml /openapi.yaml post /calls/inline
openapi: 3.0.0
info:
  title: Omnia Voice API
  description: >
    The Omnia Voice API allows you to programmatically manage voice agents,
    tools, phone numbers, and call logs.


    ## Authentication

    All API requests require an API key to be passed in the `X-API-Key` header.


    ## Rate Limiting

    API requests are rate limited to 1000 requests per hour per API key.
  version: 1.0.0
  contact:
    email: support@omnia-voice.com
servers:
  - url: https://api.omnia-voice.com/api/v1
    description: Production
  - url: https://dashboard.omnia-voice.com/api/v1
    description: Production (alias — same service)
security:
  - ApiKeyAuth: []
tags:
  - name: Agents
    description: Manage voice agents
  - name: Tools
    description: Manage agent tools and actions
  - name: Phone Numbers
    description: Manage phone number assignments
  - name: Calls
    description: Create and manage voice calls
  - name: Call Logs
    description: View call history and details
  - name: Pricing
    description: Get pricing information and calculate call costs
  - name: Configuration
    description: Get configuration options (voices, languages)
paths:
  /calls/inline:
    post:
      tags:
        - Calls
      summary: Create a call with inline configuration
      description: |
        Run a call without a saved agent — the whole configuration travels in
        the request. Nothing is stored and nothing is reused.

        Use it for per-user personas, generated agents, or testing a prompt
        without leaving a record behind. If the same configuration is used
        repeatedly, create a real agent instead: you gain version history, tool
        assignment, a phone number, corpora, and the dashboard.
      operationId: createInlineCall
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - systemPrompt
                - voice
                - language
              properties:
                systemPrompt:
                  type: string
                  description: |
                    The **entire** prompt. There is no basePrompt/context/
                    customInstructions layering here — that belongs to saved
                    agents.
                voice:
                  type: string
                  description: Voice name or ID. See `GET /voices`.
                  example: Mark
                language:
                  type: string
                  description: Language code. See `GET /languages`.
                  example: en
                model:
                  type: string
                  enum:
                    - gemma
                    - llama
                    - glm
                  default: llama
                temperature:
                  type: number
                  minimum: 0
                  maximum: 1
                  default: 0
                greeting:
                  type: string
                  description: |
                    Appended to the prompt as the opening line when the agent
                    speaks first. Ignored when `firstSpeaker` is `user`.
                firstSpeaker:
                  type: string
                  enum:
                    - agent
                    - user
                  default: agent
                interruptible:
                  type: boolean
                  default: false
                  description: Applies to the agent's first message only.
                maxDuration:
                  type: integer
                  minimum: 60
                  maximum: 7200
                  default: 3000
                  description: Hard cap in seconds.
                inactivityTimeout:
                  type: integer
                  minimum: 10
                  maximum: 300
                  description: Seconds of silence before the agent reacts.
                inactivityAction:
                  type: string
                  enum:
                    - hang_up
                    - prompt
                recordingEnabled:
                  type: boolean
                  default: true
                connectionType:
                  $ref: '#/components/schemas/ConnectionType'
                websocket:
                  $ref: '#/components/schemas/WebSocketOptions'
                selectedTools:
                  type: array
                  items:
                    $ref: '#/components/schemas/InlineSelectedTool'
                metadata:
                  type: object
                  additionalProperties: true
      responses:
        '201':
          description: Call session created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                  websocketUrl:
                    type: string
                    description: Short-lived, single-use URL to stream audio to.
                  status:
                    type: string
                  connectionType:
                    type: string
                  createdAt:
                    type: string
                    format: date-time
        '400':
          description: |
            Missing `systemPrompt` / `voice` / `language`; an invalid `model`;
            an unsupported `connectionType`; a `websocket` connection without
            both sample rates; or a `selectedTools` entry setting more than one
            of `toolId` / `toolName` / `temporaryTool`.
        '402':
          description: Insufficient credits
        '429':
          description: Rate limit exceeded
components:
  schemas:
    ConnectionType:
      type: string
      enum:
        - twilio
        - telnyx
        - plivo
        - websocket
        - webrtc
      default: twilio
      description: |
        Which transport the returned `websocketUrl` is prepared for.

        `twilio` / `telnyx` / `plivo` — carrier media streams, **G.711 audio**.
        `websocket` — your own client; you choose the sample rates and codec.
        `webrtc` — browser transport, normally reached through the SDK.

        Any other value returns `400`.
    WebSocketOptions:
      type: object
      description: |
        Audio parameters. Only read when `connectionType` is `websocket` —
        telephony transports force G.711 at 8000 Hz regardless of what is sent
        here.
      required:
        - inputSampleRate
        - outputSampleRate
      properties:
        inputSampleRate:
          type: integer
          example: 16000
          description: |
            Sample rate of the audio you send, in Hz. **Required** when
            `connectionType` is `websocket` — omitting it returns `400`.
        outputSampleRate:
          type: integer
          example: 16000
          description: |
            Sample rate you want back, in Hz. **Required** when
            `connectionType` is `websocket`.
        codec:
          type: string
          enum:
            - pcm
            - g711
          default: g711
          description: '`pcm` for direct integrations, `g711` for telephony.'
        enableAudioBuffering:
          type: boolean
          description: Buffer audio to smooth jitter on unreliable links.
        twilioStream:
          type: boolean
          description: Format the stream for Twilio's `<Stream>` verb.
    InlineSelectedTool:
      type: object
      description: |
        A tool for one inline call. Set **exactly one** of `toolId`,
        `toolName`, or `temporaryTool` — setting more than one returns `400`.
      properties:
        toolId:
          type: string
          description: A tool already saved in your workspace.
        toolName:
          type: string
          description: A system tool, e.g. `hangUp`.
          example: hangUp
        temporaryTool:
          type: object
          description: |
            A full tool definition scoped to this call only. Same shape as a
            saved tool, but using the runtime's array form for parameters
            rather than the keyed-object form.
          properties:
            modelToolName:
              type: string
              pattern: ^[a-zA-Z][a-zA-Z0-9_]*$
            description:
              type: string
            timeout:
              $ref: '#/components/schemas/ToolTimeout'
            precomputable:
              type: boolean
              description: Runtime form of `readOnly`.
            dynamicParameters:
              type: array
              items:
                type: object
                properties:
                  name:
                    type: string
                  location:
                    $ref: '#/components/schemas/ParameterLocation'
                  required:
                    type: boolean
                  schema:
                    type: object
            staticParameters:
              type: array
              items:
                type: object
            automaticParameters:
              type: array
              items:
                type: object
            http:
              type: object
              properties:
                baseUrlPattern:
                  type: string
                  format: uri
                httpMethod:
                  type: string
                  enum:
                    - GET
                    - POST
                    - PUT
                    - PATCH
                    - DELETE
            client:
              type: object
              description: Empty object marks this as a client-executed tool.
    ToolTimeout:
      type: string
      pattern: ^\d+(\.\d+)?s$
      description: |
        Seconds with an `s` suffix, e.g. `"2.5s"` or `"10s"`. Must be greater
        than 0 and at most **40s**. Defaults to 2.5s when unset.
      example: 5s
    ParameterLocation:
      type: string
      description: |
        Where the value goes in the HTTP request. Both the short and the
        canonical long form are accepted on input; the long form is what is
        sent to the runtime.
      enum:
        - header
        - query
        - path
        - body
        - PARAMETER_LOCATION_HEADER
        - PARAMETER_LOCATION_QUERY
        - PARAMETER_LOCATION_PATH
        - PARAMETER_LOCATION_BODY
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: API key for authentication

````