You can call this operation to query the information of the WAF instance in a specified region.

Note You do not need to specify the InstanceId common request parameters.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action Boolean No DescribePayInfo

The operation that you want to perform. Valid values: DescribePayInfo.

InstanceSource String Yes waf-cloud

The source of the instance. Default value: waf-cloud.

Region String Yes cn

The ID of the region. Valid values:

  • cn: mainland China (default)
  • cn-hongkong: outside mainland China

Response parameters

Parameter Type Example Description
RequestId String Cost

The ID of the request.

Result

The returned result.

EndDate Long 1512921600

The time when an instance expires.

Note For a pay-as-you-go instance, the trial period ends.
InDebt Integer 1

Whether the current instance is overdue:

  • 0: The instance has overdue payments.
  • 1: indicates normal.
Note This parameter takes effect for pay-as-you-go WAF instances.
InstanceId String waf_elasticity-cn-0xldbqtm005

The ID of the instance whose type or storage space is modified.

PayType Integer env

The type of the WAF instance:

  • 0: indicates that the ECS instance is not purchased or activated.
  • 1: A subscription instance.
  • 2: A pay-as-you-go instance.
Region String cn

Region:

  • CN: indicates mainland China.
  • cn-hongkong: indicates the overseas region.
RemainDay Integer 0

The number of days before the trial period of the WAF instance expires.

Note This parameter is only valid for pay-as-you-go WAF instances.
Status Integer 0

The status of the WAF instance. Valid values:

  • 0: indicates that the API has expired.
  • 1: indicates normal.
Note This parameter is only valid for WAF subscription instances.
Trial Integer 0

Indicates whether this is a trial instance. Valid value:

  • 0: false
  • 1: true
Note This parameter is only valid for pay-as-you-go WAF instances.

Samples

Sample request


https://wafopenapi.cn-hangzhou.aliyuncs.com/? Action=DescribePayInfo
&Region=cn
&Common request parameters

Sample success responses

XML format

<DescribePayInfoResponse>
      <RequestId>56B40D30-4960-4F19-B7D5-2B1F0EE6CB70</RequestId>
      <Result>
            <Status>1</Status>
            <Trial>0</Trial>
            <InstanceId>waf_elasticity-cn-0xldbqtm005</InstanceId>
            <InDebt>1</InDebt>
            <Region>cn</Region>
            <RemainDay>0</RemainDay>
            <PayType>2</PayType>
            <EndDate>1512921600</EndDate>
      </Result>
</DescribePayInfoResponse>

JSON format

{
	"Result":{
		"Status":1,
		"EndDate":1512921600,
		"Region":"cn",
		"InDebt":1,
		"Trial":0,
		"InstanceId":"waf_elasticity-cn-0xldbqtm005",
		"RemainDay":0,
		"PayType":2
	},
	"RequestId":"276D7566-31C9-4192-9DD1-51B10DAC29D2"
}

Error codes.

For a list of error codes, visit the API Error Center.