Sign inGet started

List calls from a channel

Use this request to GET a list of all incoming and outgoing calls of a specific channel. You can include additional query parameters to filter the retrieved list.
GET
/workspaces/{workspaceId}/channels/{channelId}/calls
Get a list of calls from a channel
查询参数
limit
integer
Limits the number of results to return.
pageToken
string
The cursor that keeps track of the current position in the results.
startAt
string
Start date for the query
endAt
string
End date for the query
status
string
Possible values: accepted, starting, ringing, ongoing, completed, busy, no-answer, failed, cancelled, scheduled
type
string
Possible values: pstn, sip, webrtc
to
string
from
string
duration
integer
direction
string
Possible values: incoming, outgoing
id
string
The ID for a call
tag
array
Filter based on tag
响应载荷
results
array of object
显示子属性
results.id
string
必填
results.channelId
string
必填
results.from
string
必填
results.to
string
必填
results.originator
object
必填
显示子属性
results.originator.contact
object
显示子属性
results.originator.contact.id
string
必填
results.originator.contact.identifierKey
string
必填
results.originator.contact.identifierValue
string
必填
results.originator.number
object
必填
显示子属性
results.originator.number.type
string
必填
Possible values: pstn, sip, webrtc
results.originator.number.number
string
必填
results.originator.number.anonymous
boolean
results.originator.number.callerIdName
string
results.originator.number.identity
string
results.originator.number.countryIsoCode
string
results.originator.number.pstnNumberType
string
results.receiver
object
必填
显示子属性
results.receiver.contact
object
显示子属性
results.receiver.contact.id
string
必填
results.receiver.contact.identifierKey
string
必填
results.receiver.contact.identifierValue
string
必填
results.receiver.number
object
必填
显示子属性
results.receiver.number.type
string
必填
Possible values: pstn, sip, webrtc
results.receiver.number.number
string
必填
results.receiver.number.anonymous
boolean
results.receiver.number.callerIdName
string
results.receiver.number.identity
string
results.receiver.number.countryIsoCode
string
results.receiver.number.pstnNumberType
string
results.parentId
string
results.direction
string
必填
Possible values: incoming, outgoing
results.status
string
必填
Possible values: accepted, starting, ringing, ongoing, completed, busy, no-answer, failed, cancelled, scheduled
results.reason
string
results.type
string
必填
Possible values: pstn, sip, webrtc
results.duration
integer
results.hangupCauseCode
integer
results.hangupSource
string
Possible values: callee, caller, api, timeout, media-timeout, none
results.hangupSipCode
string
results.createdAt
string
必填
results.updatedAt
string
必填
results.ringingAt
string
results.answeredAt
string
results.endedAt
string
results.scheduledFor
string
results.callFlow
object
显示子属性
results.callFlow.id
string
results.callFlow.commands
array of object
显示子属性
results.callFlow.commands.id
string
results.callFlow.commands.callId
string
results.callFlow.commands.callFlowId
string
results.callFlow.commands.status
string
results.callFlow.commands.command
string
results.callFlow.commands.conditions
array of object
显示子属性
results.callFlow.commands.conditions.variable
string
Possible values: keys, speech
results.callFlow.commands.conditions.operator
string
Possible values: eq, ne, ==, !=, contains
results.callFlow.commands.conditions.value
string
results.notification
object
显示子属性
results.notification.url
string
results.qualityInsights
object
显示子属性
results.qualityInsights.mos
string
results.qualityInsights.pdd
string
results.sipInsights
object
显示子属性
results.sipInsights.hangupSipCode
string
results.sipInsights.edgeRegion
string
results.sipInsights.providerName
string
results.sipInsights.userAgent
string
results.sipInsights.remoteSignallingIp
string
results.sipInsights.remoteMediaIp
string
results.amdResult
object
显示子属性
results.amdResult.result
string
Possible values: human, machine, noSpeech, beep, unknown
results.amdResult.speech
string
results.amdResult.locale
string
results.sipType
string
Possible values: elastic, byoc, forward
results.tags
array of string
Tags to associate with the call. Tags are converted to lower case and tags that do not exist are automatically created. You can view your created tags in the UI. You can specify up to 10 tags per call.
nextPageToken
string
The token that can be passed as pageToken in URL to retrieve the next set of results. If missing, no more results to display.
代码示例
curl -X GET 'https://api.bird.com/workspaces/{workspaceId}/channels/{channelId}/calls' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'

Example 1: List calls from a workspace and a channel

You might consider filtering the call based on the channel and workspace using the available query parameters.
代码示例
curl "/workspaces/{workspaceId}/channels/{channelId}/calls" \
     -H 'Authorization: AccessKey YOUR_SECRET_TOKEN'

Example 2: List calls from a workspace and a channel filtered by startAt and endAt

代码示例
curl "GET /workspaces/{workspaceId}/channels/{channelId}/calls?startAt=2024-02-28T16%3A54%3A33.241Z&endAt=2024-03-01T16%3A54%3A33.241Z" \
    -H 'Authorization: AccessKey YOUR_SECRET_TOKEN'