Skip to main content
POST
Create Namespace

Authorizations

Authorization
string
header
required

Mixpeek API key, sent as Authorization: Bearer mxp_sk_.... Create one in Studio under Settings → API Keys, or with an admin key via POST /v1/organizations/users/{user_email}/api-keys. A missing, malformed, unknown, revoked, inactive or expired key returns 401; a key without the permission, scope or plan an operation needs returns 403.

Body

application/json

Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).

Request schema for creating a new namespace.

namespace_name
string
required

Name of the namespace to create

Required string length: 3 - 64
Example:

"product-search"

namespace_id
string | null

Optional namespace ID override. Used for recovery/migration when recreating a namespace with a known ID. If not provided, a new ID is auto-generated.

mode
string | null
default:managed

Namespace mode. 'managed' (default) uses Mixpeek feature extractors. 'standalone' allows BYO vectors without extractors. If omitted and ONLY vector_configs is provided (no features/feature_extractors), standalone is inferred.

namespace_type
enum<string> | null
default:standard

Type of namespace. STANDARD for regular namespaces, MARKETPLACE for curated datasets.

Available options:
standard,
marketplace
scope
enum<string> | null
default:org

Ownership scope. ORG (default) creates an org-scoped namespace. SYSTEM requires Mixpeek admin privileges and creates a namespace visible read-only to every org — used for curated sample corpora.

Available options:
org,
system
description
string | null

Description of the namespace

Example:

"This namespace contains playlists from Spotify"

starred
boolean
default:false

Show this namespace at the top of the organization's namespace list. Free, and it has no effect on capacity or billing.

features
string[] | null

Modality+features config (contract v2 §6.2, D9): feature keys from GET /v1/collections/features (e.g. ['image_search', 'faces'] or ['custom:']). Resolved server-side to the UNION of feature extractors the namespace needs — the preferred alternative to feature_extractors (extractor names are internal implementation). A namespace hosts many collections, so multiple features spanning multiple extractors are fine here. May be combined with feature_extractors (the two merge as a union). If neither is provided, the namespace gets the standard baseline (same as the scaffolded default namespace). Managed mode only.

Example:
feature_extractors
BaseFeatureExtractorModel · object[] | null

List of feature extractors to configure for this namespace. DEPRECATED for direct use: prefer features: [...] (contract v2 §6.2, D9) — extractor names are internal implementation. Not used for standalone mode. If neither features nor feature_extractors is provided, the namespace defaults to the standard baseline. Each extractor requires 'feature_extractor_name' and 'version'. Optional 'params' can be specified for extractors with configurable settings (e.g., model selection) that affect vector dimensions. These params are locked at namespace creation time. Example: [{"feature_extractor_name": "multimodal_extractor", "version": "v1"}]

Example:
vector_configs
VectorConfigSpec · object[] | null

Optional vector index configurations for standalone mode. Each entry defines a named vector index with dimension and distance metric. If omitted, indexes are auto-created on first upsert (schema-on-write).

Example:
payload_indexes
PayloadIndexConfig · object[] | null

Optional list of custom payload index configurations. Indexes required by selected feature extractors will be added automatically.

Example:
auto_create_indexes
boolean | null

Enable automatic creation of vector store payload indexes based on filter usage patterns. When enabled, the system tracks which fields are most frequently filtered (>100 queries/24h) and automatically creates indexes to improve query performance. Background task runs every 6 hours. Expected performance improvement: 50-90% latency reduction for filtered queries. Defaults: managed namespaces off, standalone namespaces on. Set explicitly to false to opt out (including for standalone, so an agent can manage indexes itself).

Example:

true

adaptive_indexing
boolean | null

Let the vector index re-tune its own partition size and flush threshold from observed search latency. Off by default. When on, every change it makes is recorded in the namespace's mxp_platform_events collection (event_type index_adaptation) with the parameter, its old and new value, the search count that triggered it, and p95 search latency before and after.

Example:

false

hold
NamespaceHold · object | null

Keep everything in this namespace until a date: {reason, until}. While the hold is in force, nothing in the namespace can be deleted and each uploaded file is held in storage. Needs an API key with admin permission and Mixpeek-managed storage that supports holds. Cannot be combined with ttl_seconds.

ttl_seconds
integer | null

Time-to-live in seconds. Namespace will be auto-deleted after this duration.

Required range: x >= 60
infrastructure
NamespaceInfrastructure · object | null

Optional dedicated infrastructure configuration for this namespace. Required for custom plugins and custom models (Enterprise tier). If None, uses shared infrastructure or organization-level infrastructure.

