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

# Create Music on Hold

> Create a music on hold and its MEDIAFILE destinations



## OpenAPI

````yaml https://api.voxo.co/v2/docs/openapi.json post /v2/admin/music-on-hold/
openapi: 3.1.0
info:
  title: VOXO API
  description: VOXO Communication Platform API
  version: 2.0.0
servers:
  - url: https://api.voxo.co
security:
  - bearerAuth: []
paths:
  /v2/admin/music-on-hold/:
    post:
      tags:
        - Music On Hold
      summary: Create Music on Hold
      description: Create a music on hold and its MEDIAFILE destinations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                tenantId:
                  type: integer
                  minimum: 0
                  maximum: 9007199254740991
                  description: Tenant ID (0 for system/global)
                name:
                  type: string
                  description: Music on hold name
                isLinear:
                  type: boolean
                  description: Play tracks in linear order
                defaultTenant:
                  default: false
                  description: Set as the tenant's default music on hold
                  type: boolean
                routingDestinations:
                  type: array
                  items:
                    type: object
                    properties:
                      type:
                        type: string
                        enum:
                          - MEDIAFILE
                      id:
                        type: number
                    required:
                      - type
                      - id
                  description: Ordered MEDIAFILE destinations that make up the playlist
              required:
                - tenantId
                - name
                - isLinear
                - routingDestinations
              additionalProperties: false
      responses:
        '200':
          description: Created music on hold
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: number
                    description: Music on hold ID
                  tenantId:
                    type: number
                    description: Tenant ID (0 = system)
                  name:
                    type: string
                    description: Music on hold name
                  isLinear:
                    type: boolean
                    description: Tracks play in linear order
                  defaultTenant:
                    type: boolean
                    description: Is the tenant's default music on hold
                  routingDestinations:
                    default: []
                    description: Ordered MEDIAFILE destinations
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: number
                          description: Destination target ID
                        destType:
                          type: string
                          description: Destination type
                        order:
                          description: Ordering within the group
                          type: number
                        typeSrc:
                          description: Source routing slot
                          type: string
                        name:
                          description: Destination name
                          anyOf:
                            - type: string
                            - type: 'null'
                        number:
                          description: Destination number
                          anyOf:
                            - type: string
                            - type: 'null'
                      required:
                        - id
                        - destType
                      additionalProperties: {}
                required:
                  - id
                  - tenantId
                  - name
                  - isLinear
                  - defaultTenant
                  - routingDestinations
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````