import os
from gcore import Gcore
client = Gcore(
api_key=os.environ.get("GCORE_API_KEY"), # This is the default and can be omitted
)
client_profile = client.security.profiles.create(
fields=[{
"base_field": 1
}],
profile_template=1,
site="GNC",
)
print(client_profile.id)
Create protection profile. Protection is enabled at the same time as profile is created
POST
/
security
/
iaas
/
v2
/
profiles
Python
Copy
Ask AI
import os
from gcore import Gcore
client = Gcore(
api_key=os.environ.get("GCORE_API_KEY"), # This is the default and can be omitted
)
client_profile = client.security.profiles.create(
fields=[{
"base_field": 1
}],
profile_template=1,
site="GNC",
)
print(client_profile.id)