Help Center/ Edge Security/ API Reference/ API/ Tenant Subscription Management/ Querying Purchased EdgeSec Products
Updated on 2023-11-24 GMT+08:00

Querying Purchased EdgeSec Products

Function

This API is used to query purchased EdgeSec products.

URI

GET /v1/edgesec/subscription

Table 1 Query Parameters

Parameter

Mandatory

Type

Description

enterprise_project_id

No

String

Obtain the enterprise project ID by calling the ListEnterpriseProject API of Enterprise Project Management Service (EPS).

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

No

String

User token. It can be obtained by calling the IAM API (value of X-Subject-Token in the response header).

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

waf_domain_num

Integer

Number of WAF domain names that have been added

waf_rule_num

Integer

Number of added WAF IP address blacklist and whitelist rules

ddos_domain_num

Integer

Number of added anti-DDoS domain names

product_infos

Array of EdgeSecProductResource objects

Product details

Table 4 EdgeSecProductResource

Parameter

Type

Description

order_id

String

ID of the order for purchasing the resource.

cloud_service_type

String

Cloud service type. The value for EdgeSec is hws.service.type.edgesec.

product_id

String

Product ID

resource_id

String

Resource ID

enterprise_project_id

String

Enterprise project ID

region_id

String

region ID

resource_type

String

Resource type

resource_spec_code

String

The resource specification code.

resource_size

Integer

Number of extension package resources.

bill_type

Integer

Billing method (0: not billed by traffic; 1: billed by peak bandwidth; 2: billed by traffic)

Enumeration values:

  • 0

  • 1

  • 2

charging_mode

String

Billing mode. The value can be 1 (one-off, yearly/monthly) or 2 (pay-per-use).

Enumeration values:

  • 1

  • 2

Status code: 400

Table 5 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 500

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Requests

Query purchased EdgeSec products.

GET https://{Endpoint}/v1/edgesec/products

{
  "enterprise_project_id" : 0
}

Example Responses

Status code: 200

Request succeeded.

{
  "waf_domain_num" : 4,
  "waf_rule_num" : 0,
  "ddos_domain_num" : 30,
  "ddos_rule_num" : 0,
  "product_infos" : [ {
    "order_id" : "CS23051715154AMJZ",
    "cloud_service_type" : "hws.service.type.edgesec",
    "product_id" : "OFFI847313454219157506",
    "resource_id" : "148bdfa5-6b79-47d3-86ea-eed43f887248",
    "enterprise_project_id" : 0,
    "region_id" : "ap-south-east-1",
    "resource_type" : "hws.resource.type.edgeddos",
    "resource_spec_code" : "edgesec.ddos.basic.abroad",
    "resource_size" : 0,
    "bill_type" : 0,
    "charging_mode" : "prePaid"
  }, {
    "order_id" : "CS23051715154AMJZ",
    "cloud_service_type" : "hws.service.type.edgesec",
    "product_id" : "OFFI847291260949225474",
    "resource_id" : "7ee6a5c8-2fe4-45e5-8ac7-1192248a5969",
    "enterprise_project_id" : 0,
    "region_id" : "ap-south-east-1",
    "resource_type" : "hws.resource.type.edgewaf",
    "resource_spec_code" : "edgewaf.professional.abroad",
    "resource_size" : "0,",
    "bill_type" : "0,",
    "charging_mode" : "prePaid"
  } ]
}

Status Codes

Status Code

Description

200

Request succeeded.

400

Invalid request parameter.

401

The account corresponding to the token does not have sufficient permission.

500

Internal server error.

Error Codes

See Error Codes.