---
title: "Get one namespace, with its size"
method: GET
path: "/v2/workspaces/{id}/namespaces/{ns}"
tags: ["Memories"]
---

# Get one namespace, with its size

`GET /v2/workspaces/{id}/namespaces/{ns}`

## Request

- Base URL: `https://api.infolang.ai`
- URL: `https://api.infolang.ai/v2/workspaces/{id}/namespaces/{ns}`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer

One namespace and the number of memories and chunks it holds — the count a destructive confirmation has to show. Same native op as the list route, so it costs one billed unit and no egress.

`exists: false` with zero counts is the answer for a namespace that holds nothing. That is not a 404: a namespace that is already gone is a question with a true answer.

Subject to the credential's `scoped_namespaces` — otherwise a scoped credential could learn the SIZE of namespaces it cannot read, one name at a time.

Requires the `memories:read` scope. Accepts all three lanes: a session JWT (bounded by the caller's role on this workspace) or an `il_*` machine credential whose own scope set, workspace set and validity window cover it — both ceilings apply and neither can raise the other, so a credential carrying `memories:read` is still refused where the role does not permit it.

A credential with no scope record resolves to `LEGACY_DEFAULT`, which INCLUDES `memories:read` — every key minted before scoping keeps working here.

## Path parameters

- `id` string, required
- `ns` string, required

## Response `200`

The namespace and its size

- object
  - `namespace` string, required
  - `exists` boolean, required
  - `memories` integer, required
  - `chunks` integer, required

## Other responses

- `401`: Missing/invalid credential
- `403`: The credential holds no grant on this workspace. Or `lane_not_supported` — the credential is well-formed but this route does not accept its lane
- `502`: Upstream Kairos failure

---

[API](https://skmtc.dev/infolang/apis/infolang-api.md) · [All operations](https://skmtc.dev/infolang/apis/infolang-api/llms.txt) · [OpenAPI document](https://skmtc.dev/infolang/apis/infolang-api/revisions/d04bf6de72c8?raw)
