Update a NAT Gateway Rule
Endpoint
Request
Full update (PUT)
curl --location \
--request PUT 'https://api.ionos.com/cloudapi/v6/datacenters/15f67991-0f51-4efc-a8ad-ef1fb31a480c/natgateways/8b3a6e2d-c9f1-4d3e-a7b2-1e4f8c9d3a2b/rules/5d4c3b2a-1e9f-8d7c-6b5a-4f3e2d1c0b9a' \
--header 'Authorization: Bearer $IONOS_TOKEN' \
--header 'Content-Type: application/json' \
--data-raw '{
"properties": {
"name": "Updated NAT Rule",
"type": "SNAT",
"protocol": "TCP",
"sourceSubnet": "10.0.1.0/24",
"publicIp": "203.0.113.15",
"targetSubnet": "10.0.2.0/24",
"targetPortRange": {
"start": 8080,
"end": 8090
}
}
}'Partial update (PATCH)
Response
Last updated
Was this helpful?