ListPhoneNumbers - 获取号码列表

更新时间:
复制为 MD 格式

调用ListPhoneNumbers获取指定实例下的号码列表。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

当前API暂无授权信息透出。

请求参数

名称

类型

必填

描述

示例值

InstanceId

string

实例 ID。

ccc-test

SearchPattern

string

根据号码进行模糊匹配,非必填,默认为空,为空表示不过滤。

0833

Usage

string

号码的用途,非必填,默认为空,为空表示不过滤。

枚举值:

  • Outbound :

    呼出

  • Inbound :

    呼入

  • Bidirection :

    呼入和呼出

Bidirection

Active

boolean

号码是否可用,非必填,默认为空,为空表示不过滤。

true

PageNumber

integer

分页序号,范围 1-100。

1

PageSize

integer

分页大小,范围 1-100。

20

返回参数

名称

类型

描述

示例值

object

HttpStatusCode

integer

HTTP 状态码。

200

RequestId

string

请求 ID。

BA03159C-E808-4FF1-B27E-A61B6E888D7F

Code

string

响应码。

OK

Message

string

响应信息。

Data

object

数据。

PageNumber

integer

分页序号,范围 1-100

1

PageSize

integer

分页序号,范围 1-100

20

TotalCount

integer

总数。

1

List

array<object>

号码列表。

array<object>

Active

boolean

号码是否可用。

true

CreateTime

string

号码创建时间,即关联到实例的时间,格式为 Unix 时间戳,单位毫秒。

1617958538000

UserId

string

坐席 ID,如果此参数不为空,说明该号码是座席专属号码。

agent@ccc-test

Tags

string

号码业务标签,主要用于给号码打标,做一些扩展业务,普通客户无需关心。

M1

City

string

号码归属地市。

乐山

InstanceId

string

实例 ID。

ccc-test

Usage

string

号码用途。

枚举值:

  • Outbound :

    呼出

  • Inbound :

    呼入

  • Bidirection :

    呼入和呼出

Bidirection

ContactFlowName

string

号码关联的 IVR 联系流名称。

默认联系流

Provider

string

号码供应商名称。

alicom

Number

string

号码。

08330011****

ContactFlowId

string

号码关联的 IVR 联系流 ID。

a3fb6c62-9b49-4942-ae5b-cf2abd4123ek

Province

string

号码归属地省。

四川

SkillGroups

array<object>

号码关联的技能组列表。

object

DisplayName

string

技能组展示名。

测试技能组

InstanceId

string

实例 ID。

ccc-test

Name

string

技能组名称。

skillgroup

SkillGroupId

string

技能组 ID。

skillgroup@ccc-test

示例

正常返回示例

JSON格式

{
  "HttpStatusCode": 200,
  "RequestId": "BA03159C-E808-4FF1-B27E-A61B6E888D7F",
  "Code": "OK",
  "Message": "无",
  "Data": {
    "PageNumber": 1,
    "PageSize": 20,
    "TotalCount": 1,
    "List": [
      {
        "Active": true,
        "CreateTime": "1617958538000",
        "UserId": "agent@ccc-test",
        "Tags": "M1",
        "City": "乐山",
        "InstanceId": "ccc-test",
        "Usage": "Bidirection",
        "ContactFlowName": "默认联系流",
        "Provider": "alicom",
        "Number": "08330011****",
        "ContactFlowId": "a3fb6c62-9b49-4942-ae5b-cf2abd4123ek",
        "Province": "四川",
        "SkillGroups": [
          {
            "DisplayName": "测试技能组",
            "InstanceId": "ccc-test",
            "Name": "skillgroup",
            "SkillGroupId": "skillgroup@ccc-test"
          }
        ]
      }
    ]
  }
}

错误码

HTTP status code

错误码

错误信息

描述

400 Parameter.Enumeration The parameter %s must be one of the value of enumeration %s. 该参数必须为系统限定的枚举值之一。
400 Parameter.Maximum The parameter %s must be less than or equal to %s. 参数必须小于或等于系统规定的最大值。
400 Parameter.Minimum The parameter %s must be greater than or equal to %s. 参数必须大于或等于系统规定的最小值。
400 Parameter.Empty The parameter %s may not be null or empty. 该参数不能为null值或为空字符串。
400 Parameter.Null The parameter %s may not be null. 该参数不能为null值.
404 NotExists.InstanceId The specified instance %s does not exist. 指定的呼叫中心实例不存在。

访问错误中心查看更多错误码。

变更历史

更多信息,参考变更详情