From dd48d60c5ba239f76b054b1bb6c1e17c68537497 Mon Sep 17 00:00:00 2001 From: Mark Michelson Date: Wed, 30 Mar 2016 17:01:28 -0500 Subject: ARI: Add method to create a new channel. This adds a new ARI method to the channels resource that allows for the creation of a new channel. The channel is created and then placed into the specified Stasis application. This is different from the existing originate method that creates a channel, dials it, and then places the answered channel into the dialplan or a Stasis application. This method does not attempt to call the channel at all. Dialing is left as a later step after channel creation. This allows for pre-dialing channel manipulation if desired. ASTERISK-25889 Change-Id: I3c96a0aba914b08e39f6256371a5bd4c92cbded8 --- rest-api/api-docs/channels.json | 62 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) (limited to 'rest-api') diff --git a/rest-api/api-docs/channels.json b/rest-api/api-docs/channels.json index bc0879b57..a4489fb7d 100644 --- a/rest-api/api-docs/channels.json +++ b/rest-api/api-docs/channels.json @@ -139,6 +139,68 @@ } ] }, + { + "path": "/channels/create", + "description": "Create a channel and place it in a Stasis app, but do not dial the channel yet.", + "operations": [ + { + "httpMethod": "POST", + "summary": "Create channel.", + "nickname": "create", + "responseClass": "Channel", + "parameters": [ + { + "name": "endpoint", + "description": "Endpoint for channel communication", + "paramType": "query", + "required": true, + "allowMultiple": false, + "dataType": "string" + }, + { + "name": "app", + "description": "Stasis Application to place channel into", + "paramType": "query", + "required": true, + "allowMultiple": false, + "dataType": "string" + }, + { + "name": "appArgs", + "description": "The application arguments to pass to the Stasis application provided by 'app'. Mutually exclusive with 'context', 'extension', 'priority', and 'label'.", + "paramType": "query", + "required": false, + "allowMultiple": false, + "dataType": "string" + }, + { + "name": "channelId", + "description": "The unique id to assign the channel on creation.", + "paramType": "query", + "required": false, + "allowMultiple": false, + "dataType": "string" + }, + { + "name": "otherChannelId", + "description": "The unique id to assign the second channel when using local channels.", + "paramType": "query", + "required": false, + "allowMultiple": false, + "dataType": "string" + }, + { + "name": "originator", + "description": "Unique ID of the calling channel", + "paramType": "query", + "required": false, + "allowMultiple": false, + "dataType": "string" + } + ] + } + ] + }, { "path": "/channels/{channelId}", "description": "Active channel", -- cgit v1.2.3