Example:
trusted_issuers
NamespaceTrustedIssuer · object[] | null

Identity providers whose end-user tokens (OIDC/JWT, verified against a JWKS) may call this namespace directly from a browser, each with the retrievers and collections it may use and the claims applied as filters. None or empty accepts no end-user tokens.

Maximum array length: 5
tiering
TieringOverride · object | null

This namespace's tiering override: enabled, idle_days {cold, frozen} and exempt (a reason). Each field left unset inherits the platform's data-class default, and each collection inherits from here. An exempt namespace is never demoted. The same override PATCH sets.

spend_budget
NamespaceSpendBudgetUpdate · object | null

Set this namespace's daily and monthly spend budget in USD. It must fit inside the organization's budget. A null field returns to the organization's namespace default. Each change is recorded with who made it, when, and the prior value.

cost_cap_override
NamespaceCostCapOverride · object | null

Start this namespace with an explicit daily inference cost cap instead of the tier default. Requires daily_usd, reason and owner.

Response

Successful Response

Namespace model.

namespace_name
string
required

Name of the namespace

Maximum string length: 64
Example:

"product-search"

object
string
default:namespace
read-only

Resource type identifier, always 'namespace'.

follow
NamespaceFollow · object | null

Set on a branch that follows its source: how far it has applied the source's changes, and why it stopped or failed. Read from stored state without waking the namespace; add ?include=follow_live to ask it directly.

namespace_id
string

Unique identifier for the namespace. Format: ns_.

namespace_type
enum<string>
default:standard

Type of namespace. STANDARD for regular namespaces, MARKETPLACE for curated datasets that can be subscribed to.

Available options:
standard,
marketplace
scope
enum<string>
default:org

Ownership scope. ORG (default) is org-scoped — only visible to members of the owning organization. SYSTEM is Mixpeek-owned and visible read-only to every authenticated org; used for curated sample corpora. Mutations on SYSTEM namespaces require admin auth.

Available options:
org,
system
infrastructure
NamespaceInfrastructure · object | null

Infrastructure configuration for the namespace.

Example:
trusted_issuers
NamespaceTrustedIssuer · object[] | null

Identity providers whose end-user tokens (OIDC/JWT, verified against a JWKS) may call this namespace directly from a browser, each with the retrievers and collections it may use and the claims applied as filters. None or empty accepts no end-user tokens.

Maximum array length: 5
cost_cap_override
NamespaceCostCapOverride · object | null

Deprecated: use spend_budget. Explicit daily inference cost cap for this namespace, kept working for existing callers.

tiering
TieringOverride · object | null

This namespace's tiering override: enabled, idle_days and exempt (a reason). Each field left unset inherits the platform's data-class default, and each collection inherits from here. An exempt namespace is never demoted.

pinned
NamespacePin · object | null

This namespace's pin: enabled, warm_query_encoder, and who set it when. A pinned namespace with warm_query_encoder keeps one replica of each query encoder its searches call running, billed per replica-hour as its own invoice line. Absent means not pinned.

starred
boolean
default:false

Shows this namespace at the top of the organization's namespace list. A display preference shared by everyone in the organization: free, with no limit on how many, and no effect on capacity or billing. Separate from pinned, which keeps capacity warm.

spend_budget
Spend Budget · object | null

This namespace's own spend budget as stored: daily_usd, monthly_usd and the change history. Absent until someone sets it; the organization's namespace default applies until then.

budget
Budget · object | null

Read-only. The namespace's effective daily and monthly budget, where each number comes from, spend to date, and the headroom left under the organization's budget. Computed on GET; never stored.

cluster_id
string | null

Infrastructure cluster ID for this namespace (Enterprise only). When set, this namespace uses a dedicated compute and vector cluster. If None, uses shared infrastructure or organization-level infrastructure. Format: iclstr_xxx

Example:

"iclstr_abc123xyz"

description
string | null

Description of the namespace

feature_extractors
BaseFeatureExtractorModel · object[]

List of feature extractors configured for this namespace

payload_indexes
PayloadIndexConfig · object[] | null

Custom payload indexes configured for this namespace

payload_index_count
integer | null

Number of USER (non-protected) payload indexes on this namespace — the same count the Studio Namespaces table shows per row. Populated even in the summary LIST view, which omits the heavy payload_indexes array itself (the array is ~75% of the list payload, but its count is a single integer). Without it the table can only show '—'.

document_count
integer | null

