Query CDR Recordings
Queries all recording segments associated with a CDR, including the waveform and speaker data.
Request URL
GET {base_url}/uc-creport/api/v1/cdr/{cdrMainId}/recordings
Request parameters
- Headers
-
Parameter Required Type Description Authorization Yes String The access token used for authentication. Format: Bearer
{access_token}.x-tenant-code Yes String The tenant name. Note: You can obtain tenant name using the Query Tenants interface.
- Path parameters
-
Parameter Required Type Description cdrMainId Yes String The ID of the CDR main record. You can obtain the ID using the Search Recordings interface.
Response parameters
| Parameter | Type | Description |
|---|---|---|
| requestId | String | The unique ID of the request, which can be used to quickly locate the request. |
| code | String | The HTTP status code of the request.
|
| message | String | The status message of the request. |
| detailMessage | String | The detailed error information. When the request is successful, this parameter returns empty. |
| result | Object<CDR_Recordings_Result> | The recording segments of the CDR. |
- CDR_Recordings_Result
-
Parameter Type Description recordings Array<Recording_Segment> The list of recording segments, including the waveform and speaker data. totalDuration Integer The total duration of all segments, in milliseconds. totalSize String The total size of all segments, in bytes.
- Recording_Segment
-
Parameter Type Description id String The ID of the recording segment. duration Integer The duration of the segment, in milliseconds. format String The format of the recording:
wavmp3
speakerSegments Array<Speaker_Segment> The speaker segments, which are used by the front end to render the call timeline. waveformSamples String The waveform amplitude samples, which is gzip-compressed binary data. startTime String The start time of the segment, in Unix timestamp format (microseconds). cdrLegId String The CDR leg ID.
- Speaker_Segment
-
Parameter Type Description speaker String The role of the speaker:
caller: The caller.callee: The callee.
number String The number of the speaker. name String The name of the speaker. avatar String The URL of the avatar. segments Array<Time_Range> The list of active time ranges of the speaker.
- Time_Range
-
Parameter Type Description startMs Integer The start of the time range, in milliseconds. endMs Integer The end of the time range, in milliseconds.
Example
Request example
GET /uc-creport/api/v1/cdr/347642293061275648/recordings HTTP/1.1
Host: api.cn.novoone.com
Authorization: Bearer eyJraWQiOiJjbi0wLWtleS0xIiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJkaXN0cmlidXRvcmV4YW1wbGVAb3V0bG9vay5jb20iLCJhcHBfa2V5Ijoic2xOdnQzaH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3380fb3", "code": "200", "message": "SUCCESS", "detailMessage": "", "result": { "recordings": [ { "id": "347642307762311168", "duration": 383520, "format": "wav", "speakerSegments": [ { "speaker": "caller", "number": "1000", "name": "Leo Ball", "avatar": "https://novo-one-tst-self-operated-business.s3.ap-east-1.amazonaws.com/public/platform/colortest2/user_avatar/1786586611608/1.png", "segments": [ { "startMs": 6036, "endMs": 6037 }, { "startMs": 28332, "endMs": 28384 }, { "startMs": 29762, "endMs": 29769 }, { "startMs": 68534, "endMs": 68600 }, { "startMs": 145016, "endMs": 146338 }, { "startMs": 146672, "endMs": 147323 }, { "startMs": 147636, "endMs": 147806 }, { "startMs": 150364, "endMs": 150365 }, { "startMs": 156588, "endMs": 156592 }, { "startMs": 156905, "endMs": 156926 }, { "startMs": 175972, "endMs": 175974 }, { "startMs": 176485, "endMs": 176487 }, { "startMs": 177327, "endMs": 177335 }, { "startMs": 269674, "endMs": 269675 }, { "startMs": 300225, "endMs": 300227 }, { "startMs": 307159, "endMs": 307160 }, { "startMs": 313286, "endMs": 313288 }, { "startMs": 314516, "endMs": 314517 }, { "startMs": 320406, "endMs": 320408 }, { "startMs": 326726, "endMs": 326730 }, { "startMs": 327192, "endMs": 327196 }, { "startMs": 333474, "endMs": 333476 }, { "startMs": 344592, "endMs": 344617 }, { "startMs": 368726, "endMs": 368917 }, { "startMs": 378369, "endMs": 378403 } ] }, { "speaker": "callee", "number": "1001", "name": "Terrell Smith", "avatar": "https://novo-one-tst-self-operated-business.s3.ap-east-1.amazonaws.com/public/platform/colortest2/user_avatar/1786586587824/2.png", "segments": [] } ], "waveformSamples": "H4sIAAAAAAAC/+zdzW6bTBTG8XnOmQ+TOG9eqVEWrbqpqqx7M73/W6mw/KWEONgesIH/bxPFBgzjmcMcYMYBGEZU70W3S7rmc/QKQdL+0KZ4BOr4iu6mcK9cAIPWHEmzOp7NMRm1Ciei/ZT3fpSPsW0ZxXOjyYhl0TyvU0kuu4/WnsW5bDQ273MyPSOM1XZE3AIdIAAAMNTZu7i75NH2VxgALC0OjNn42wR36sGGYDmHWm8e3d049ZH4Y0I16NSaRnMmhvQQl1xNaCCUP2WLE6dR6atn0TZvGkUFAAAA3DYD0jYNklLHqyGUzR9br6ylwx2ZLHN5yZLps0FMb7+eSmmyr/3395LWf0Nwl35Gezaldku5XcoPqzZd6YUdD/A67KW5UjIpFMtvVtzkf3KO7UuvbTriUniJuTz+t2qyRY///3hqSk6SzLpyGHdzT+5u0U27YigLryGPS2kIXAy4A02zvcm2+zbkx21V+SG2cehmV264hgEAC+0vT2EnY829VDm/a9QM0Jl6SV0blS35Jo7qr6gh90z1thrprwMYI+nrDjZOycT+8zeQOQN0T0cN3APOJvVZVhSZwAo0/H5dApoKAAAAAADAaLSgT8W9cf94Pd2/esQjvV/n/HuM6cOHHP27HyYQ/ZKnTUSUAAAAs+kEXPqzPfQezmbkojv5Vo98H0Ye6JLqTa1fsBQnWBXufzdrh4JaT+3V/3Hd3OPaw8M5Q7TqjpxZMYVqhdZDEe5OtJQERg5hIbx6d/jXbmrLzfSW28opHS1OdSXG93r72sFixQmNAOp6KIkePAAAOEpjrukZ5KoZ1SwUhfTuOFf9bvB5dBMTjgAXhrJaG8rfnmI2OTnTcv0LAAD//yLdfQrQlQAA", "startTime": "1786951197826217", "cdrLegId": "347642293061275650" } ], "totalDuration": 383520, "totalSize": "6136398" } }