Create IP Group
Endpoint
POST /apiops/projects/{projectName}/ipGroups/
Authentication
Requires a Personal API Access Token.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
| Content-Type | application/json | Yes |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
Request Body
Full JSON Body Example - Basic IP Group
{
"name": "AllowedIPs",
"description": "Allowed IP addresses for API access"
}
Full JSON Body Example - IP Group without Description
{
"name": "BlockedIPs"
}
Request Body Fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| name | string | Yes | - | IP Group name (unique identifier within project) |
| description | string | No | - | IP Group description |
| ipList | array[string] | No | [] | Optional initial IP addresses or CIDR ranges. Omit or leave empty to create an empty group |
Notes
namemust be unique within the projectnamemust not be empty- When
ipListis omitted or empty, the group is created with no IPs - Use Add IPs to Group to add addresses after creation
Response
Success Response (200 OK)
{
"status": "SUCCESS",
"deploymentResult": {
"success": true,
"responseTime": 1500,
"detailList": [
{
"envName": "production",
"success": true,
"detail": "Deployed successfully",
"responseTime": 450
}
]
}
}
Error Response (400 Bad Request)
{
"status": "FAILURE",
"resultMessage": "name value can not be empty!"
}
or
{
"status": "FAILURE",
"resultMessage": "An IP Group with same name (AllowedIPs) already exists in project!"
}
Common Causes
- Missing or empty
namefield - IP Group name already exists in project
cURL Example
curl -X POST \
"https://demo.apinizer.com/apiops/projects/MyProject/ipGroups/" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "AllowedIPs",
"description": "Allowed IP addresses for API access"
}'
Notes and Warnings
-
Name Uniqueness:
- IP Group name must be unique within the project
- If name already exists, creation will fail
-
Optional ipList on create:
- You can provide
ipListin the create body to seed the group - When omitted, the group starts empty (pilot collection uses this pattern)
- You can provide
-
Empty Group:
- Use Add IPs to Group to add addresses after creation
-
Automatic Deployment:
- The group is deployed to Gateway environments after create
Permissions
- User must have
GLOBAL_SETTINGS+MANAGEpermission in the project
Related Documentation
- Update IP Group - Update an IP Group
- Add IPs to Group - Add IP addresses to group