Set the ID of the configuration template linked to a resource
Changed onAttaches, repoints, or detaches the configuration template linked to a resource. This endpoint only manages the link (by ID) between a resource and an existing configuration template — it does not create, modify, or delete the template itself. To manage a template's own fields (name, description, request configurations, visibility, etc.), use the /configuration-templates endpoints.
The request body is {"configuration_template_id": "<uuid>" | null}:
- A <uuid> value links the resource to the configuration template with that ID. If the resource was previously linked to a different template, the resource is repointed in place.
- null detaches the resource from its current configuration template. The template is deep-copied into a new private configuration with the same settings so the resource's current behaviour is preserved, and the resource is repointed at the fork.
The configuration_template_id field is required. Sending {} or any body in which the field is omitted is rejected with 400.
The call is idempotent: if the request body matches the resource's current link, no changes are made and no audit events are emitted.
This endpoint is the preferred, Terraform-friendly surface for linking and unlinking configuration templates on resources. The equivalent configuration_template_id field on PUT /resources remains available but is deprecated for this purpose.
Request
- Base URLhttps://api.opal.dev/v1
- AuthHTTP bearer
Path parameters
The ID of the resource whose configuration template link is being set.
Request body
Example request
{
"configuration_template_id": "06851574-e50d-40ca-8c78-f72ae6ab4304"
}Response
The ID of the configuration template now linked to the resource, or null if the resource was detached.
Example response
{
"configuration_template_id": "06851574-e50d-40ca-8c78-f72ae6ab4304"
}Changes
- info
endpoint added
- info