Blocklist

Get All Blocklists

get

Fetch all blocklists and their blocked hosts

Responses
200Success
application/json
get
/servers/blocklist
GET /v1/servers/blocklist HTTP/1.1
Host: 
Accept: */*
[
  {
    "blocklist_id": "text",
    "name": "text",
    "blocked_hosts": [
      "text"
    ]
  }
]

Create Blocklist

post

Create a blocklist with an array of blocked hostnames

Body
namestringRequired
hostnamesstring[]Required
Responses
200Success
application/json
post
/servers/blocklist
POST /v1/servers/blocklist HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 36

{
  "name": "text",
  "hostnames": [
    "text"
  ]
}
{
  "blocklist_id": "text",
  "name": "text",
  "blocked_hosts": [
    "text"
  ]
}

Get Blocklist by ID

get

Fetch a blocklist and its blocked hosts by blocklist ID

Path parameters
idstring · uuidRequired
Responses
200Success
application/json
get
/servers/blocklist/{id}
GET /v1/servers/blocklist/{id} HTTP/1.1
Host: 
Accept: */*
{
  "blocklist_id": "text",
  "name": "text",
  "blocked_hosts": [
    "text"
  ]
}

Remove blocklist

delete

Delete a blocklist and the associated blocked hosts. Can only be deleted if no subnet has a relation to a given list.

Path parameters
idstring · uuidRequired
Responses
delete
/servers/blocklist/{id}
DELETE /v1/servers/blocklist/{id} HTTP/1.1
Host: 
Accept: */*
default
{
  "timestamp": "text",
  "message": "text",
  "domain_error_code": 1
}