You need to enable JavaScript to run this app.
导航

DescribeCloudConnectorAPNs

最近更新时间2024.01.09 07:43:30

首次发布时间2024.01.09 07:43:30

调用DescribeCloudConnectorAPNs查询APN信息。

调用说明

DescribeCloudConnectorAPNs支持分页查询,初次调用接口进行分页查询时,仅需传入MaxResults以限制单页返回结果的条目,无需传入NextToken,查询结果会返回NextToken的值作为后续页查询的凭证。后续查询时请求参数NextToken传入上一次的NextToken的返回值,并设置MaxResults限制单页返回结果的条目即可。

请求参数

名称类型是否必选示例值描述
ActionStringDescribeCloudConnectorAPNs要执行的操作,取值:DescribeCloudConnectorAPNs。
VersionString2020-04-01API版本信息。

APNIds.N

String

APNIds.1=apn-1sdsf334j51288****&APNIds.2=apn-def9cdjn0s****

运营商APN的ID。

  • 参数 - N:表示APN的ID的序号,数量上限为100个。

  • 如不填,则默认查询当前账号下全部符合条件的APN信息。

  • 多个ID间使用“&”分隔。

APNStringxxx.mnc.mcc.gprs运营商APN信息。

ISP

String

ChinaTelecom

运营商类型。

  • ChinaTelecom:中国电信。

  • ChinaMobile:中国移动。

  • ChinaUnicom:中国联通。

MaxResults

String

50

单次查询的数量,默认为 10,最大为100。

NextToken

String

caeba0bbb2be03f84eb48b699f0a****

分页查询凭证,用于标记分页的位置。
初次调用接口时无需设置,后续查询此参数取值为上一次API调用返回的NextToken的值。

返回数据

名称类型示例值描述
RequestIdString20220627103212010225145152058****请求ID。

NextToken

String

ca3fob2be03f84eb41b633f0d****

本次调用返回的查询凭证值,返回为空表示没有下一页。

APNsArray of struct-APN的详细信息。具体参见下方“APN”。

APN

名称类型示例值描述
APNIdStringapn-1sdsf334j51288***APN的ID。
APNStringxxx.mnc.mcc.gprsAPN的信息。
NameStringtest-nameAPN的名称。

ISP

String

ChinaUnicom

APN运营商的类型。

  • ChinaTelecom:中国电信。

  • ChinaMobile:中国移动。

  • ChinaUnicom:中国联通。

Status

String

Available

APN的状态。

  • Creating:创建中

  • Deleting:删除中

  • Pending:操作中

  • Available:可用

  • Deleted:已删除

IotCidrsList of String["172.16.XX.XX/16","172.16.XX.XX/16"]IOT终端网段地址列表。

Zones

List of String

["cn-beijing-a,cn-beijing-b"]

APN对应虚拟机所在可用区的列表。

CreationTimeString2021-07-12T07:28:20+08:00创建APN的时间。

UpdateTime

String

2021-07-12T07:28:20+08:00

更新APN的时间。

请求示例

GET /?Action=DescribeCloudConnectorAPNs&Version=2020-04-01&APNIds.1=apn-imd3sh2d7u2o8gbssy**** HTTP/1.1
Host: open.volcengineapi.com
ServiceName: directconnect
Region: cn-beijing

返回示例

{
    "ResponseMetadata": {
        "RequestId": "20240103145037B265ED6CC655D2****",
        "Action": "DescribeCloudConnectorAPNs",
        "Version": "2020-04-01",
        "Service": "directconnect",
        "Region": "cn-beijing"
    },
    "Result": {
        "RequestId": "20240103145037B265ED6CC655D2****",
        "NextToken": "",
        "APNs": [
            {
                "APNId": "apn-imd3sh2d7u2o8gbssy***",
                "APN": "20231****.****",
                "Name": "test",
                "ISP": "ChinaUnicom",
                "Status": "Available",
                "IotCidrs": [
                    "172.XX.XX.0/16"
                ],
                "Zones": [
                    "cn-beijing-a",
                    "cn-beijing-b"
                ],
                "CreationTime": "2021-07-12T07:28:20+08:00",
                "UpdateTime": "2021-07-12T07:28:20+08:00"
            }
        ]
    }
}

错误码

此处仅展示当前API的错误码,更多错误码请参见公共错误码

HttpCode错误码错误信息描述
400DryRunOperationException raised to indicate a successfully authorized action when the DryRun flag is set to true.该请求设置为DryRun操作,操作授权已获得许可,但未被实际执行。

400

InvalidISP.Malformed

The specified parameter ISP is malformed. Only ChinaTelecom, ChinaMobile and ChinaUnicom are supported.

运营商参数不合法,仅支持中国电信、中国移动和中国联通。

400InvalidMaxResults.MalformedThe specified parameter MaxResults is malformed.查询数量不合法。
400InvalidNextToken.MalformedThe specified parameter NextToken is invalid.查询 NextToken 不合法。
400InvalidPage.MalformedThe specified page is malformed.指定的分页参数不合法。
400LimitExceeded.APNIdYou've reached the limit on the number of APN IDs that you can describe.已达到可查询的APN ID数量上限。