> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ns.rocks/llms.txt
> Use this file to discover all available pages before exploring further.

# Names

> Reserve, rename, and inspect template names and namespaces.

Template names give builds stable refs that are easier to use than generated
template IDs.

<CodeGroup>
  ```python Python SDK theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  claim = Template.reserve_name("team/agent-template")
  print(claim.claim_token)

  namespace = Template.get_namespace("team")
  print(namespace.slug)

  Template.rename("team/agent-template", "agent-template-renamed")
  Template.release_name_claim(claim.claim_token)
  ```

  ```bash CLI theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  nullspace template reserve team/agent-template
  nullspace template namespace get team
  nullspace template rename team/agent-template agent-template-renamed
  nullspace template claim release tclm_...
  ```

  ```bash HTTP API theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  # Reserve a name claim
  curl -X POST "${NULLSPACE_API_URL}/v1/templates/claims" \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}" \
    -H "Content-Type: application/json" \
    -d '{"template_ref": "team/agent-template"}'

  # Inspect a namespace
  curl "${NULLSPACE_API_URL}/v1/templates/namespaces/team" \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}"

  # Rename a template (use /v1/templates/refs/{ref}/rename for slash-bearing refs)
  curl -X POST "${NULLSPACE_API_URL}/v1/templates/refs/team%2Fagent-template/rename" \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}" \
    -H "Content-Type: application/json" \
    -d '{"new_name": "agent-template-renamed"}'

  # Release a name claim
  curl -X DELETE "${NULLSPACE_API_URL}/v1/templates/claims/tclm_..." \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}"
  ```
</CodeGroup>

<Note>
  The TypeScript SDK exposes `client.templates.list()`, `.get(ref)`, and
  `.delete(ref)`; name reservation, namespaces, renaming, and field selection
  are available in the Python SDK, CLI, or HTTP API.
</Note>

Template refs can be IDs, canonical refs, or aliases depending on the
operation. Prefer canonical refs in automation when you need stable ownership
and namespace behavior.

Use field selection for compact index responses:

<CodeGroup>
  ```python Python SDK theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  templates = Template.list(fields=["id", "canonical_ref", "visibility"])
  info = Template.get("team/agent-template", fields=["id", "canonical_ref"])
  ```

  ```bash CLI theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  nullspace template list --fields id,canonical_ref,visibility
  nullspace template get team/agent-template --fields id,canonical_ref
  ```

  ```bash HTTP API theme={"theme":{"light":"one-light","dark":"one-dark-pro"}}
  curl "${NULLSPACE_API_URL}/v1/templates?fields=id,canonical_ref,visibility" \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}"

  curl "${NULLSPACE_API_URL}/v1/templates/team%2Fagent-template?fields=id,canonical_ref" \
    -H "Authorization: Bearer ${NULLSPACE_API_KEY}"
  ```
</CodeGroup>

## Related

* [Tags & versioning](./tags-versioning)
* [Templates overview](./overview)
