v1

latestOpenAPI 3.1.0BSD-32026-07-2471176175.5 KB
costformation-namespaces

Update a namespace

Replaces the settings for a specific namespace, including role-based access control (view_role_ids, edit_role_ids) and the optional display_name. edit_role_ids must be a subset of view_role_ids.

put/v2/costformation/namespace/{id}

Path parameters

idstring required

The namespace identifier (FQN format)

Headers

cloudzero-idempotency-keystring

If passed, any subsequent operation with the same value for this header will return the exact same result. This is true for all responses, i.e. successes and errors.

cloudzero-test-keystring

If passed, the operation executes in the namespace specified by this key. Resource mutations in the namespace last for 1 hour.

Request body

view_role_idsstring[] nullable

List of Role IDs whose members can view dimensions in this namespace. If null or empty, the namespace is publicly visible to all users.

edit_role_idsstring[] nullable

List of Role IDs whose members can create and edit dimensions in this namespace. If null or empty, the namespace is publicly editable. Must be a subset of view_role_ids.

display_namestring nullable

Optional human-friendly display name for the namespace. If not provided, the namespace identifier (FQN) is used as the display name.

Example request

{
  "view_role_ids": [
    "a1b2c3d4-5678-4abc-9def-012345678901"
  ],
  "edit_role_ids": [
    "a1b2c3d4-5678-4abc-9def-012345678901"
  ],
  "display_name": "Production"
}

Response

Namespace updated successfully

Example response

{
  "namespace": {
    "id": "User:Production",
    "view_role_ids": [
      "a1b2c3d4-5678-4abc-9def-012345678901"
    ],
    "edit_role_ids": [
      "a1b2c3d4-5678-4abc-9def-012345678901"
    ],
    "display_name": "Production"
  }
}