{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/dialogbrain-com/json-schema/dialogbrain-com-post-sessions-request-schema.json",
  "title": "PostSessionsRequest",
  "description": "Request to join a Google Meet and dispatch bot.",
  "x-generated": "2026-10-30",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/dialogbrain-com-openapi.json#/components/schemas/PostSessionsRequest",
  "properties": {
    "meet_url": {
      "type": "string",
      "title": "Meet Url",
      "description": "Google Meet or Microsoft Teams meeting link"
    },
    "agent_id": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Agent Id",
      "description": "AI agent ID. Omit (or null) for TRANSCRIBE-ONLY: the bot joins and transcribes into the thread but never speaks and runs no agentic session. A ws-0 template id is accepted and forked into the workspace on use."
    },
    "vision_mode": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "off",
            "on_demand",
            "continuous_0_3fps"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Vision Mode",
      "description": "Screen-share vision mode. None → default-derive from the agent's vision_enabled flag (enabled → 'continuous_0_3fps', else 'off'). 'off' = no vision; 'on_demand' = the agent can call vision.query; 'continuous_0_3fps' = every agent turn carries a low-detail ambient screen frame + vision.query for fine detail."
    },
    "instructions": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Instructions",
      "description": "Task brief for the agent once it joins (e.g. 'greet everyone and present the overview deck'). Woven into the voice system prompt."
    },
    "start_immediately": {
      "type": "boolean",
      "title": "Start Immediately",
      "description": "If true, the agent starts talking as soon as it joins (greets + begins the task) instead of waiting for a wake-word.",
      "default": false
    },
    "translation_mode": {
      "type": "boolean",
      "title": "Translation Mode",
      "description": "If true, pre-arm translator mode (auto-target language) on join with zero verbal trigger. Forces meet_audio_path ∈ {framework, hybrid} so the original-speaker track exists for listener audio path.",
      "default": false
    },
    "target_language": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Target Language",
      "description": "Primary target language spoken INTO the Meet call (e.g. 'en', 'es', 'fr'). Used with translation_mode=True."
    },
    "app_languages": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "App Languages",
      "description": "Extra target languages translated for the APP ONLY (text + listenable audio in the inbox), never spoken into the Meet call. Each runs its own translation engine. Max 4. ISO codes, e.g. ['de', 'fr']. Used with translation_mode=True."
    },
    "stt_provider": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Stt Provider",
      "description": "Speech-recognition provider for THIS session: 'deepgram' or 'gladia'. Omit to use the agent's setting, then the workspace default. Gladia covers ~115 languages including Uzbek, Kazakh and Tajik, which Deepgram does not."
    },
    "stt_model": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Stt Model",
      "description": "Recognition model within the provider, e.g. 'flux' or 'nova-3' for Deepgram. Omit to use the agent's setting, then the workspace default."
    },
    "source_language": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Source Language",
      "description": "Spoken language of the meeting (any ISO code: 'en', 'ru', 'zh', ...). When set, speech recognition runs in that language's dedicated mode for better accuracy. Omit when participants may speak multiple languages — recognition then autodetects. Independent of translation_mode: improves plain transcription too."
    },
    "tts_provider": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tts Provider",
      "description": "Translator VOICE provider (the TTS the translator speaks with). One of the translation-capable providers (cartesia, openai, deepgram, ...). Only with translation_mode. Omit for the workspace default translation voice."
    },
    "tts_voice": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tts Voice",
      "description": "Specific voice id for tts_provider (e.g. 'nova' for openai). Omit for the provider's default voice."
    },
    "silent": {
      "type": "boolean",
      "title": "Silent",
      "description": "Silent translator dispatch: the translator never speaks into the Meet call (participants hear no bot voice). Translation audio + subtitles remain available in the app (translator-tts tracks / listen overlay). Only meaningful with translation_mode=True.",
      "default": false
    },
    "comeback_phrase": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Comeback Phrase",
      "description": "Phrase or word to trigger return to original language during translation. e.g. 'Back to English'. Optional."
    },
    "meet_audio_path": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Meet Audio Path",
      "description": "Audio routing strategy: 'direct' (bot input bypasses framework), 'framework' (bot hears all participants via SFU), 'hybrid' (bot hears and speaks via framework, guests routed direct). None → default-derive. Rejected when translation_mode=True (must be framework or hybrid)."
    }
  },
  "type": "object",
  "required": [
    "meet_url"
  ]
}