调用DescribeGateway接口查询指定ID的网关的基本信息。包括网关状态、类型等详情。

调用该接口时,您需要注意:

  • 请确保在使用该接口前,已充分了解混合云存储网关产品的收费方式和价格
  • 如果您需要购买网关,您可以通过该接口返回的购买链接或续费链接进行购买或续费。

调试

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

请求参数

名称 类型 是否必选 示例值 描述
Action String DescribeGateway

系统规定参数。取值:DescribeGateway

GatewayId String gw-000eg44nmxbsfwbvq***

网关ID。

返回数据

名称 类型 示例值 描述
Description String 测试使用

网关描述。

CreatedTime Long 1532099461

网关创建时间。时间戳为秒(s)。

PublicNetworkBandwidth Integer 50

数据公网带宽。如果网关为线上网关返回数据公网带宽。

DataLoadType String once

数据加载策略。可能值如下:

  • never:从不加载
  • once(默认):加载一次
  • periodical:按周期加载
Category String Aliyun

网关类别。默认值为Aliyun

TaskId String t-0000iwdggbharrw6r***

任务ID。

Message String successful

请求结果描述。

ExpireStatus Integer 0

网关是否过期状态。可能值:

  • 0:正常
  • 1:将要过期
  • 2:已经过期
Ip String 47.101.160.44

公网IP。

GatewayType String File

网关类型,可能值如下:

  • File:文件网关
  • Iscsi:块网关
StorageBundleId String sb-000dt67z4ijqfocpy***

网关集群ID。

GatewayClass String Basic

网关规格。当网关为线上网关时会返回网关规格。可能值如下:

  • Basic:基础型
  • Standard:标准型
  • Enhanced:增强型
  • Advanced:性能型
Success Boolean true

请求是否成功。可能值如下:

  • true:是
  • false:否
Name String alex***

网关名称。

IsPostPaid Boolean true

是否为后付费网关。可能值如下:

  • true:后付费网关,即按量付费网关。
  • false:预付费网关,即包年包月网关。
Capacity Integer 500

容量,单位为GB。

ExpiredTime Long 1532530021

网关过期时间。时间戳为秒(s)。

GatewayVersion String 1.0.39

网关版本。

IsReleaseAfterExpiration Boolean false

是否到期释放。可能值如下:

  • true:到期释放,直接收回。创建的云存储网关到期7天后,停止云存储网关服务。
  • false:创建的云存储网关到期后,转按量付费模式。
Status String Initialized

网关状态。可能值如下:

  • Initialized:已初始化
  • Deactivated:未激活
  • Activated:已激活
  • Deploying:部署中
  • Running:运行中
  • Stopping:停止中
  • Stopped:已停止
  • Starting:启动中
  • Rebooting:重启中
  • Deleting:删除中
  • Failed:失败
  • Upgrading:升级中
  • Modifying:修改中
  • Unknown:长时间没有心跳
BuyURL String https://expense.console.aliyun.com/?returnExpense=true#/order/list/

购买链接。

MaxThroughput Integer 30

最大吞吐量,单位为Gb/s。

DataLoadInterval Integer 120

数据加载周期,单位为秒(s)。

InnerIp String 172.19.55.65

挂载IP。

RequestId String 736C7733-FCED-4AFB-8407-C325F210CE03

请求ID。

VSwitchId String vsw-bp1b3mvml55ziekq7e***

虚拟交换机vSwitch ID。

ElasticNodes Array of String 172.16.0.23

弹性网关节点IP。

GatewayId String gw-0000ewknguw5o96vn***

网关ID。

Code String 200

状态码。状态码为200表示请求成功。

EcsInstanceId String i-uf62406gy5vyao4y8***

ECS实例ID。

Type String File

参见GatewayType参数。

RenewURL String https://common-buy.aliyun.com/?commodityCode=hcs_sgw_csg_pre&orderType=RENEW&instanceId=ca-0007va9bnideidndn***#/renew

续费链接。

VpcId String vpc-uf6j237kxmsw08auey***

专有网络VPC ID。

ActivatedTime Long 1578986214

网关激活时间。时间戳为秒(s)。

ElasticGateway Boolean false

是否为弹性网关。可能值如下:

  • false:不是
  • true:是
CommonBuyInstanceId String i-uf6gjr3lnwhyrd6hu***

包年包月网关在售卖系统中的实例ID。

InnerIpv6Ip String 2408:4004:110:6000:4656:f88e:1c14:e578

IPv6地址。

LastErrorKey String InternalError

错误关键字。

Location String Cloud

网关位置。可能值如下:

  • Cloud:线上网关
  • On_Premise:线下网关

示例

请求示例

http(s)://[Endpoint]/?Action=DescribeGateway
&GatewayId=gw-000eg44nmxbsfwbvq***
&<公共请求参数>

正常返回示例

XML格式

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeGatewayResponse>
    <Status>Initialized</Status>
    <BuyURL>https://expense.console.aliyun.com/?returnExpense=true#/order/list/</BuyURL>
    <Description>sadfasdf</Description>
    <CreatedTime>1578986214</CreatedTime>
    <Category>Aliyun</Category>
    <Message>successful</Message>
    <RequestId>736C7733-FCED-4AFB-8407-C325F210CE03</RequestId>
    <VSwitchId>vsw-bp1b3mvml55ziekq7e***</VSwitchId>
    <ExpireStatus>0</ExpireStatus>
    <StorageBundleId>sb-000dt67z4ijqfocpy***</StorageBundleId>
    <GatewayId>gw-0000ewknguw5o96vn***</GatewayId>
    <Code>200</Code>
    <GatewayClass>Standard</GatewayClass>
    <Success>true</Success>
    <Name>sdfafsa</Name>
    <IsPostPaid>false</IsPostPaid>
    <Type>File</Type>
    <IsReleaseAfterExpiration>true</IsReleaseAfterExpiration>
    <Location>Cloud</Location>
</DescribeGatewayResponse>

JSON格式

HTTP/1.1 200 OK
Content-Type:application/json

{
  "Status" : "Initialized",
  "BuyURL" : "https://expense.console.aliyun.com/?returnExpense=true#/order/list/",
  "Description" : "sadfasdf",
  "CreatedTime" : 1578986214,
  "Category" : "Aliyun",
  "Message" : "successful",
  "RequestId" : "736C7733-FCED-4AFB-8407-C325F210CE03",
  "VSwitchId" : "vsw-bp1b3mvml55ziekq7e***",
  "ExpireStatus" : 0,
  "StorageBundleId" : "sb-000dt67z4ijqfocpy***",
  "GatewayId" : "gw-0000ewknguw5o96vn***",
  "Code" : "200",
  "GatewayClass" : "Standard",
  "Success" : true,
  "Name" : "sdfafsa",
  "IsPostPaid" : false,
  "Type" : "File",
  "IsReleaseAfterExpiration" : true,
  "Location" : "Cloud"
}

错误码

HttpCode 错误码 错误信息 描述
400 EmptyGatewayId You must enter a valid ID for the gateway. 网关ID不能为空。
400 GatewayNotExist The specified gateway does not exist. You must specify a valid parameter. 网关不存在,请确认输入参数是否正确。

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