---
updatedAt: 2026-09-01T14:05:24.000Z
agentTools:
  siteIndex: https://developer.jamf.com/llms.txt
  projectIndex: https://developer.jamf.com/platform-api/llms.txt
---

# Partially update a Gateway

Partially update a dedicated Gateway. All fields are optional — flat body, no nesting.

Returns `404` if the gateway does not exist **or belongs to a different tenant** — never `403`,
to avoid confirming the existence of gateways owned by other tenants.

`tenantIds` are validated against the caller's organization — **403** on mismatch.
When `datacenter` changes, `availabilityZones` must be valid IPs for the new datacenter
(see the table on `GatewayPatchRequest.availabilityZones`) — returns `400` on mismatch.
Sending `ipsec.left.secret: null` explicitly returns `400 IPSEC_SECRET_CLEAR_NOT_SUPPORTED`
— omit the field to leave the existing secret unchanged.
Sending `ipsec: null` explicitly returns `400 IPSEC_REMOVAL_NOT_SUPPORTED`
— IPSec configuration cannot be removed from a gateway that has it.
Once a gateway has `availabilityZones`, the list can be replaced but not emptied — sending `[]`
or `null` returns `400 EMPTY_AVAILABILITY_ZONES_NOT_SUPPORTED`.

**Partial IPSec update:** When `ipsec` is present in the patch, sub-fields are
deep-merged — you may supply only `left.secret` to rotate the PSK without replacing
the rest of the configuration, or supply the full `ipsec` block to replace cipher
suites and endpoint addresses simultaneously.

**`contact: null` is rejected.** Setting `contact` to `null` in a merge-patch returns
`409` — the contact field cannot be removed from a dedicated gateway.

**`tenantIds: []` is rejected.** Setting `tenantIds` to an empty array returns `400`
— a dedicated gateway must always have at least one tenant (`minItems: 1` enforced by schema).

**Known limitation:** Concurrent modifications to the same gateway may overwrite each
other — no optimistic locking is in place for this release.

**Datacenter change is destructive:** Expect a connectivity outage while the gateway is
re-provisioned. `status.state` resets to `PENDING` immediately; `status.tunnelState` resets
to `null`; status records for the old datacenter are expired. `dedicatedIps.ips` are not
cleared immediately — treat them as unreliable until VSC completes provisioning in the new datacenter.


