openapi: 3.2.0 info: title: wazo-confd Moh API description: "Confd exposes an API for managing core resources on a Wazo server such as users, extensions, devices, voicemails, queues, etc. Resources can be associated together to provide additional functionality. For example: By associating a voicemail with a user, calls will automatically fallback on to the voicemail when the user cannot answer.\n\nImplementation notes\n====================\n\nErrors\n------\n\nResponses containing errors will have a status code in the 400 or 500 class. A list of error messages will be returned in the body of the response as a JSON-encoded array:\n\n~~~\n[\n \"Input error - User not found\",\n \"Resource error - User not associated to a line\"\n]\n~~~\n\n\nUpdating resources via PUT\n--------------------------\n\nWhen updating a resource, all fields become optional. In other words, only values that have been changed need to be sent to the server. Please note that this behavior may change in future versions of the API." version: '1.1' license: name: GPL v3 url: http://www.gnu.org/licenses/gpl.txt contact: name: Wazo Dev Team url: https://wazo-platform.org/ email: dev@wazo.community x-logo: url: https://wazo-platform.org/images/logo-black.svg backgroundColor: '#FAFAFA' altText: Wazo Logo servers: - url: /1.1 security: - wazo_auth_token: [] tags: - name: moh paths: /moh: get: operationId: list_moh summary: List MOH classes description: '**Required ACL:** `confd.moh.read`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/recurse' - $ref: '#/components/parameters/order' - $ref: '#/components/parameters/direction' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/offset' - $ref: '#/components/parameters/search' responses: '200': description: MOH list content: application/json: schema: $ref: '#/components/schemas/MohItems' post: operationId: create_moh summary: Create MOH class description: '**Required ACL:** `confd.moh.create`' tags: - moh responses: '201': description: MOH class created content: application/json: schema: $ref: '#/components/schemas/Moh' '400': $ref: '#/components/responses/CreateError' requestBody: content: application/json: schema: $ref: '#/components/schemas/Moh' description: MOH class to create required: true /moh/{moh_uuid}: get: operationId: get_moh summary: Get MOH class description: '**Required ACL:** `confd.moh.{moh_uuid}.read`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' responses: '200': description: MOH class content: application/json: schema: $ref: '#/components/schemas/Moh' '404': $ref: '#/components/responses/NotFoundError' put: operationId: update_moh summary: Update MOH class description: '**Required ACL:** `confd.moh.{moh_uuid}.update`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' responses: '204': $ref: '#/components/responses/ResourceUpdated' '400': $ref: '#/components/responses/UpdateError' '404': $ref: '#/components/responses/NotFoundError' requestBody: content: application/json: schema: $ref: '#/components/schemas/Moh' required: true delete: operationId: delete_moh summary: Delete MOH class description: '**Required ACL:** `confd.moh.{moh_uuid}.delete` Delete the MOH class and associated audio files. ' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' responses: '204': $ref: '#/components/responses/ResourceDeleted' '400': $ref: '#/components/responses/DeleteError' '404': $ref: '#/components/responses/NotFoundError' /moh/{moh_uuid}/files/{moh_filename}: get: operationId: get_moh_files summary: Get audio file description: '**Required ACL:** `confd.moh.{moh_uuid}.files.{moh_filename}.read`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' - $ref: '#/components/parameters/moh_filename' responses: '200': description: Audio file '404': $ref: '#/components/responses/NotFoundError' put: operationId: update_moh_files summary: Add or update audio file description: '**Required ACL:** `confd.moh.{moh_uuid}.files.{moh_filename}.update`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' - $ref: '#/components/parameters/moh_filename' responses: '204': $ref: '#/components/responses/ResourceUpdated' '404': $ref: '#/components/responses/NotFoundError' requestBody: content: application/octet-stream: schema: format: binary required: true delete: operationId: delete_moh_files summary: Delete audio file description: '**Required ACL:** `confd.moh.{moh_uuid}.files.{moh_filename}.delete`' tags: - moh parameters: - $ref: '#/components/parameters/tenantuuid' - $ref: '#/components/parameters/moh_uuid' - $ref: '#/components/parameters/moh_filename' responses: '204': $ref: '#/components/responses/ResourceDeleted' '404': $ref: '#/components/responses/NotFoundError' components: responses: NotFoundError: description: The resource requested was not found on the server content: application/json: schema: $ref: '#/components/schemas/Error' ResourceDeleted: description: Resource was deleted successfully ResourceUpdated: description: Resource was updated successfully CreateError: description: An error occurred when creating the resource content: application/json: schema: $ref: '#/components/schemas/Error' UpdateError: description: An error occurred when updating the resource content: application/json: schema: $ref: '#/components/schemas/Error' DeleteError: description: An error occurred when deleting the resource content: application/json: schema: $ref: '#/components/schemas/Error' parameters: tenantuuid: name: Wazo-Tenant in: header description: The tenant's UUID, defining the ownership of a given resource. required: false schema: type: string moh_uuid: required: true name: moh_uuid in: path schema: type: string offset: required: false name: offset in: query description: Number of items to skip over in the list. Useful for pagination. schema: type: integer order: required: false name: order in: query description: Name of the field to use for sorting the list of items returned. schema: type: string direction: required: false name: direction in: query description: Sort list of items in 'asc' (ascending) or 'desc' (descending) order schema: type: string enum: - asc - desc recurse: name: recurse in: query description: Should the query include sub-tenants required: false schema: type: boolean default: false search: required: false name: search in: query description: Search term for filtering a list of items. Only items with a field containing the search term will be returned. schema: type: string moh_filename: required: true name: moh_filename in: path schema: type: string limit: required: false name: limit in: query description: Maximum number of items to return in the list schema: type: integer schemas: MohItems: properties: items: type: array items: $ref: '#/components/schemas/Moh' total: type: integer required: - total Moh: allOf: - properties: uuid: type: string readOnly: true description: The UUID of the MOH class tenant_uuid: type: string description: The UUID of the tenant readOnly: true name: type: string description: The name used by Asterisk readOnly: true label: type: string description: The label of the MOH class mode: type: string description: 'The play mode of the MOH class. Notice: `mp3` is deprecated and should not be used' default: files enum: - custom - files - mp3 application: type: string description: The command to run (only used when mode is "custom") sort: type: string description: The order in which files are played (only used when mode is "files") enum: - alphabetical - random - random_start files: type: array readOnly: true description: The audio files items: $ref: '#/components/schemas/MohFile' - required: - label - mode Error: type: array items: type: string MohFile: properties: name: type: string description: The name of the file securitySchemes: wazo_auth_token: type: apiKey name: X-Auth-Token in: header x-xivo-port: 9486 x-xivo-name: confd x-apievangelist-source: harvested_from: https://github.com/wazo-platform/wazo-confd assembly: base plugin api.yml deep-merged with all plugin api.yml fragments, reproducing what the running service serves at /api/confd/1.1/api/api.yml (see wazo_confd/plugins/api/http.py — xivo.chain_map.ChainMap) spec_version: Swagger 2.0 (as published by Wazo) harvested: '2026-08-17'