---
title: "Create firewall"
method: POST
path: "/firewalls"
tags: ["Firewalls"]
---

# Create firewall

`POST /firewalls`

Create a firewall

## Request body

- object
  - `data` object, required
    - `type` 'firewalls', required
    - `attributes` object
      - `name` string, required
      - `project` string, required
      - `rules` object[]
        - `from` string — Source IP address, IP range in CIDR notation, or 'ANY' (e.g., "192.168.1.1", "192.168.1.0/24", "ANY")
        - `to` string — Destination IP address, IP range in CIDR notation, or 'ANY' (e.g., "192.168.1.1", "192.168.1.0/24", "ANY")
        - `protocol` 'TCP' | 'UDP'
        - `port` string — Port number or range (e.g., "80", "80-443")
        - `description` string, nullable — Optional description explaining the purpose of this rule

## Response `201`

Created

---

[API](https://skmtc.net/latitude/apis/latitude-sh-api.md) · [All operations](https://skmtc.net/latitude/apis/latitude-sh-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/latitude/latitude-sh-api/versions/7302d79e39bb/schema)