**Required Permissions:** `ztna:update`

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "Jamf ZTNA Public API",
    "version": "1.0.0",
    "description": "Manage ZTNA Gateways, Grouped Gateways, Apps, and Predefined Apps",
    "termsOfService": "https://www.jamf.com/developer-resources/api-license-agreement/",
    "contact": {
      "name": "Jamf Developer",
      "url": "https://developer.jamf.com"
    }
  },
  "tags": [
    {
      "name": "gateways",
      "description": "Dedicated ZTNA Gateways — customer-owned gateways managed exclusively by the tenant. Full CRUD available.\n"
    }
  ],
  "paths": {
    "/v1/ztna/gateways/{gatewayId}": {
      "parameters": [
        {
          "$ref": "#/components/parameters/gatewayId"
        }
      ],
      "patch": {
        "tags": [
          "gateways"
        ],
        "summary": "Partially update a Gateway",
        "description": "Partially update a dedicated Gateway. All fields are optional — flat body, no nesting.\n\nReturns `404` if the gateway does not exist **or belongs to a different tenant** — never `403`,\nto avoid confirming the existence of gateways owned by other tenants.\n\n`tenantIds` are validated against the caller's organization — **403** on mismatch.\nWhen `datacenter` changes, `availabilityZones` must be valid IPs for the new datacenter\n(see the table on `GatewayPatchRequest.availabilityZones`) — returns `400` on mismatch.\nSending `ipsec.left.secret: null` explicitly returns `400 IPSEC_SECRET_CLEAR_NOT_SUPPORTED`\n— omit the field to leave the existing secret unchanged.\nSending `ipsec: null` explicitly returns `400 IPSEC_REMOVAL_NOT_SUPPORTED`\n— IPSec configuration cannot be removed from a gateway that has it.\nOnce a gateway has `availabilityZones`, the list can be replaced but not emptied — sending `[]`\nor `null` returns `400 EMPTY_AVAILABILITY_ZONES_NOT_SUPPORTED`.\n\n**Partial IPSec update:** When `ipsec` is present in the patch, sub-fields are\ndeep-merged — you may supply only `left.secret` to rotate the PSK without replacing\nthe rest of the configuration, or supply the full `ipsec` block to replace cipher\nsuites and endpoint addresses simultaneously.\n\n**`contact: null` is rejected.** Setting `contact` to `null` in a merge-patch returns\n`409` — the contact field cannot be removed from a dedicated gateway.\n\n**`tenantIds: []` is rejected.** Setting `tenantIds` to an empty array returns `400`\n— a dedicated gateway must always have at least one tenant (`minItems: 1` enforced by schema).\n\n**Known limitation:** Concurrent modifications to the same gateway may overwrite each\nother — no optimistic locking is in place for this release.\n\n**Datacenter change is destructive:** Expect a connectivity outage while the gateway is\nre-provisioned. `status.state` resets to `PENDING` immediately; `status.tunnelState` resets\nto `null`; status records for the old datacenter are expired. `dedicatedIps.ips` are not\ncleared immediately — treat them as unreliable until VSC completes provisioning in the new datacenter.\n\n\n**Required Permissions:** `ztna:update`",
        "operationId": "patchGateway",
        "x-required-privileges": [
          "ztna:update"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/merge-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/GatewayPatchRequest"
              },
              "examples": {
                "metadataOnly": {
                  "summary": "Update route metadata only",
                  "value": {
                    "name": "EU West Gateway (updated)",
                    "tenantIds": [
                      "550e8400-e29b-41d4-a716-446655440001",
                      "550e8400-e29b-41d4-a716-446655440002"
                    ],
                    "contact": {
                      "email": "ops@example.com",
                      "name": "Ops Team"
                    }
                  }
                },
                "deploymentOnly": {
                  "summary": "Disable the deployment",
                  "value": {
                    "enabled": false
                  }
                },
                "changeDatacenter": {
                  "summary": "Move to a different datacenter (zones must match new datacenter)",
                  "value": {
                    "datacenter": "eu-central-1",
                    "availabilityZones": [
                      "3.66.107.208",
                      "3.121.43.105"
                    ]
                  }
                },
                "combined": {
                  "summary": "Update metadata and deployment in one call",
                  "value": {
                    "name": "EU West Gateway (updated)",
                    "tenantIds": [
                      "550e8400-e29b-41d4-a716-446655440001"
                    ],
                    "enabled": true,
                    "availabilityZones": [
                      "18.202.42.169",
                      "54.220.161.57"
                    ]
                  }
                },
                "rotateIpsecPsk": {
                  "summary": "Rotate the IPSec pre-shared key",
                  "value": {
                    "ipsec": {
                      "left": {
                        "secret": "new-pre-shared-key"
                      }
                    }
                  }
                },
                "replaceIpsecConfig": {
                  "summary": "Replace full IPSec configuration (cipher suites + endpoints + key rotation)",
                  "value": {
                    "ipsec": {
                      "keyExchange": "ikev2",
                      "ike": {
                        "encryption": [
                          "aes256"
                        ],
                        "integrity": [
                          "sha256"
                        ],
                        "dhGroups": [
                          "modp2048"
                        ],
                        "lifetimeInSec": 28800
                      },
                      "esp": {
                        "encryption": [
                          "aes256"
                        ],
                        "integrity": [
                          "sha256"
                        ],
                        "dhGroups": [
                          "modp2048"
                        ],
                        "lifetimeInSec": 3600
                      },
                      "left": {
                        "id": "wpa.wandera.com",
                        "host": "%any",
                        "subnets": [
                          "172.31.140.203/29"
                        ],
                        "secret": "new-pre-shared-key"
                      },
                      "right": {
                        "id": "vpn-peer.corp.example.com",
                        "host": "81.145.130.194",
                        "subnets": [
                          "10.10.0.0/16"
                        ],
                        "vendor": "Cisco"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Gateway updated."
          },
          "400": {
            "$ref": "#/components/responses/badRequest"
          },
          "403": {
            "$ref": "#/components/responses/forbidden"
          },
          "404": {
            "description": "Gateway not found or belongs to a different tenant."
          },
          "409": {
            "$ref": "#/components/responses/conflict"
          },
          "429": {
            "$ref": "#/components/responses/tooManyRequests"
          }
        },
        "parameters": [
          {
            "$ref": "#/components/parameters/X-Tenant-Id"
          },
          {
            "$ref": "#/components/parameters/X-Environment-Id"
          }
        ],
        "security": [
          {
            "oauth2": [
              "ztna:update"
            ]
          }
        ]
      }
    }
  },
  "components": {
    "parameters": {
      "gatewayId": {
        "name": "gatewayId",
        "in": "path",
        "required": true,
        "schema": {
          "type": "string",
          "pattern": "^[0-9a-f]{4}$"
        },
        "description": "ID of the Gateway (obtained from `GET /gateways` or a create response). Format: 4-character lowercase hexadecimal string (e.g. `a1b2`).\n"
      },
      "X-Tenant-Id": {
        "name": "X-Tenant-Id",
        "in": "header",
        "required": false,
        "description": "The tenant UUID identifier. Send it to address tenant scope. This API is also published at environment scope — send that scope's header instead. Send exactly one scope header per request.",
        "schema": {
          "type": "string",
          "format": "uuid",
          "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
          "example": "e77c1408-10c8-4007-b177-abc9157fbcaa"
        }
      },
      "X-Environment-Id": {
        "name": "X-Environment-Id",
        "in": "header",
        "required": false,
        "description": "The environment UUID identifier. Send it to address environment scope. This API is also published at tenant scope — send that scope's header instead. Send exactly one scope header per request.",
        "schema": {
          "type": "string",
          "format": "uuid",
          "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
          "example": "e77c1408-10c8-4007-b177-abc9157fbcaa"
        }
      }
    },
    "responses": {
      "tooManyRequests": {
        "description": "Rate limit exceeded. Retry after the period indicated by `Retry-After`.",
        "headers": {
          "Retry-After": {
            "description": "Number of seconds to wait before retrying.",
            "schema": {
              "type": "integer"
            }
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            },
            "example": {
              "httpStatus": 429,
              "traceId": "ecf2ca07e23c0abc12393472f2b783df",
              "errors": [
                {
                  "code": "RATE_LIMIT_EXCEEDED",
                  "description": "Too many requests. Retry after the indicated period."
                }
              ]
            }
          }
        }
      },
      "badRequest": {
        "description": "Bad request — validation error. Common codes: `INVALID_FIELD` (schema or constraint violation), `IPSEC_SECRET_CLEAR_NOT_SUPPORTED` (explicit `null` sent for `ipsec.left.secret`), `IPSEC_REMOVAL_NOT_SUPPORTED` (explicit `null` sent for `ipsec` on a gateway that has IPSec configured), `EMPTY_AVAILABILITY_ZONES_NOT_SUPPORTED` (patch empties `availabilityZones` on a gateway that currently has zones).\n",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            },
            "examples": {
              "invalidField": {
                "summary": "Schema validation failure",
                "value": {
                  "httpStatus": 400,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "INVALID_FIELD",
                      "field": "name",
                      "description": "name must not be blank."
                    }
                  ]
                }
              },
              "ipsecSecretClear": {
                "summary": "Attempt to clear IPSec secret",
                "value": {
                  "httpStatus": 400,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "IPSEC_SECRET_CLEAR_NOT_SUPPORTED",
                      "field": "ipsec.left.secret",
                      "description": "The IPSec pre-shared key cannot be cleared. Provide a new value to rotate it, or omit the field to leave it unchanged."
                    }
                  ]
                }
              },
              "ipsecRemoval": {
                "summary": "Attempt to remove IPSec configuration",
                "value": {
                  "httpStatus": 400,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "IPSEC_REMOVAL_NOT_SUPPORTED",
                      "field": "ipsec",
                      "description": "IPSec configuration cannot be removed from a gateway that has it configured."
                    }
                  ]
                }
              },
              "emptyAvailabilityZones": {
                "summary": "Attempt to empty the availability zone list",
                "value": {
                  "httpStatus": 400,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "EMPTY_AVAILABILITY_ZONES_NOT_SUPPORTED",
                      "field": "availabilityZones",
                      "description": "availabilityZones must contain at least one address."
                    }
                  ]
                }
              }
            }
          }
        }
      },
      "forbidden": {
        "description": "Forbidden — the caller's organization does not own one or more of the supplied `tenantIds`. Any mismatch rejects the entire request.\n",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            },
            "example": {
              "httpStatus": 403,
              "traceId": "ecf2ca07e23c0abc12393472f2b783df",
              "errors": [
                {
                  "code": "FORBIDDEN",
                  "description": "One or more tenantIds do not belong to your organization."
                }
              ]
            }
          }
        }
      },
      "conflict": {
        "description": "Conflict — request is valid but cannot be processed due to current state. Common codes: `HOSTNAME_CONFLICT` — hostname already assigned to another App; `BARE_IPS_CONFLICT` — POST/PATCH app: one or more of the provided `bareIps` IP ranges conflict with an existing app (`field: bareIps`); `DEDICATED_IPS_LIMIT` — `dedicatedIps.enabled: true` quota exhausted; `IPSEC_LIMIT` — IPSec egress tunnel limit reached; `TLD_LIMIT_EXCEEDED` — limit on distinct top-level domains exceeded; `MISSING_CATEGORY_NAME` — `categoryName` does not match any category returned by `GET /v1/categories`; `MISSING_SKU2_FOR_RISK_CONTROL` — risk controls require SKU2 entitlement not held by this customer; `MISSING_USER_GROUPS` — one or more assignment group IDs do not exist for this customer; `UNSUPPORTED_BARE_IP_IN_REFERENCED_GATEWAY_IPSEC_CONFIG` — a `bareIps` subnet is not covered by the referenced gateway's IPSec tunnel `right.subnets`; `GATEWAY_REFERENCED_BY_ACCESS_POLICIES` — DELETE gateway: still referenced by one or more Access Policies; `GATEWAY_REFERENCED_BY_GROUPED_GATEWAYS` — DELETE gateway: still a member of one or more grouped gateways; `GATEWAY_REFERENCED_BY_DNS_ZONES` — DELETE gateway: still referenced by one or more Custom DNS Zones; `GROUPED_GATEWAY_REFERENCED_BY_ACCESS_POLICIES` — DELETE grouped-gateway: still referenced by one or more Access Policies; `GROUPED_GATEWAY_REFERENCED_BY_DNS_ZONES` — DELETE grouped-gateway: still referenced by one or more Custom DNS Zones; `CUSTOMERS_REFERENCED_BY_ACCESS_POLICIES` — PATCH gateway or grouped gateway: an unassigned customer is still referenced by one or more Access Policies; `CUSTOMERS_REFERENCED_BY_GROUPED_GATEWAYS` — PATCH gateway: an unassigned customer still uses this gateway via a grouped gateway; `CUSTOMERS_REFERENCED_BY_DNS_ZONES` — PATCH gateway or grouped gateway: an unassigned customer is still referenced by one or more Custom DNS Zones; `CUSTOMERS_FROM_DIFFERENT_ORGANIZATIONS` — PATCH gateway: the provided customers belong to different organizations; only customers from the same organization may be assigned together; `GATEWAYS_TUNNEL_FLAG_MISMATCH` — PATCH grouped-gateway: the combined set of referenced gateways (supplied plus the group's existing members) does not all share the same tunneled flag; distinct from `422 MIXED_TUNNEL_TYPES`, which rejects a supplied `gatewayIds` set that is itself mixed (`field: gatewayIds`); `IPSEC_CONFIG_DUPLICATE` — POST/PATCH gateway: a gateway with the same IPSec configuration already exists (`field: ipsec`); `PREDEFINED_APP_NOT_FOUND` — POST app: `predefinedAppId` does not resolve to an existing predefined app (`field: predefinedAppId`). Returned as `409` (not `422`): the id is checked against existing predefined apps, not the request's shape. `CONFLICT` — generic conflict fallback; emitted for conflict cases not covered by a specific code above (e.g. removing the contact from a dedicated VPN route). Note: inaccessible gateway IDs in request bodies return `422 GATEWAY_NOT_FOUND`, not `409`. An unresolvable `predefinedAppId` is the deliberate exception — it returns `409 PREDEFINED_APP_NOT_FOUND`.\n",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            },
            "examples": {
              "hostnameConflict": {
                "summary": "HOSTNAME_CONFLICT",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "HOSTNAME_CONFLICT",
                      "field": "hostnames",
                      "description": "Hostname 'atlassian.com' is already assigned to another App.",
                      "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
                    }
                  ]
                }
              },
              "bareIpsConflict": {
                "summary": "BARE_IPS_CONFLICT",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "BARE_IPS_CONFLICT",
                      "field": "bareIps",
                      "description": "One or more of the provided IP ranges conflict with an existing app."
                    }
                  ]
                }
              },
              "gatewayReferencedByAccessPolicies": {
                "summary": "GATEWAY_REFERENCED_BY_ACCESS_POLICIES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GATEWAY_REFERENCED_BY_ACCESS_POLICIES",
                      "description": "The gateway could not be deleted because it is referenced by one or more Access Policies. Disconnect this gateway from all policies, then try again."
                    }
                  ]
                }
              },
              "gatewayReferencedByGroupedGateways": {
                "summary": "GATEWAY_REFERENCED_BY_GROUPED_GATEWAYS",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GATEWAY_REFERENCED_BY_GROUPED_GATEWAYS",
                      "description": "The gateway could not be deleted because it is referenced by one or more grouped gateways. Disconnect this gateway from all grouped gateways, then try again."
                    }
                  ]
                }
              },
              "gatewayReferencedByDnsZones": {
                "summary": "GATEWAY_REFERENCED_BY_DNS_ZONES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GATEWAY_REFERENCED_BY_DNS_ZONES",
                      "description": "The gateway could not be deleted because it is referenced by one or more Custom DNS Zones. Disconnect this gateway from all zones, then try again."
                    }
                  ]
                }
              },
              "groupedGatewayReferencedByAccessPolicies": {
                "summary": "GROUPED_GATEWAY_REFERENCED_BY_ACCESS_POLICIES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GROUPED_GATEWAY_REFERENCED_BY_ACCESS_POLICIES",
                      "description": "The grouped gateway could not be deleted because it is referenced by one or more Access Policies. Disconnect this grouped gateway from all policies, then try again."
                    }
                  ]
                }
              },
              "groupedGatewayReferencedByDnsZones": {
                "summary": "GROUPED_GATEWAY_REFERENCED_BY_DNS_ZONES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GROUPED_GATEWAY_REFERENCED_BY_DNS_ZONES",
                      "description": "The grouped gateway could not be deleted because it is referenced by one or more Custom DNS Zones. Disconnect this grouped gateway from all zones, then try again."
                    }
                  ]
                }
              },
              "customersReferencedByAccessPolicies": {
                "summary": "CUSTOMERS_REFERENCED_BY_ACCESS_POLICIES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "CUSTOMERS_REFERENCED_BY_ACCESS_POLICIES",
                      "description": "The gateway or grouped gateway could not be modified because one or more unassigned customers are still referenced by one or more Access Policies. Remove the reference, then try again."
                    }
                  ]
                }
              },
              "customersReferencedByGroupedGateways": {
                "summary": "CUSTOMERS_REFERENCED_BY_GROUPED_GATEWAYS",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "CUSTOMERS_REFERENCED_BY_GROUPED_GATEWAYS",
                      "description": "The gateway could not be modified because one or more unassigned customers are still referenced by one or more grouped gateways. Remove the reference, then try again."
                    }
                  ]
                }
              },
              "customersReferencedByDnsZones": {
                "summary": "CUSTOMERS_REFERENCED_BY_DNS_ZONES",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "CUSTOMERS_REFERENCED_BY_DNS_ZONES",
                      "description": "The gateway or grouped gateway could not be modified because one or more unassigned customers are still referenced by one or more Custom DNS Zones. Remove the reference, then try again."
                    }
                  ]
                }
              },
              "customersFromDifferentOrganizations": {
                "summary": "CUSTOMERS_FROM_DIFFERENT_ORGANIZATIONS",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "CUSTOMERS_FROM_DIFFERENT_ORGANIZATIONS",
                      "description": "The provided customers belong to different organizations. Use only customers from the same organization."
                    }
                  ]
                }
              },
              "gatewaysTunnelFlagMismatch": {
                "summary": "GATEWAYS_TUNNEL_FLAG_MISMATCH",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "GATEWAYS_TUNNEL_FLAG_MISMATCH",
                      "field": "gatewayIds",
                      "description": "The combined set of referenced gateways, including existing members, must all have the same tunneled flag."
                    }
                  ]
                }
              },
              "ipsecConfigDuplicate": {
                "summary": "IPSEC_CONFIG_DUPLICATE",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "IPSEC_CONFIG_DUPLICATE",
                      "field": "ipsec",
                      "description": "A gateway with the same IPSec configuration already exists."
                    }
                  ]
                }
              },
              "predefinedAppNotFound": {
                "summary": "PREDEFINED_APP_NOT_FOUND",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "PREDEFINED_APP_NOT_FOUND",
                      "field": "predefinedAppId",
                      "description": "The predefined app 'atlassian-cloud' does not exist."
                    }
                  ]
                }
              },
              "ipsecLimit": {
                "summary": "IPSEC_LIMIT",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "IPSEC_LIMIT",
                      "description": "The IPSec egress limit has been reached (5 of 5)."
                    }
                  ]
                }
              },
              "tldLimitExceeded": {
                "summary": "TLD_LIMIT_EXCEEDED",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "TLD_LIMIT_EXCEEDED",
                      "description": "The number of distinct top-level domains (10) exceeds the maximum of 8."
                    }
                  ]
                }
              },
              "dedicatedIpsLimit": {
                "summary": "DEDICATED_IPS_LIMIT",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "DEDICATED_IPS_LIMIT",
                      "description": "The dedicated IP address limit has been reached (5 of 5)."
                    }
                  ]
                }
              },
              "missingCategoryName": {
                "summary": "MISSING_CATEGORY_NAME",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "MISSING_CATEGORY_NAME",
                      "description": "Category Web Browsing does not exist."
                    }
                  ]
                }
              },
              "missingUserGroups": {
                "summary": "MISSING_USER_GROUPS",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "MISSING_USER_GROUPS",
                      "description": "User groups [c375d769-0e0e-4cb3-99c0-3dcd5f48a36f, a1b2c3d4-e5f6-7890-abcd-ef1234567890] do not exist."
                    }
                  ]
                }
              },
              "missingSku2ForRiskControl": {
                "summary": "MISSING_SKU2_FOR_RISK_CONTROL",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "MISSING_SKU2_FOR_RISK_CONTROL",
                      "description": "The required component is not enabled for risk-based access control."
                    }
                  ]
                }
              },
              "unsupportedBareIpInReferencedGatewayIpsecConfig": {
                "summary": "UNSUPPORTED_BARE_IP_IN_REFERENCED_GATEWAY_IPSEC_CONFIG",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "UNSUPPORTED_BARE_IP_IN_REFERENCED_GATEWAY_IPSEC_CONFIG",
                      "description": "The referenced gateway's IPSec configuration does not support 10.10.0.0/24."
                    }
                  ]
                }
              },
              "genericConflict": {
                "summary": "CONFLICT",
                "value": {
                  "httpStatus": 409,
                  "traceId": "ecf2ca07e23c0abc12393472f2b783df",
                  "errors": [
                    {
                      "code": "CONFLICT",
                      "description": "The request conflicts with the current state of the resource."
                    }
                  ]
                }
              }
            }
          }
        }
      }
    },
    "schemas": {
      "ApiError": {
        "type": "object",
        "description": "Standard error response body. Returned for all non-2xx responses.\n",
        "required": [
          "httpStatus"
        ],
        "properties": {
          "httpStatus": {
            "type": "integer",
            "minimum": 100,
            "maximum": 599,
            "example": 400
          },
          "traceId": {
            "type": "string",
            "description": "Trace ID for correlating server-side errors. Include this value when reporting issues to Jamf support.\n",
            "example": "ecf2ca07e23c0abc12393472f2b783df"
          },
          "errors": {
            "type": "array",
            "description": "One entry per problem in the request.",
            "items": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "description": "Machine-readable error code.",
                  "example": "INVALID_FIELD"
                },
                "field": {
                  "type": "string",
                  "description": "Name of the field that caused the error, if applicable.",
                  "example": "categoryName"
                },
                "description": {
                  "type": "string",
                  "description": "Human-readable description for debugging. Do not display to end users.",
                  "example": "Value is not a recognized category."
                },
                "id": {
                  "type": "string",
                  "description": "ID of the object with the error, if applicable.",
                  "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
                }
              }
            }
          }
        }
      },
      "GatewayContact": {
        "type": "object",
        "description": "Operational contact for this gateway.",
        "required": [
          "email",
          "name"
        ],
        "properties": {
          "email": {
            "type": "string",
            "minLength": 1,
            "pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$",
            "description": "Contact email address.",
            "example": "netops@example.com"
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "description": "Contact name or team name.",
            "example": "Network Operations"
          }
        }
      },
      "GatewayPatchRequest": {
        "type": "object",
        "description": "Flat merge-patch body (`application/merge-patch+json`). All fields optional. When `datacenter` is omitted, the existing value is preserved. When `datacenter` changes, `availabilityZones` must be valid IPs for the new datacenter (e.g. `3.66.107.208` for `eu-central-1`) — returns `400` on mismatch.\n",
        "additionalProperties": false,
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "description": "New name for the gateway.",
            "example": "EU West Production Gateway"
          },
          "tenantIds": {
            "type": "array",
            "uniqueItems": true,
            "minItems": 1,
            "items": {
              "type": "string"
            },
            "description": "Replaces the full tenantIds list. Validated against the caller's organization — **403** if mismatched. Setting `tenantIds: []` (empty array) returns `400` — `minItems: 1` enforced by schema.\n",
            "example": [
              "3fa85f64-5717-4562-b3fc-2c963f66afa6"
            ]
          },
          "contact": {
            "$ref": "#/components/schemas/GatewayContact"
          },
          "datacenter": {
            "type": "string",
            "enum": [
              "af-south-1",
              "ap-east-1",
              "ap-northeast-1",
              "ap-south-1",
              "ap-southeast-1",
              "ap-southeast-2",
              "ca-central-1",
              "eu-central-1",
              "eu-west-1",
              "eu-west-2",
              "sa-east-1",
              "us-east-1",
              "us-west-2"
            ],
            "description": "New datacenter for this deployment (e.g. `eu-central-1`). When changed, `availabilityZones` must be valid IPs for the new datacenter — returns `400` on mismatch. **Destructive:** triggers re-provisioning, connectivity outage, and immediate `status.state` reset to `PENDING`. `dedicatedIps.ips` remain stale until VSC completes provisioning in the new datacenter.\n",
            "example": "eu-west-1"
          },
          "enabled": {
            "type": "boolean",
            "description": "Whether the deployment should be active.",
            "example": true
          },
          "availabilityZones": {
            "type": "array",
            "uniqueItems": true,
            "items": {
              "type": "string",
              "format": "ipv4"
            },
            "description": "Replaces the availability zone node list. Accepts public IPv4 addresses\n(e.g. `18.202.42.169`). Zones must belong to the (new or existing) datacenter.\nCannot be emptied once set — sending `[]` or `null` returns\n`400 EMPTY_AVAILABILITY_ZONES_NOT_SUPPORTED`. The list can still be replaced.\n\nFor **IPsec gateways**, these are the source addresses the peer firewall must allow. Valid IPs per datacenter:\n\n| Datacenter | Name | IP 1 | IP 2 |\n|---|---|---|---|\n| `af-south-1` | Africa - Cape Town | `13.244.169.182` | `13.246.106.52` |\n| `ap-east-1` | Asia - Hong Kong | `16.163.54.105` | `16.163.15.242` |\n| `ap-northeast-1` | Asia - Japan | `35.76.189.152` | `52.192.166.230` |\n| `ap-south-1` | Asia - Mumbai | `3.109.252.176` | `65.1.247.99` |\n| `ap-southeast-1` | Asia - Singapore | `18.140.158.235` | `52.77.139.71` |\n| `ap-southeast-2` | Australia | `54.66.243.182` | `13.238.46.250` |\n| `ca-central-1` | North America - Canada | `15.222.200.189` | `3.98.80.44` |\n| `eu-central-1` | Europe - Germany | `3.66.107.208` | `3.121.43.105` |\n| `eu-west-1` | Europe - Ireland | `54.220.161.57` | `18.202.42.169` |\n| `eu-west-2` | Europe - UK | `3.9.67.90` | `18.130.213.235` |\n| `sa-east-1` | South America - Brazil | `54.207.180.94` | `54.232.123.56` |\n| `us-east-1` | North America - USA East | `163.123.175.1` | `163.123.175.2` |\n| `us-west-2` | North America - USA West | `163.123.174.1` | `163.123.174.2` |\n",
            "example": [
              "18.202.42.169"
            ]
          },
          "ipsec": {
            "$ref": "#/components/schemas/GatewayIpSecPatchRequest",
            "description": "IPSec tunnel configuration to update. Fields are deep-merged — you may supply only `left.secret` to rotate the pre-shared key, or the full block to replace cipher suites and endpoint addresses simultaneously. `right.secret` is always derived from `left.secret` automatically — callers never set it directly. Sending `null` returns `400 IPSEC_REMOVAL_NOT_SUPPORTED`.\n"
          }
        }
      },
      "GatewayIpSecPatchRequest": {
        "type": "object",
        "description": "Partial IPSec configuration for PATCH. All fields optional — fields are deep-merged. Supply only `left.secret` to rotate the pre-shared key, or the full block to replace cipher suites and endpoint addresses simultaneously. `right.secret` is derived automatically from `left.secret` — callers never set it directly.\n",
        "properties": {
          "keyExchange": {
            "type": "string",
            "enum": [
              "ikev1",
              "ikev2"
            ],
            "example": "ikev2",
            "description": "IKE version."
          },
          "ike": {
            "$ref": "#/components/schemas/CipherSuiteConfig"
          },
          "esp": {
            "$ref": "#/components/schemas/CipherSuiteConfig"
          },
          "left": {
            "$ref": "#/components/schemas/ConnectionConfigPatchLeftRequest"
          },
          "right": {
            "$ref": "#/components/schemas/ConnectionConfigPatchRightRequest"
          }
        }
      },
      "CipherSuiteConfig": {
        "type": "object",
        "description": "Cipher suite configuration for an IKE or ESP phase.",
        "required": [
          "encryption",
          "integrity",
          "dhGroups",
          "lifetimeInSec"
        ],
        "properties": {
          "encryption": {
            "type": "array",
            "minItems": 1,
            "maxItems": 1,
            "items": {
              "type": "string",
              "enum": [
                "3des",
                "aes128",
                "aes256"
              ]
            },
            "description": "Encryption algorithm. Exactly one value.",
            "example": [
              "aes256"
            ]
          },
          "integrity": {
            "type": "array",
            "minItems": 1,
            "maxItems": 1,
            "items": {
              "type": "string",
              "enum": [
                "md5",
                "sha1",
                "sha256",
                "sha512"
              ]
            },
            "description": "Integrity algorithm. Exactly one value.",
            "example": [
              "sha256"
            ]
          },
          "dhGroups": {
            "type": "array",
            "minItems": 1,
            "maxItems": 1,
            "items": {
              "type": "string",
              "enum": [
                "modp1024",
                "modp1536",
                "modp2048",
                "modp3072",
                "modp4096",
                "ecp256",
                "ecp384",
                "ecp521"
              ]
            },
            "description": "Diffie-Hellman group. Exactly one value.",
            "example": [
              "modp2048"
            ]
          },
          "lifetimeInSec": {
            "type": "integer",
            "format": "int64",
            "minimum": 1,
            "description": "Key lifetime in seconds (e.g. `28800` for IKE, `3600` for ESP).",
            "example": 28800
          }
        }
      },
      "ConnectionConfigPatchLeftRequest": {
        "type": "object",
        "description": "IPSec connection endpoint for PATCH `left`. All fields optional — supply only the fields to update. `secret` is write-only; omit to preserve the existing PSK; sending `null` returns `400 IPSEC_SECRET_CLEAR_NOT_SUPPORTED`.\n",
        "properties": {
          "id": {
            "type": "string",
            "example": "wpa.wandera.com",
            "description": "IKE identity (e.g. `wpa.wandera.com` or `%any`)."
          },
          "host": {
            "type": "string",
            "example": "%any",
            "description": "Endpoint address or `%any`."
          },
          "subnets": {
            "type": "array",
            "uniqueItems": true,
            "minItems": 1,
            "maxItems": 1,
            "items": {
              "type": "string",
              "description": "Private RFC1918 IPv4 CIDR — `10.0.0.0/8` (prefix /8–/30), `172.16.0.0/12` (/12–/30), or `192.168.0.0/16` (/16–/30) (e.g. `172.31.140.203/29`).\n"
            },
            "description": "Jamf-side encryption domain. Must be a private (RFC1918) CIDR in one of the ranges above. Exactly 1 element.\n",
            "example": [
              "172.31.140.203/29"
            ]
          },
          "secret": {
            "type": "string",
            "format": "password",
            "writeOnly": true,
            "example": "new-pre-shared-key",
            "description": "Pre-shared key. Provide to set or rotate the PSK. Omit to preserve the existing secret. Sending `null` returns `400 IPSEC_SECRET_CLEAR_NOT_SUPPORTED`.\n"
          }
        }
      },
      "ConnectionConfigPatchRightRequest": {
        "type": "object",
        "description": "IPSec connection endpoint for PATCH `right` (remote peer). The secret is always derived from `left.secret` — callers never supply it here.\n",
        "properties": {
          "id": {
            "type": "string",
            "example": "%any",
            "description": "IKE identity (e.g. `wpa.wandera.com` or `%any`)."
          },
          "host": {
            "type": "string",
            "example": "%any",
            "description": "Endpoint address or `%any`."
          },
          "subnets": {
            "type": "array",
            "uniqueItems": true,
            "minItems": 1,
            "items": {
              "type": "string",
              "description": "IPv4 CIDR notation (e.g. `0.0.0.0/0`, `172.31.140.203/29`)."
            },
            "description": "CIDR subnets routed through this endpoint.",
            "example": [
              "0.0.0.0/0"
            ]
          },
          "vendor": {
            "type": "string",
            "enum": [
              "Checkpoint",
              "Cisco",
              "Fortinet",
              "Juniper",
              "Palo Alto",
              "SonicWall",
              "Sophos",
              "Sourcefire",
              "strongSwan",
              "Watchguard",
              "Other"
            ],
            "description": "VPN vendor identifier of the remote peer. Case-sensitive.",
            "example": "Cisco"
          }
        }
      }
    },
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "description": "Obtain an access token by calling the API Gateway's token endpoint using the OAuth2 client-credentials flow.",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "https://{region}.api.jamfcloud.com/auth/token",
            "scopes": {
              "ztna:create": "",
              "ztna:delete": "",
              "ztna:read": "",
              "ztna:update": ""
            }
          }
        }
      }
    }
  },
  "x-scope-types": [
    "tenant",
    "environment"
  ],
  "servers": [
    {
      "url": "https://{region}.api.jamfcloud.com/securitycloud",
      "description": "Jamf Beta API Gateway - prod",
      "variables": {
        "region": {
          "default": "us",
          "enum": [
            "us",
            "eu",
            "apac"
          ],
          "description": "Geographic deployment region"
        }
      }
    }
  ],
  "security": [
    {
      "oauth2": []
    }
  ]
}
```