ARI: Music on Hold/Background Music for bridges

Adds ARI functions to be able to turn on/off music on hold in a
bridge. It actually functions more as a background music without
further actions on the bridge since if the rest of the channels
in the bridge aren't explicitly muted, they will still be able
to communicate.

(closes issue ASTERISK-21974)
Reported by: Matt Jordan
Review: https://reviewboard.asterisk.org/r/2688/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@397505 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Jonathan Rose
2013-08-23 00:26:19 +00:00
parent c25c093c67
commit 21e22310c7
6 changed files with 556 additions and 2 deletions

View File

@@ -176,6 +176,79 @@
}
]
},
{
"path": "/bridges/{bridgeId}/mohStart",
"description": "Play music on hold to a bridge",
"operations": [
{
"httpMethod": "POST",
"summary": "Play music on hold to a bridge or change the MOH class that is playing.",
"nickname": "mohStartBridge",
"responseClass": "void",
"parameters": [
{
"name": "bridgeId",
"description": "Bridge's id",
"paramType": "path",
"required": true,
"allowMultiple": false,
"dataType": "string"
},
{
"name": "mohClass",
"description": "Channel's id",
"paramType": "query",
"required": false,
"allowMultiple": false,
"dataType": "string"
}
],
"errorResponses": [
{
"code": 404,
"reason": "Bridge not found"
},
{
"code": 409,
"reason": "Bridge not in Stasis application"
}
]
}
]
},
{
"path": "/bridges/{bridgeId}/mohStop",
"description": "Stop music on hold for a bridge",
"operations": [
{
"httpMethod": "POST",
"summary": "Stop playing music on hold to a bridge.",
"notes": "This will only stop music on hold being played via bridges/{bridgeId}/mohStart.",
"nickname": "mohStopBridge",
"responseClass": "void",
"parameters": [
{
"name": "bridgeId",
"description": "Bridge's id",
"paramType": "path",
"required": true,
"allowMultiple": false,
"dataType": "string"
}
],
"errorResponses": [
{
"code": 404,
"reason": "Bridge not found"
},
{
"code": 409,
"reason": "Bridge not in Stasis application"
}
]
}
]
},
{
"path": "/bridges/{bridgeId}/play",
"description": "Play media to the participants of a bridge",