Updated on 2024-04-22 GMT+08:00

Creating an Edge Resource Pool

Function

This API is used to create an edge resource pool.

URI

POST /v2/{project_id}/edge-pools

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID. For details, see Obtaining a Project ID and Name.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. For details about how to obtain a user token, see Authentication.

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

name

Yes

String

Name of an edge resource pool. The value is a string of 4 to 32 characters consisting of lowercase letters, digits, and hyphens (-). It must start with a lowercase letter and ends with a lowercase letter or digit.

description

No

String

Task description

Minimum: 0

Maximum: 255

ief_service_instance_id

No

String

ID of a platinum IEF instance

Minimum: 0

Maximum: 255

nodes

Yes

Array of strings

IEF edge nodes

Array Length: 1 - 10

Response Parameters

Status code: 201

Table 4 Response body parameters

Parameter

Type

Description

id

String

ID of a created edge pool

Status code: 400

Table 5 Response body parameters

Parameter

Type

Description

error_code

String

Error code

error_msg

String

Error description

detail

String

Error details

params

Array of strings

Error parameters

Array Length: 0 - 1

reason

String

Error cause

advice

String

Suggestion

Status code: 500

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code

error_msg

String

Error description

detail

String

Error details

params

Array of strings

Error parameters

Array Length: 0 - 1

reason

String

Error cause

advice

String

Suggestion

Example Requests

This request is used to create an edge resource pool named xxx with the node xxx selected.

POST https://{endpoint}/v2/{project_id}/edge-pools

{
  "name":"xxx",
  "description":"xxx",
  "iefServiceInstanceId":"xxx",
  "nodes":[
    {
      "xxx"
    }
  ]
}

Example Responses

Status code: 201

Response body for creating an edge resource pool

{
  "id" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
}

Status Codes

Status Code

Description

201

Response body for creating an edge resource pool

400

Request error

500

Internal error

Error Codes

See Error Codes.