Create firewall rules

Enabled per organisation

This endpoint answers 403 until our staff enable the Firewall API flag on your organisation, and its ability cannot be granted to a key before then. Open a ticket saying what you intend to build — see Activation.
POST
/firewall/ips/{ip}/rules

Creates one rule per port in the expression. A multi-port request is not atomic — the appliance takes one rule at a time — so the response reports created alongside requested. Compare the two before assuming the whole expression landed.

Authorization

orgApiKey firewall.manage
AuthorizationBearer <token>

An organisation API key, prefixed tbk_. Create one under Organisation to API keys; the plaintext is shown once.

The scopes listed on each operation are the abilities the key must carry. They are not OAuth scopes and are not negotiated per request.

In: header

Scope: firewall.manage

Path Parameters

ip*string

An address inside a prefix you announce, or one assigned to one of your services. Anything else is a 404.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/firewall/ips/192.0.2.10/rules" \  -H "Content-Type: application/json" \  -d '{    "action": "allow",    "protocol": "tcp",    "destination_port": "25565"  }'
{  "data": {    "ids": [      0    ],    "created": 0,    "requested": 0  },  "message": "Accepted. Changes take 3-5 minutes to propagate globally."}