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

# Enable/disable embeded search widget for media

> Enable/disable embeded search widget for media. Returns embed link if enabled. Embed link is in the form of https://app.trytldw.ai/embed/media/{media_id} which can be put in an iframe, and you can add hide_tags=true and hide_segment_desc=true to hide unwanted section as needed.



## OpenAPI

````yaml put /widget/media/{media_id}
openapi: 3.1.0
info:
  title: tl;dw
  version: 0.0.1
  x-logo:
    url: https://app.trytldw.ai/static/images/sidebar_logo.svg
    backgroundColor: transparent
    altText: tl;dw Logo
  contact:
    name: tl;dw Support
    url: https://app.trytldw.ai/support
  termsOfService: https://app.trytldw.ai/terms
  x-apisguru-categories:
    - video
    - ai
servers:
  - url: https://api.trytldw.ai/v1
security: []
tags:
  - name: Collection
    description: Collection
  - name: Video
    description: Media
  - name: Account
    description: Account
paths:
  /widget/media/{media_id}:
    put:
      tags:
        - Embed UI Widget
      summary: Enable/disable embeded search widget for media
      description: >-
        Enable/disable embeded search widget for media. Returns embed link if
        enabled. Embed link is in the form of
        https://app.trytldw.ai/embed/media/{media_id} which can be put in an
        iframe, and you can add hide_tags=true and hide_segment_desc=true to
        hide unwanted section as needed.
      operationId: update_media_widget_widget_media__media_id__put
      parameters:
        - name: media_id
          in: path
          required: true
          schema:
            type: string
            description: Id of media to config widget
            title: Media Id
          description: Id of media to config widget
      requestBody:
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/src__public_api__widget_router__EmbedMediaRequest
              description: Config to enable/disable widget
              default:
                enabled: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/src__public_api__widget_router__EmbedMediaResponse
        '404':
          description: Media not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    src__public_api__widget_router__EmbedMediaRequest:
      properties:
        enabled:
          type: boolean
          title: Enabled
          default: true
      type: object
      title: EmbedMediaRequest
    src__public_api__widget_router__EmbedMediaResponse:
      properties:
        embed_link:
          anyOf:
            - type: string
            - type: 'null'
          title: Embed Link
      type: object
      required:
        - embed_link
      title: EmbedMediaResponse
    ErrorResponse:
      properties:
        detail:
          type: string
          title: Detail
      type: object
      required:
        - detail
      title: ErrorResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````