PUT/api/networks/{networkId}/resources/{resourceId}

Replace a network resource

Replaces the configuration of a network resource in the specified network. Provide its name, address, enabled status, and groups; the address can be a host, subnet, or domain. You can include an optional description.

2 parameters · 5 body fields
networkIdstringrequired
The unique identifier of the network containing the resource.
resourceIdstringrequired
The unique identifier of the network resource to replace.

Network resource configuration. When you send a body, name, address, enabled, and groups are required.

addressstringrequired
Network resource address (either a direct host like 1.1.1.1 or 1.1.1.1/32, or a subnet like 192.168.178.0/24, or domains like example.com and *.example.com)
descriptionstringoptional
Network resource description
enabledbooleanrequired
Network resource status
namestringrequired
Network resource name
groupsarray<string>required
Group IDs containing the resource

5 status codes
200Returns the updated network resource object, including its identifier, type, groups, address, name, enabled status, and description.
groupsarray<object>required
Groups that the resource belongs to
idstringrequired
Network Resource ID
typestringrequired
Network resource type based of the address
Allowed:hostsubnetdomain
addressstringrequired
Network resource address (either a direct host like 1.1.1.1 or 1.1.1.1/32, or a subnet like 192.168.178.0/24, or domains like example.com and *.example.com)
descriptionstringoptional
Network resource description
enabledbooleanrequired
Network resource status
namestringrequired
Network resource name
400Returned when the request is invalid.
401Returned when the request lacks valid authentication.
403Returned when the authenticated user is not permitted to update the network resource.
500Returned when an internal server error occurs.

Error handling

A 400 indicates an invalid request; a 401 indicates missing or invalid authentication; a 403 indicates insufficient permission; and a 500 indicates an internal server error. The networkId path parameter must identify the network, and the resourceId path parameter must identify the resource to replace. When you send a body, name, address, enabled, and groups are required.