openapi: 3.2.0 info: title: Apidaze Voice - VoIP Innovations XML Scripting API version: v1.1.1 termsOfService: https://developer.kpn.com/legal contact: name: API Support email: api_developer@kpn.com url: https://developer.kpn.com/support description: "This REST API exposes actions that help your apps to interact with APIdaze’s Telco platform in mulitples ways. You can set the URL from where Apidaze fetchs XML instructions to run on Apidaze platform. You can write your various scripts there using the [Script Reference doc](https://developer.kpn.com/script-reference-documentation), and test them. You can manage your phone numbers, connect directly with other SIP carriers (inbound and outbound), manage your SIP accounts, voicemail boxes and messages, provision your hardphones.\n## [Source view](https://app.swaggerhub.com/apis/kpn/apidaze-voice-voip-innovations/)
[Documentation view](https://app.swaggerhub.com/apis-docs/kpn/apidaze-voice-voip-innovations/)\n---\n## [KPN Developer](https://developer.kpn.com/)
[Getting Started](https://developer.kpn.com/getting-started)\n---\n " servers: - url: https://api-prd.kpn.com/communication/apidaze/cpaas tags: - name: XML Scripting API paths: /externalscripts: get: summary: External Script List tags: - XML Scripting API description: Returns the list of the external scripts for your domain. Only one external script is allowed per domain. responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/XMLScriptingResponse' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] post: summary: External Script Create tags: - XML Scripting API description: Creates a new external script. responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/XMLScriptingResponse' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] requestBody: content: application/x-www-form-urlencoded: schema: type: object properties: name: type: string description: name of the external script. url: type: string description: URL of the external script. This URL is fetched when a calls is placed to one of your numbers required: - url /externalscripts/{id}: get: summary: External Script Read tags: - XML Scripting API description: Returns the External Script object details by id. parameters: - in: path name: id description: id of the external script. required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/XMLScriptingResponse' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] put: summary: External Script Update tags: - XML Scripting API description: Updates the external script. parameters: - in: path name: id description: id of the external script. required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/XMLScriptingResponse' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] requestBody: content: application/x-www-form-urlencoded: schema: type: object properties: name: type: string description: name of the external script. url: type: string description: URL of the external script. This URL is fetched when a calls is placed to one of your numbers required: - url delete: summary: External Script Delete tags: - XML Scripting API description: Deletes the external script. parameters: - in: path name: id description: id of the external script. required: true schema: type: string responses: '204': description: OK '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] /externalscripts/test: get: summary: External Script Test tags: - XML Scripting API description: Tests in real time your External Script by fetching its URL and returning the XML instructions. You can send any parameter in the request and therefore check the proper behaviour of the script depending on how call are placed (to a DID, from a SIP account, from WebRTC/JavaScript, etc.). Only one external script is allowed per domain. responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/XMLScriptingResponse' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '429': description: Too Many Requests content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '503': description: Service Unavailable content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' security: - OAuth2: [] requestBody: content: application/x-www-form-urlencoded: schema: type: object properties: url: type: string description: URL of your External Script if empty. required: - url components: schemas: XMLScriptingObject: type: object properties: id: type: string description: id of the external script title: id name: type: string description: name of the external script title: name url: type: string description: url of the external script title: url created_at: type: string description: creation date of the external script title: created_at updated_at: type: string description: updation date of the external script title: updated_at ErrorResponse: type: object properties: transactionId: type: string description: transaction id of the the request title: Transaction ID status: type: string description: Status title: Status name: type: string description: Error name title: Error name message: type: string description: Error message title: Error message info: type: string description: Additional information about error title: Info XMLScriptingResponse: type: array items: $ref: '#/components/schemas/XMLScriptingObject' description: Response containing the list of the external scripts for your domain. securitySchemes: OAuth2: type: oauth2 flows: clientCredentials: scopes: {} tokenUrl: https://api-prd.kpn.com/oauth/client_credential/accesstoken?grant_type=client_credentials externalDocs: description: HTTP response headers url: https://developer.kpn.com/documentation-response-headers