Total number of documents in this namespace

document_count_complete
boolean | null
default:true

False when the live vector-store count above did not finish in time (e.g. a shard still replaying its WAL after a restart) and document_count is therefore null rather than a real count, including a genuine zero. True (the default) covers every non-degraded response, including an empty namespace, whose document_count is 0 with this true.

bucket_count
integer | null

Total number of buckets in this namespace

collection_count
integer | null

Total number of collections in this namespace

object_count
integer | null

Total number of objects across all buckets in this namespace

auto_create_indexes
boolean
default:false

Enable automatic creation of vector store payload indexes based on filter usage patterns. When enabled, the system tracks which fields are most frequently filtered (>100 queries/24h) and automatically creates indexes to improve query performance. Background task runs every 6 hours. Expected performance improvement: 50-90% latency reduction for filtered queries.

adaptive_indexing
boolean
default:false

Let the vector index re-tune its own partition size and flush threshold from observed search latency. Off by default. When on, every change it makes is recorded in the namespace's mxp_platform_events collection (event_type index_adaptation) with the parameter, its old and new value, the search count that triggered it, and p95 search latency before and after.

vector_inference_map
Vector Inference Map · object | null

Mapping of vector index names to inference service names. Built at namespace creation based on extractor configurations. Used by feature search to determine correct inference service for queries. Example: {'image_extractor_v1_embedding': 'google_siglip_base_v1'}

dynamic_vector_indexes
boolean | null

Creation-time marker for BYO vector-name handling. False = the namespace was created with EXPLICIT vector_configs, so upserting a vector name outside those configs is rejected (422) instead of silently auto-indexed under a name nothing searches. True = fully dynamic BYO namespace (created without vector_configs): new vector names keep being inferred on first upsert. Null (namespaces that predate the marker) behaves as True so existing flows are unchanged.

mode
string | null

Namespace mode: 'managed' (Mixpeek manages vector schemas and inference) or 'standalone' (bring-your-own vectors). Populated from the stored mvs_mode; null for namespaces that predate BYOV.

vector_configs
Vector Configs · object[] | null

For standalone / promoted (BYO-vector) namespaces, the per-vector configs: name, dimension, metric. Populated from the stored mvs_vector_configs; null for managed namespaces with no BYO vectors.

clone_status
string | null

Deep-clone / scaffold sample-data progress: 'cloning' (in flight), 'ready' (completed), 'failed' (see clone_error). Null for namespaces that were never cloned. Poll this after a scaffold instantiate with include_sample_data=true.

clone_error
string | null

Error detail when clone_status='failed'; null otherwise.

clone_phase
string | null

Fine-grained clone progress: 'queued' (dispatched, waiting for a worker — a clone can wait many minutes behind tenant heavy-queue backlogs), 'copying' (the clone task is actively running), null once terminal (see clone_status) or for namespaces never cloned. Distinguishes a queue-starved clone from a dead one.

clone_task_id
string | null

Work id of the in-flight or last deep clone, for diagnosing a stalled clone from the namespace record alone.

clone_dispatched_at
string<date-time> | null

When the deep-clone task was dispatched; with clone_phase='queued' this measures time spent waiting for a worker.

source_namespace_id
string | null

For a cloned namespace, the source (golden/sample) namespace id it was cloned from.

namespace_ready
boolean
default:false

ALWAYS PRESENT. True only after the server CONFIRMED this namespace is usable: its vector collection exists and is reachable (a served live count, the readiness signal) and no clone is in flight. Never a prediction or timestamp. A wizard-created namespace mid-provision reads false (poll the namespace GET; it flips true on the first confirming read and the flip is persisted). Namespaces created before the feature shipped emit true; post-ship namespaces with no stored value emit false (fail toward not-ready).

created_at
string<date-time> | null

When the namespace was created

updated_at
string<date-time> | null

When the namespace was last updated

hold
NamespaceHold · object | null

Keeps everything in this namespace until a date: {reason, until}. While the hold is in force, no document, object, collection, bucket or the namespace itself can be deleted, and each uploaded file is held in storage too. New documents can still be added. Null means the namespace is not held.

expires_at
string<date-time> | null

UTC timestamp after which the namespace is deleted automatically. Set at create time from ttl_seconds, and changed or cleared with PATCH (expires_at or ttl_seconds). An hourly sweep records a namespace_expiring event in the namespace's mxp_platform_events collection about an hour before, and deletes the namespace once the expiry has passed and that warning is an hour old. Null means the namespace never expires.