POST
/
cloud
/
v1
/
ddos
/
profiles
/
{project_id}
/
{region_id}
Create DDoS protection profile
curl --request POST \
  --url https://api.gcore.com/cloud/v1/ddos/profiles/{project_id}/{region_id} \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
  "bm_instance_id": null,
  "fields": [
    {
      "base_field": 10,
      "field_value": [
        45046,
        45047
      ]
    }
  ],
  "ip_address": "11.111.111.1",
  "profile_template": 123,
  "resource_id": null,
  "resource_type": "instance"
}'
{
  "tasks": [
    "d478ae29-dedc-4869-82f0-96104425f565"
  ]
}

Authorizations

Authorization
string
header
required

API key for authentication. Make sure to include the word apikey, followed by a single space and then your token. Example: apikey 1234$abcdef

Path Parameters

project_id
integer
required

Unique identifier of the cloud project that owns the DDoS protection resources

Examples:

1

region_id
integer
required

Unique identifier of the cloud region where DDoS protection operations will be performed

Examples:

1

Body

application/json
ip_address
required

IP address that will be protected by the DDoS protection profile

Examples:

"11.111.111.1"

profile_template
integer
required

Unique identifier of the DDoS protection template to use for this profile

Examples:

123

bm_instance_id
string | null
deprecated

Deprecated. Use resource_id field.

Examples:

null

"ff3bdce6-ad26-40d2-ae5a-854c53050969"

fields
CreateClientProfileFieldSerializer · object[]

List of field configurations that customize the protection parameters for this profile

Examples:
[
{
"base_field": 10,
"field_value": [45046, 45047]
}
]
resource_id
string | null

Unique identifier of the cloud resource (bare metal, load balancer, or instance) to be protected

Examples:

null

"ff3bdce6-ad26-40d2-ae5a-854c53050969"

resource_type
enum<string>
default:instance

Type of cloud resource that will be protected by the DDoS profile

Available options:
instance,
loadbalancer
Examples:

"instance"

Response

200 - application/json

OK

tasks
string[]
required

List of task IDs representing asynchronous operations. Use these IDs to monitor operation progress: * GET /v1/tasks/{task_id} - Check individual task status and details Poll task status until completion (FINISHED/ERROR) before proceeding with dependent operations.

Examples:
["d478ae29-dedc-4869-82f0-96104425f565"]