Bulk create allowed IP address ranges
curl --request POST \
--url https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"allowedIpAddressRanges": [
"<string>"
]
}
'import requests
url = "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges"
payload = { "allowedIpAddressRanges": ["<string>"] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({allowedIpAddressRanges: ['<string>']})
};
fetch('https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'allowedIpAddressRanges' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges"
payload := strings.NewReader("{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"allowedIpAddressRanges": [
{
"createdAt": "2022-11-22T04:37:12Z",
"id": "<string>",
"ipAddressRange": "<string>",
"organizationId": "<string>",
"updatedAt": "2022-11-22T04:37:12Z",
"createdBy": {
"id": "clm8qv74h000008mlf08scq7k",
"apiTokenName": "my-token",
"avatarUrl": "https://avatar.url",
"fullName": "Jane Doe",
"subjectType": "USER",
"username": "user1@company.com"
},
"updatedBy": {
"id": "clm8qv74h000008mlf08scq7k",
"apiTokenName": "my-token",
"avatarUrl": "https://avatar.url",
"fullName": "Jane Doe",
"subjectType": "USER",
"username": "user1@company.com"
}
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}Allowed IP Address Range
Bulk create allowed IP address ranges
Create up to 1000 allowed IP address ranges for the organization in one request. The whole batch is created atomically — if any item fails validation or conflicts with an existing range, no rows are inserted. This endpoint is NOT idempotent: a retry after an unacknowledged 2xx response may return 409. Clients should list the ranges to verify state before retrying.
POST
/
organizations
/
{organizationId}
/
allowed-ip-address-ranges
Bulk create allowed IP address ranges
curl --request POST \
--url https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"allowedIpAddressRanges": [
"<string>"
]
}
'import requests
url = "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges"
payload = { "allowedIpAddressRanges": ["<string>"] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({allowedIpAddressRanges: ['<string>']})
};
fetch('https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'allowedIpAddressRanges' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges"
payload := strings.NewReader("{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.astronomer.io/labs/v1/organizations/{organizationId}/allowed-ip-address-ranges")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"allowedIpAddressRanges\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"allowedIpAddressRanges": [
{
"createdAt": "2022-11-22T04:37:12Z",
"id": "<string>",
"ipAddressRange": "<string>",
"organizationId": "<string>",
"updatedAt": "2022-11-22T04:37:12Z",
"createdBy": {
"id": "clm8qv74h000008mlf08scq7k",
"apiTokenName": "my-token",
"avatarUrl": "https://avatar.url",
"fullName": "Jane Doe",
"subjectType": "USER",
"username": "user1@company.com"
},
"updatedBy": {
"id": "clm8qv74h000008mlf08scq7k",
"apiTokenName": "my-token",
"avatarUrl": "https://avatar.url",
"fullName": "Jane Doe",
"subjectType": "USER",
"username": "user1@company.com"
}
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The ID of the Organization the ranges will belong to.
Body
application/json
The request body containing the list of CIDR ranges to create.
The CIDR ranges to create. At most 1000 per request.
Required array length:
1 - 1000 elementsResponse
OK
The ranges that were created.
Show child attributes
Show child attributes
Was this page helpful?
⌘I