2013-04-22 14:58:53 +00:00
{
"_copyright" : "Copyright (C) 2012 - 2013, Digium, Inc." ,
"_author" : "David M. Lee, II <dlee@digium.com>" ,
"_svn_revision" : "$Revision$" ,
2016-11-18 09:46:48 -06:00
"apiVersion" : "2.0.0" ,
2013-04-22 14:58:53 +00:00
"swaggerVersion" : "1.1" ,
2014-09-20 23:41:55 +00:00
"basePath" : "http://localhost:8088/ari" ,
2013-04-22 14:58:53 +00:00
"resourcePath" : "/api-docs/recordings.{format}" ,
2018-01-18 10:01:26 -05:00
"requiresModules" : [
"res_stasis_recording"
] ,
2013-04-22 14:58:53 +00:00
"apis" : [
{
"path" : "/recordings/stored" ,
"description" : "Recordings" ,
"operations" : [
{
"httpMethod" : "GET" ,
"summary" : "List recordings that are complete." ,
2013-11-07 21:10:31 +00:00
"nickname" : "listStored" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "List[StoredRecording]"
}
]
} ,
{
2013-07-03 17:58:45 +00:00
"path" : "/recordings/stored/{recordingName}" ,
2013-04-22 14:58:53 +00:00
"description" : "Individual recording" ,
"operations" : [
{
"httpMethod" : "GET" ,
"summary" : "Get a stored recording's details." ,
2013-11-07 21:10:31 +00:00
"nickname" : "getStored" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "StoredRecording" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-30 13:28:50 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
}
2013-04-22 14:58:53 +00:00
]
} ,
{
"httpMethod" : "DELETE" ,
"summary" : "Delete a stored recording." ,
2013-11-07 21:10:31 +00:00
"nickname" : "deleteStored" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-30 13:28:50 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
}
2013-04-22 14:58:53 +00:00
]
}
]
} ,
2016-05-18 06:19:58 -05:00
{
"path" : "/recordings/stored/{recordingName}/file" ,
"description" : "The actual file associated with the stored recording" ,
"operations" : [
{
"httpMethod" : "GET" ,
"summary" : "Get the file associated with the stored recording." ,
"nickname" : "getStoredFile" ,
"responseClass" : "binary" ,
"parameters" : [
{
"name" : "recordingName" ,
"description" : "The name of the recording" ,
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
] ,
"errorResponses" : [
{
"code" : 403 ,
"reason" : "The recording file could not be opened"
} ,
{
"code" : 404 ,
"reason" : "Recording not found"
}
]
}
]
} ,
2014-07-18 21:48:46 +00:00
{
"path" : "/recordings/stored/{recordingName}/copy" ,
"description" : "Copy an individual recording" ,
"operations" : [
{
"httpMethod" : "POST" ,
"summary" : "Copy a stored recording." ,
"nickname" : "copyStored" ,
"responseClass" : "StoredRecording" ,
"parameters" : [
{
"name" : "recordingName" ,
"description" : "The name of the recording to copy" ,
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
} ,
{
"name" : "destinationRecordingName" ,
"description" : "The destination name of the recording" ,
"paramType" : "query" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
} ,
{
"code" : 409 ,
"reason" : "A recording with the same name already exists on the system"
}
]
}
]
} ,
2013-04-22 14:58:53 +00:00
{
2013-07-03 17:58:45 +00:00
"path" : "/recordings/live/{recordingName}" ,
2013-04-22 14:58:53 +00:00
"description" : "A recording that is in progress" ,
"operations" : [
{
"httpMethod" : "GET" ,
"summary" : "List live recordings." ,
2013-11-07 21:10:31 +00:00
"nickname" : "getLive" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "LiveRecording" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
}
2013-04-22 14:58:53 +00:00
]
} ,
{
"httpMethod" : "DELETE" ,
"summary" : "Stop a live recording and discard it." ,
2013-11-07 21:10:31 +00:00
"nickname" : "cancel" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
}
2013-04-22 14:58:53 +00:00
]
}
]
} ,
{
2013-07-03 17:58:45 +00:00
"path" : "/recordings/live/{recordingName}/stop" ,
2013-04-22 14:58:53 +00:00
"operations" : [
{
"httpMethod" : "POST" ,
"summary" : "Stop a live recording and store it." ,
2013-11-07 21:10:31 +00:00
"nickname" : "stop" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
}
2013-04-22 14:58:53 +00:00
]
}
]
} ,
{
2013-07-03 17:58:45 +00:00
"path" : "/recordings/live/{recordingName}/pause" ,
2013-04-22 14:58:53 +00:00
"operations" : [
{
"httpMethod" : "POST" ,
"summary" : "Pause a live recording." ,
2013-08-06 14:44:45 +00:00
"notes" : "Pausing a recording suspends silence detection, which will be restarted when the recording is unpaused. Paused time is not included in the accounting for maxDurationSeconds." ,
2013-11-07 21:10:31 +00:00
"nickname" : "pause" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
} ,
{
"code" : 409 ,
"reason" : "Recording not in session"
}
2013-04-22 14:58:53 +00:00
]
2013-11-07 21:10:31 +00:00
} ,
2013-04-22 14:58:53 +00:00
{
2013-11-07 21:10:31 +00:00
"httpMethod" : "DELETE" ,
2013-04-22 14:58:53 +00:00
"summary" : "Unpause a live recording." ,
2013-11-07 21:10:31 +00:00
"nickname" : "unpause" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
} ,
{
"code" : 409 ,
"reason" : "Recording not in session"
}
2013-04-22 14:58:53 +00:00
]
}
]
} ,
{
2013-07-03 17:58:45 +00:00
"path" : "/recordings/live/{recordingName}/mute" ,
2013-04-22 14:58:53 +00:00
"operations" : [
{
"httpMethod" : "POST" ,
"summary" : "Mute a live recording." ,
2013-07-03 17:58:45 +00:00
"notes" : "Muting a recording suspends silence detection, which will be restarted when the recording is unmuted." ,
2013-11-07 21:10:31 +00:00
"nickname" : "mute" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
} ,
{
"code" : 409 ,
"reason" : "Recording not in session"
}
2013-04-22 14:58:53 +00:00
]
2013-11-07 21:10:31 +00:00
} ,
2013-04-22 14:58:53 +00:00
{
2013-11-07 21:10:31 +00:00
"httpMethod" : "DELETE" ,
2013-04-22 14:58:53 +00:00
"summary" : "Unmute a live recording." ,
2013-11-07 21:10:31 +00:00
"nickname" : "unmute" ,
2013-04-22 14:58:53 +00:00
"responseClass" : "void" ,
"parameters" : [
{
2013-07-03 17:58:45 +00:00
"name" : "recordingName" ,
"description" : "The name of the recording" ,
2013-04-22 14:58:53 +00:00
"paramType" : "path" ,
"required" : true ,
"allowMultiple" : false ,
"dataType" : "string"
}
2013-08-06 14:44:45 +00:00
] ,
"errorResponses" : [
{
"code" : 404 ,
"reason" : "Recording not found"
} ,
{
"code" : 409 ,
"reason" : "Recording not in session"
}
2013-04-22 14:58:53 +00:00
]
}
]
}
] ,
"models" : {
"StoredRecording" : {
"id" : "StoredRecording" ,
2013-07-03 16:32:41 +00:00
"description" : "A past recording that may be played back." ,
2013-04-22 14:58:53 +00:00
"properties" : {
2013-08-30 13:28:50 +00:00
"name" : {
2013-04-22 14:58:53 +00:00
"required" : true ,
"type" : "string"
} ,
2013-08-30 13:28:50 +00:00
"format" : {
2013-04-22 14:58:53 +00:00
"required" : true ,
2013-08-30 13:28:50 +00:00
"type" : "string"
2013-04-22 14:58:53 +00:00
}
}
} ,
"LiveRecording" : {
"id" : "LiveRecording" ,
2013-07-03 16:32:41 +00:00
"description" : "A recording that is in progress" ,
2013-04-22 14:58:53 +00:00
"properties" : {
2013-07-19 19:35:21 +00:00
"name" : {
"required" : true ,
2013-08-30 13:28:50 +00:00
"type" : "string" ,
"description" : "Base name for the recording"
} ,
"format" : {
"required" : true ,
"type" : "string" ,
"description" : "Recording format (wav, gsm, etc.)"
} ,
2014-03-06 18:20:37 +00:00
"target_uri" : {
"required" : true ,
"type" : "string" ,
"description" : "URI for the channel or bridge being recorded"
} ,
2013-08-30 13:28:50 +00:00
"state" : {
2014-07-25 14:47:09 +00:00
"required" : true ,
2013-08-30 13:28:50 +00:00
"type" : "string" ,
"allowableValues" : {
"valueType" : "LIST" ,
"values" : [
"queued" ,
2013-10-25 21:28:32 +00:00
"recording" ,
2013-08-30 13:28:50 +00:00
"paused" ,
2013-10-25 21:28:32 +00:00
"done" ,
"failed" ,
"canceled"
2013-08-30 13:28:50 +00:00
]
}
2013-07-19 19:35:21 +00:00
} ,
2014-07-25 14:47:09 +00:00
"duration" : {
"required" : false ,
"type" : "int" ,
"description" : "Duration in seconds of the recording"
} ,
"talking_duration" : {
"required" : false ,
"type" : "int" ,
"description" : "Duration of talking, in seconds, detected in the recording. This is only available if the recording was initiated with a non-zero maxSilenceSeconds."
} ,
"silence_duration" : {
"required" : false ,
"type" : "int" ,
"description" : "Duration of silence, in seconds, detected in the recording. This is only available if the recording was initiated with a non-zero maxSilenceSeconds."
} ,
2013-11-23 12:52:54 +00:00
"cause" : {
"required" : false ,
"type" : "string" ,
"description" : "Cause for recording failure if failed"
2013-04-22 14:58:53 +00:00
}
}
}
}
}