Collections

A collection is a namespace inside your organization. Use one per product, environment, or agent. Calls without a collection use the default bucket.

Create collections in the dashboard. Pass the code (not an internal id) on SDK clients, REST bodies, or MCP tool calls.

const memory = new GomindClient(
  "https://api.gominddb.com",
  process.env.GOMIND_API_KEY!,
  { collection: "my-project" },
);

Precedence

First match wins:

  1. JSON body collection — including "", which forces the default bucket
  2. Query ?collection=
  3. Header X-Gomind-Collection
  4. Connection default (OAuth consent collection, or the default bucket for API keys)

On MCP, omit collection to use the connection default. Pass "" to force the default bucket.

Aliases default, null, none, nil, and undefined also mean the default bucket.

Unknown codes

A code that does not exist returns 404. The call is not billed.

One batch, one collection

remember_many commits the whole batch to a single collection. A per-fact collection is allowed only when it matches the batch. Split mixed namespaces into separate calls.

MCP list_collections returns the codes you can pass.