---
title: "Create IP filter"
method: POST
path: "/api/ip-filters"
tags: ["IP Filters"]
---

# Create IP filter

`POST /api/ip-filters`

Creates a new IP filter with the provided configuration

## Request body

- IPFilterCommandDTO — Command DTO for creating or updating an IP filter. Used as the request body for IP filter creation/update endpoints.
  - `address` string, required — A regex pattern matched against the remote client's IP address. A plain IP address (e.g. `192.168.1.1`) is treated as a literal pattern. Use `*` to allow all addresses, or a regex prefix like `192\.168\.` to allow an entire subnet. Both IPv4 and IPv6 addresses (including IPv4-mapped IPv6) are supported.
  - `description` string, required — A description of the purpose or reason for this IP filter.

## Response `201`

IP filter created successfully

- IPFilterDTO — Data Transfer Object for an IP filter. Represents a configured IP filter with its address and description.
  - `id` string, required — The unique identifier of the entity.
  - `createdBy` UserInfo, required — Represents the user who performed an action, with a computed display name.
    - `id` string, required — The unique identifier of the user.
    - `friendlyName` string, required — A human-readable display name for the user. "OIAnalytics" for the oianalytics system user, "Admin" for the admin login, or "Firstname Lastname (login)" for regular users.
  - `updatedBy` UserInfo, required — Represents the user who performed an action, with a computed display name.
    - `id` string, required — The unique identifier of the user.
    - `friendlyName` string, required — A human-readable display name for the user. "OIAnalytics" for the oianalytics system user, "Admin" for the admin login, or "Firstname Lastname (login)" for regular users.
  - `createdAt` string, required — Represents an instant in time as an ISO 8601 string.
  - `updatedAt` string, required — Represents an instant in time as an ISO 8601 string.
  - `address` string, required — A regex pattern matched against the remote client's IP address. A plain IP address (e.g. `192.168.1.1`) is treated as a literal pattern. Use `*` to allow all addresses, or a regex prefix like `192\.168\.` to allow an entire subnet. Both IPv4 and IPv6 addresses (including IPv4-mapped IPv6) are supported.
  - `description` string, required — A description of the purpose or reason for this IP filter.

## Changes

- **2026-03-25** `cdb5b7ea7199` — 2 warning, 4 info
  - removed the optional property `creationDate` from the response with the `201` status
  - removed the optional property `lastEditInstant` from the response with the `201` status
  - added the required property `createdAt` to the response with the `201` status
  - added the required property `createdBy` to the response with the `201` status
  - …2 more
- **2026-03-20** `108013c94629` — 4 breaking, 2 info
  - removed the required property `createdAt` from the response with the `201` status
  - removed the required property `createdBy` from the response with the `201` status
  - removed the required property `updatedAt` from the response with the `201` status
  - removed the required property `updatedBy` from the response with the `201` status
  - …2 more
- **2026-03-19** `fb56929c0675` — 2 warning, 4 info
  - removed the optional property `creationDate` from the response with the `201` status
  - removed the optional property `lastEditInstant` from the response with the `201` status
  - added the required property `createdAt` to the response with the `201` status
  - added the required property `createdBy` to the response with the `201` status
  - …2 more
- …earlier changes not shown

[Full history](https://skmtc.dev/optimistiksas/apis/oibus-api/changes/api/ip-filters/post.md)

---

[API](https://skmtc.dev/optimistiksas/apis/oibus-api.md) · [All operations](https://skmtc.dev/optimistiksas/apis/oibus-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/optimistiksas/oibus-api/revisions/fe8fd32c9fdc/schema)
