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

# Upsert Assistant Widget

> Create or update the default widget config for an assistant.



## OpenAPI

````yaml /openapi.json put /api/assistants/{assistant_id}/widget
openapi: 3.1.0
info:
  description: >-
    Build and run voice assistants: configure an assistant, give it tools,
    knowledge and playbooks, place and read calls, and manage contacts,
    campaigns and analytics.


    Authenticate every request with an API key as a bearer token. See the API
    introduction for the response envelope, pagination and error shapes.
  title: Qall API
  version: 0.1.0
servers:
  - description: Production
    url: https://qall.io
security: []
paths:
  /api/assistants/{assistant_id}/widget:
    put:
      tags:
        - assistant-widgets
      summary: Upsert Assistant Widget
      description: Create or update the default widget config for an assistant.
      operationId: upsert_assistant_widget_api_assistants__assistant_id__widget_put
      parameters:
        - in: path
          name: assistant_id
          required: true
          schema:
            title: Assistant Id
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WidgetConfigPayload'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WidgetConfigResponse'
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
      security:
        - HTTPBearer: []
components:
  schemas:
    WidgetConfigPayload:
      description: Upsert payload — the config blob the frontend sends.
      properties:
        config:
          additionalProperties: true
          title: Config
          type: object
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
      title: WidgetConfigPayload
      type: object
    WidgetConfigResponse:
      description: Full response for authenticated dashboard endpoints.
      properties:
        assistant_id:
          title: Assistant Id
          type: integer
        config:
          additionalProperties: true
          title: Config
          type: object
        created_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Created At
        id:
          title: Id
          type: integer
        is_active:
          title: Is Active
          type: boolean
        is_default:
          title: Is Default
          type: boolean
        name:
          title: Name
          type: string
        updated_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Updated At
      required:
        - id
        - assistant_id
        - name
        - is_default
        - is_active
        - config
      title: WidgetConfigResponse
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    HTTPBearer:
      scheme: bearer
      type: http

````

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