Create an in-memory client for local use.This client stores all data in memory and does not persist to disk.
It is intended for testing and development.
Optional[Settings]
Optional settings to override defaults.
str
Tenant name to use for requests. Defaults to the default tenant.
str
Database name to use for requests. Defaults to the default database.
PersistentClient
Create a persistent client that stores data on disk.This client is intended for local development and testing. For production,
prefer a server-backed Chroma instance.
Union[str, Path]
Directory to store persisted data.
Optional[Settings]
Optional settings to override defaults.
str
Tenant name to use for requests.
str
Database name to use for requests.
HttpClient
Create a client that connects to a Chroma server.
str
Hostname of the Chroma server.
int
HTTP port of the Chroma server.
bool
Whether to enable SSL for the connection.
Optional[Dict[str, str]]
Optional headers to send with each request.
Optional[Settings]
Optional settings to override defaults.
str
Tenant name to use for requests.
str
Database name to use for requests.
AsyncHttpClient
Create an async client that connects to a Chroma HTTP server.This supports multiple clients connecting to the same server and is the
recommended production configuration.
str
Hostname of the Chroma server.
int
HTTP port of the Chroma server.
bool
Whether to enable SSL for the connection.
Optional[Dict[str, str]]
Optional headers to send with each request.
Optional[Settings]
Optional settings to override defaults.
str
Tenant name to use for requests.
str
Database name to use for requests.
CloudClient
Create a client for Chroma Cloud.If not provided, tenant, database, and api_key will be inferred from the environment variables CHROMA_TENANT, CHROMA_DATABASE, and CHROMA_API_KEY.
Optional[str]
Tenant name to use, or None to infer from credentials.
Optional[str]
Database name to use, or None to infer from credentials.
Optional[str]
API key for Chroma Cloud.
Optional[Settings]
Optional settings to override defaults.
str
int
bool
AdminClient
Create an admin client for tenant and database management.
Settings
Client Methods
heartbeat
Get the current time in nanoseconds since epoch.Used to check if the server is alive.Returns: The current time in nanoseconds since epoch
list_collections
List all collections.
Optional[int]
The maximum number of entries to return. Defaults to None.
Optional[int]
The number of entries to skip before returning. Defaults to None.
Returns: A list of collections
count_collections
Count the number of collections.Returns: The number of collections.
create_collection
Create a new collection with the given name and metadata.
str
required
The name of the collection to create.
Optional[Schema]
Optional[CreateCollectionConfiguration]
Optional[Dict[str, Any]]
Optional metadata to associate with the collection.
Optional[EmbeddingFunction[Optional[Embeddings]]]
Optional function to use to embed documents.
Uses the default embedding function if not provided.
Optional[DataLoader[Optional[Embeddings]]]
Optional function to use to load records (documents, images, etc.)
bool
If True, return the existing collection if it exists.
Returns: The newly created collection.Raises:
ValueError: If the collection already exists and get_or_create is False.
ValueError: If the collection name is invalid.
get_collection
Get a collection with the given name.
str
required
The name of the collection to get
Optional[EmbeddingFunction[Optional[Embeddings]]]
Optional function to use to embed documents.
Uses the default embedding function if not provided.
Optional[DataLoader[Optional[Embeddings]]]
Optional function to use to load records (documents, images, etc.)
Returns: The collectionRaises:
ValueError: If the collection does not exist
get_or_create_collection
Get or create a collection with the given name and metadata.Args:
name: The name of the collection to get or create
metadata: Optional metadata to associate with the collection. If
the collection already exists, the metadata provided is ignored.
If the collection does not exist, the new collection will be created
with the provided metadata.
embedding_function: Optional function to use to embed documents
data_loader: Optional function to use to load records (documents, images, etc.)Returns:
The collectionExamples:
{"docsConfig":{"theme":"aspen","$schema":"https://mintlify.com/docs.json","name":"Chroma Docs","colors":{"primary":"#ff6446","light":"#3b82f6","dark":"#3b82f6"},"logo":{"light":"https://mintcdn.com/chroma-8943dec5/zDKM3GBjHr8r61ad/images/light-logo.svg?fit=max\u0026auto=format\u0026n=zDKM3GBjHr8r61ad\u0026q=85\u0026s=d487d229a3d00bed252f4728417390fe","dark":"https://mintcdn.com/chroma-8943dec5/zDKM3GBjHr8r61ad/images/dark-logo.svg?fit=max\u0026auto=format\u0026n=zDKM3GBjHr8r61ad\u0026q=85\u0026s=9a0a6a79ac0ebba171a05f875bd724e1"},"favicon":"https://mintcdn.com/chroma-8943dec5/zDKM3GBjHr8r61ad/images/favicon.svg?fit=max\u0026auto=format\u0026n=zDKM3GBjHr8r61ad\u0026q=85\u0026s=490f4b16d291523f62110db3bdff5500","api":{"examples":{"languages":["curl","terminal","python","typescript","rust"]}},"appearance":{"default":"system"},"navbar":{"links":[{"icon":"github","href":"https://github.com/chroma-core/chroma","label":"27k"},{"icon":"discord","href":"https://discord.gg/dSHcBEMSk7","label":"11k"},{"icon":"x-twitter","href":"https://x.com/trychroma","label":"29k"}],"primary":{"type":"button","label":"Dashboard","href":"https://trychroma.com/login"}},"footer":{"socials":{"github":"https://github.com/chroma-core/chroma","x":"https://x.com/trychroma","discord":"https://discord.gg/MMeYNTmh3x","youtube":"https://youtube.com/@trychroma"},"links":[{"items":[{"label":"Enterprise","href":"https://trychroma.com/enterprise"},{"label":"Pricing","href":"https://trychroma.com/pricing"},{"label":"Changelog","href":"https://trychroma.com/changelog"}]}]},"fonts":{"family":"Inter"},"integrations":{"gtm":{"tagId":"GTM-T8MGS4GJ"},"posthog":{"apiKey":"phc_M1NrBVW8hgvKCGYxVtYusnbBvpVq9sKpE7FJMew9suK","sessionRecording":false}},"contextual":{"options":["copy","view","grok","chatgpt","claude","mcp","cursor","vscode"],"display":"header"},"thumbnails":{"background":"https://mintcdn.com/chroma-8943dec5/4JUAmIxOVRcPzFno/images/og-bg.png?fit=max\u0026auto=format\u0026n=4JUAmIxOVRcPzFno\u0026q=85\u0026s=1bad42a6df47084c8ff628738967bc4b"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"chroma-8943dec5","hasAudioNarration":false,"actualSubdomain":"chroma-8943dec5","customDomains":["docs.trychroma.com"],"gitSource":{"type":"github","owner":"chroma-core","repo":"chroma","deployBranch":"main","contentDirectory":"docs/mintlify","isPrivate":false,"mountPath":"","label":""},"feedback":{"edits":true,"issues":false,"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"REMOVE_BRANDING":{"status":"ENABLED"},"CONTEXTUAL_FEEDBACK":{"status":"ENABLED"},"CODE_SNIPPET_FEEDBACK":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aeeae7a7e16d2194a71edc7","clientVersion":"0.0.4177","searchFilterCounts":[{"language":"default","tag":"Reference","count":65},{"language":"default","tag":"APIs","count":44},{"language":"default","tag":"Integrations","count":39},{"language":"default","tag":"Docs","count":29},{"language":"default","tag":"Chroma Core API","count":27},{"language":"default","tag":"Chroma Cloud","count":25},{"language":"default","tag":"Dense Embedding Models","count":21},{"language":"default","tag":"Guides","count":16},{"language":"default","tag":"Frameworks","count":13},{"language":"default","tag":"SDKs","count":13}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true,"deflection":{"enabled":true,"email":"support@trychroma.com","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-bash","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"[data-component-part=\"step-number\"]>div{border-radius:0;border:1px solid #000000;background-color:#ffffff;font-family:ui-monospace, monospace;font-weight:400;box-shadow:2px 2px 0 0 #000000}.dark [data-component-part=\"step-number\"]>div{border-color:#c4c5c8;background-color:#111827;box-shadow:2px 2px 0 0 #babbbf}[data-component-part=\"step-line\"]{background-color:#000000;background-image:none!important}.dark [data-component-part=\"step-line\"]{background-color:#c4c5c8}[data-testid=\"tab-TypeScript\"] .tab-icon{display:none}[data-testid=\"tab-TypeScript\"]::before{content:\"\";display:inline-block;width:1rem;height:1rem;background-color:currentColor;-webkit-mask-image:url(\"/images/typescript.svg\");mask-image:url(\"/images/typescript.svg\");-webkit-mask-size:contain;mask-size:contain;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}a[href*=\"mintlify.com?utm_campaign=poweredBy\"] span{display:none}a[href*=\"mintlify.com?utm_campaign=poweredBy\"]::after{content:\"is powered by Chroma\"}a[href=\"/reference/typescript\"] [data-component-part=\"card-icon\"] svg{-webkit-mask-image:url(\"/images/typescript.svg\")!important;mask-image:url(\"/images/typescript.svg\")!important;-webkit-mask-size:contain;mask-size:contain;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.dark #topbar-cta-button{opacity:0.85}"}],"page":{"pagePath":"reference/python/client","slug":"/reference/python/client","pageMetadata":{"title":"Client","description":null,"href":"/reference/python/client"},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,hr:`hr`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,ParamField}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`clients`,children:`Clients`}),`\n`,_jsx(Heading,{level:`3`,id:`ephemeralclient`,children:`EphemeralClient`}),`\n`,_jsx(_components.p,{children:`Create an in-memory client for local use.`}),`\n`,_jsx(_components.p,{children:`This client stores all data in memory and does not persist to disk.\nIt is intended for testing and development.`}),`\n`,_jsx(ParamField,{path:`settings`,type:`Optional[Settings]`,id:`param-settings`,children:_jsx(_components.p,{children:`Optional settings to override defaults.`})}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant`,children:_jsx(_components.p,{children:`Tenant name to use for requests. Defaults to the default tenant.`})}),`\n`,_jsx(ParamField,{path:`database`,type:`str`,id:`param-database`,children:_jsx(_components.p,{children:`Database name to use for requests. Defaults to the default database.`})}),`\n`,_jsx(Heading,{level:`3`,id:`persistentclient`,children:`PersistentClient`}),`\n`,_jsx(_components.p,{children:`Create a persistent client that stores data on disk.`}),`\n`,_jsx(_components.p,{children:`This client is intended for local development and testing. For production,\nprefer a server-backed Chroma instance.`}),`\n`,_jsx(ParamField,{path:`path`,type:`Union[str, Path]`,id:`param-path`,children:_jsx(_components.p,{children:`Directory to store persisted data.`})}),`\n`,_jsx(ParamField,{path:`settings`,type:`Optional[Settings]`,id:`param-settings-1`,children:_jsx(_components.p,{children:`Optional settings to override defaults.`})}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-1`,children:_jsx(_components.p,{children:`Tenant name to use for requests.`})}),`\n`,_jsx(ParamField,{path:`database`,type:`str`,id:`param-database-1`,children:_jsx(_components.p,{children:`Database name to use for requests.`})}),`\n`,_jsx(Heading,{level:`3`,id:`httpclient`,children:`HttpClient`}),`\n`,_jsx(_components.p,{children:`Create a client that connects to a Chroma server.`}),`\n`,_jsx(ParamField,{path:`host`,type:`str`,id:`param-host`,children:_jsx(_components.p,{children:`Hostname of the Chroma server.`})}),`\n`,_jsx(ParamField,{path:`port`,type:`int`,id:`param-port`,children:_jsx(_components.p,{children:`HTTP port of the Chroma server.`})}),`\n`,_jsx(ParamField,{path:`ssl`,type:`bool`,id:`param-ssl`,children:_jsx(_components.p,{children:`Whether to enable SSL for the connection.`})}),`\n`,_jsx(ParamField,{path:`headers`,type:`Optional[Dict[str, str]]`,id:`param-headers`,children:_jsx(_components.p,{children:`Optional headers to send with each request.`})}),`\n`,_jsx(ParamField,{path:`settings`,type:`Optional[Settings]`,id:`param-settings-2`,children:_jsx(_components.p,{children:`Optional settings to override defaults.`})}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-2`,children:_jsx(_components.p,{children:`Tenant name to use for requests.`})}),`\n`,_jsx(ParamField,{path:`database`,type:`str`,id:`param-database-2`,children:_jsx(_components.p,{children:`Database name to use for requests.`})}),`\n`,_jsx(Heading,{level:`3`,id:`asynchttpclient`,children:`AsyncHttpClient`}),`\n`,_jsx(_components.p,{children:`Create an async client that connects to a Chroma HTTP server.`}),`\n`,_jsx(_components.p,{children:`This supports multiple clients connecting to the same server and is the\nrecommended production configuration.`}),`\n`,_jsx(ParamField,{path:`host`,type:`str`,id:`param-host-1`,children:_jsx(_components.p,{children:`Hostname of the Chroma server.`})}),`\n`,_jsx(ParamField,{path:`port`,type:`int`,id:`param-port-1`,children:_jsx(_components.p,{children:`HTTP port of the Chroma server.`})}),`\n`,_jsx(ParamField,{path:`ssl`,type:`bool`,id:`param-ssl-1`,children:_jsx(_components.p,{children:`Whether to enable SSL for the connection.`})}),`\n`,_jsx(ParamField,{path:`headers`,type:`Optional[Dict[str, str]]`,id:`param-headers-1`,children:_jsx(_components.p,{children:`Optional headers to send with each request.`})}),`\n`,_jsx(ParamField,{path:`settings`,type:`Optional[Settings]`,id:`param-settings-3`,children:_jsx(_components.p,{children:`Optional settings to override defaults.`})}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-3`,children:_jsx(_components.p,{children:`Tenant name to use for requests.`})}),`\n`,_jsx(ParamField,{path:`database`,type:`str`,id:`param-database-3`,children:_jsx(_components.p,{children:`Database name to use for requests.`})}),`\n`,_jsx(Heading,{level:`3`,id:`cloudclient`,children:`CloudClient`}),`\n`,_jsx(_components.p,{children:`Create a client for Chroma Cloud.`}),`\n`,_jsxs(_components.p,{children:[`If not provided, `,_jsx(_components.code,{children:`tenant`}),`, `,_jsx(_components.code,{children:`database`}),`, and `,_jsx(_components.code,{children:`api_key`}),` will be inferred from the environment variables `,_jsx(_components.code,{children:`CHROMA_TENANT`}),`, `,_jsx(_components.code,{children:`CHROMA_DATABASE`}),`, and `,_jsx(_components.code,{children:`CHROMA_API_KEY`}),`.`]}),`\n`,_jsx(ParamField,{path:`tenant`,type:`Optional[str]`,id:`param-tenant-4`,children:_jsx(_components.p,{children:`Tenant name to use, or None to infer from credentials.`})}),`\n`,_jsx(ParamField,{path:`database`,type:`Optional[str]`,id:`param-database-4`,children:_jsx(_components.p,{children:`Database name to use, or None to infer from credentials.`})}),`\n`,_jsx(ParamField,{path:`api_key`,type:`Optional[str]`,id:`param-api-key`,children:_jsx(_components.p,{children:`API key for Chroma Cloud.`})}),`\n`,_jsx(ParamField,{path:`settings`,type:`Optional[Settings]`,id:`param-settings-4`,children:_jsx(_components.p,{children:`Optional settings to override defaults.`})}),`\n`,_jsx(ParamField,{path:`cloud_host`,type:`str`,id:`param-cloud-host`}),`\n`,_jsx(ParamField,{path:`cloud_port`,type:`int`,id:`param-cloud-port`}),`\n`,_jsx(ParamField,{path:`enable_ssl`,type:`bool`,id:`param-enable-ssl`}),`\n`,_jsx(Heading,{level:`3`,id:`adminclient`,children:`AdminClient`}),`\n`,_jsx(_components.p,{children:`Create an admin client for tenant and database management.`}),`\n`,_jsx(ParamField,{path:`settings`,type:`Settings`,id:`param-settings-5`}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`client-methods`,children:`Client Methods`}),`\n`,_jsx(Heading,{level:`3`,id:`heartbeat`,children:`heartbeat`}),`\n`,_jsx(_components.p,{children:`Get the current time in nanoseconds since epoch.`}),`\n`,_jsx(_components.p,{children:`Used to check if the server is alive.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The current time in nanoseconds since epoch`]}),`\n`,_jsx(Heading,{level:`3`,id:`list_collections`,children:`list_collections`}),`\n`,_jsx(_components.p,{children:`List all collections.`}),`\n`,_jsx(ParamField,{path:`limit`,type:`Optional[int]`,id:`param-limit`,children:_jsx(_components.p,{children:`The maximum number of entries to return. Defaults to None.`})}),`\n`,_jsx(ParamField,{path:`offset`,type:`Optional[int]`,id:`param-offset`,children:_jsx(_components.p,{children:`The number of entries to skip before returning. Defaults to None.`})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` A list of collections`]}),`\n`,_jsx(Heading,{level:`3`,id:`count_collections`,children:`count_collections`}),`\n`,_jsx(_components.p,{children:`Count the number of collections.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The number of collections.`]}),`\n`,_jsx(Heading,{level:`3`,id:`create_collection`,children:`create_collection`}),`\n`,_jsx(_components.p,{children:`Create a new collection with the given name and metadata.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name`,children:_jsx(_components.p,{children:`The name of the collection to create.`})}),`\n`,_jsx(ParamField,{path:`schema`,type:`Optional[Schema]`,id:`param-schema`}),`\n`,_jsx(ParamField,{path:`configuration`,type:`Optional[CreateCollectionConfiguration]`,id:`param-configuration`}),`\n`,_jsx(ParamField,{path:`metadata`,type:`Optional[Dict[str, Any]]`,id:`param-metadata`,children:_jsx(_components.p,{children:`Optional metadata to associate with the collection.`})}),`\n`,_jsx(ParamField,{path:`embedding_function`,type:`Optional[EmbeddingFunction[Optional[Embeddings]]]`,id:`param-embedding-function`,children:_jsx(_components.p,{children:`Optional function to use to embed documents.\nUses the default embedding function if not provided.`})}),`\n`,_jsx(ParamField,{path:`data_loader`,type:`Optional[DataLoader[Optional[Embeddings]]]`,id:`param-data-loader`,children:_jsx(_components.p,{children:`Optional function to use to load records (documents, images, etc.)`})}),`\n`,_jsx(ParamField,{path:`get_or_create`,type:`bool`,id:`param-get-or-create`,children:_jsx(_components.p,{children:`If True, return the existing collection if it exists.`})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The newly created collection.`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Raises:`})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`ValueError: If the collection already exists and get_or_create is False.`}),`\n`,_jsx(_components.li,{children:`ValueError: If the collection name is invalid.`}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`get_collection`,children:`get_collection`}),`\n`,_jsx(_components.p,{children:`Get a collection with the given name.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-1`,children:_jsx(_components.p,{children:`The name of the collection to get`})}),`\n`,_jsx(ParamField,{path:`embedding_function`,type:`Optional[EmbeddingFunction[Optional[Embeddings]]]`,id:`param-embedding-function-1`,children:_jsx(_components.p,{children:`Optional function to use to embed documents.\nUses the default embedding function if not provided.`})}),`\n`,_jsx(ParamField,{path:`data_loader`,type:`Optional[DataLoader[Optional[Embeddings]]]`,id:`param-data-loader-1`,children:_jsx(_components.p,{children:`Optional function to use to load records (documents, images, etc.)`})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The collection`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Raises:`})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`ValueError: If the collection does not exist`}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`get_or_create_collection`,children:`get_or_create_collection`}),`\n`,_jsx(_components.p,{children:`Get or create a collection with the given name and metadata.`}),`\n`,_jsx(_components.p,{children:`Args:\nname: The name of the collection to get or create\nmetadata: Optional metadata to associate with the collection. If\nthe collection already exists, the metadata provided is ignored.\nIf the collection does not exist, the new collection will be created\nwith the provided metadata.\nembedding_function: Optional function to use to embed documents\ndata_loader: Optional function to use to load records (documents, images, etc.)`}),`\n`,_jsx(_components.p,{children:`Returns:\nThe collection`}),`\n`,_jsx(_components.p,{children:`Examples:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`client.get_or_create_collection(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my_collection\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# collection(name=\"my_collection\", metadata={})`})}),`\n`]})})}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-2`}),`\n`,_jsx(ParamField,{path:`schema`,type:`Optional[Schema]`,id:`param-schema-1`}),`\n`,_jsx(ParamField,{path:`configuration`,type:`Optional[CreateCollectionConfiguration]`,id:`param-configuration-1`}),`\n`,_jsx(ParamField,{path:`metadata`,type:`Optional[Dict[str, Any]]`,id:`param-metadata-1`}),`\n`,_jsx(ParamField,{path:`embedding_function`,type:`Optional[EmbeddingFunction[Optional[Embeddings]]]`,id:`param-embedding-function-2`}),`\n`,_jsx(ParamField,{path:`data_loader`,type:`Optional[DataLoader[Optional[Embeddings]]]`,id:`param-data-loader-2`}),`\n`,_jsx(Heading,{level:`3`,id:`delete_collection`,children:`delete_collection`}),`\n`,_jsx(_components.p,{children:`Delete a collection with the given name.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-3`,children:_jsx(_components.p,{children:`The name of the collection to delete.`})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Raises:`})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`ValueError: If the collection does not exist.`}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`reset`,children:`reset`}),`\n`,_jsx(_components.p,{children:`Resets the database. This will delete all collections and entries.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` True if the database was reset successfully.`]}),`\n`,_jsx(Heading,{level:`3`,id:`get_version`,children:`get_version`}),`\n`,_jsx(_components.p,{children:`Get the version of Chroma.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The version of Chroma`]}),`\n`,_jsx(Heading,{level:`3`,id:`get_settings`,children:`get_settings`}),`\n`,_jsx(_components.p,{children:`Get the settings used to initialize.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Returns:`}),` The settings used to initialize.`]}),`\n`,_jsx(Heading,{level:`3`,id:`get_max_batch_size`,children:`get_max_batch_size`}),`\n`,_jsx(_components.p,{children:`Return the maximum number of records that can be created or mutated in a single call.`}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`admin-client-methods`,children:`Admin Client Methods`}),`\n`,_jsx(Heading,{level:`3`,id:`create_tenant`,children:`create_tenant`}),`\n`,_jsx(_components.p,{children:`Create a new tenant. Raises an error if the tenant already exists.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-4`}),`\n`,_jsx(Heading,{level:`3`,id:`get_tenant`,children:`get_tenant`}),`\n`,_jsx(_components.p,{children:`Get a tenant. Raises an error if the tenant does not exist.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-5`}),`\n`,_jsx(Heading,{level:`3`,id:`create_database`,children:`create_database`}),`\n`,_jsx(_components.p,{children:`Create a new database. Raises an error if the database already exists.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-6`}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-5`}),`\n`,_jsx(Heading,{level:`3`,id:`get_database`,children:`get_database`}),`\n`,_jsx(_components.p,{children:`Get a database. Raises an error if the database does not exist.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-7`}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-6`,children:_jsx(_components.p,{children:`The tenant of the database to get.`})}),`\n`,_jsx(Heading,{level:`3`,id:`delete_database`,children:`delete_database`}),`\n`,_jsx(_components.p,{children:`Delete a database. Raises an error if the database does not exist.`}),`\n`,_jsx(ParamField,{path:`name`,type:`str`,required:true,id:`param-name-8`}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-7`,children:_jsx(_components.p,{children:`The tenant of the database to delete.`})}),`\n`,_jsx(Heading,{level:`3`,id:`list_databases`,children:`list_databases`}),`\n`,_jsx(_components.p,{children:`List all databases for a tenant. Raises an error if the tenant does not exist.`}),`\n`,_jsx(ParamField,{path:`limit`,type:`Optional[int]`,id:`param-limit-1`}),`\n`,_jsx(ParamField,{path:`offset`,type:`Optional[int]`,id:`param-offset-1`}),`\n`,_jsx(ParamField,{path:`tenant`,type:`str`,id:`param-tenant-8`,children:_jsx(_components.p,{children:`The tenant to list databases for.`})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Client","description":null,"href":"/reference/python/client"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Clients","slug":"clients","depth":2,"children":[{"title":"EphemeralClient","slug":"ephemeralclient","depth":3,"children":[]},{"title":"PersistentClient","slug":"persistentclient","depth":3,"children":[]},{"title":"HttpClient","slug":"httpclient","depth":3,"children":[]},{"title":"AsyncHttpClient","slug":"asynchttpclient","depth":3,"children":[]},{"title":"CloudClient","slug":"cloudclient","depth":3,"children":[]},{"title":"AdminClient","slug":"adminclient","depth":3,"children":[]}]},{"title":"Client Methods","slug":"client-methods","depth":2,"children":[{"title":"heartbeat","slug":"heartbeat","depth":3,"children":[]},{"title":"list_collections","slug":"list_collections","depth":3,"children":[]},{"title":"count_collections","slug":"count_collections","depth":3,"children":[]},{"title":"create_collection","slug":"create_collection","depth":3,"children":[]},{"title":"get_collection","slug":"get_collection","depth":3,"children":[]},{"title":"get_or_create_collection","slug":"get_or_create_collection","depth":3,"children":[]},{"title":"delete_collection","slug":"delete_collection","depth":3,"children":[]},{"title":"reset","slug":"reset","depth":3,"children":[]},{"title":"get_version","slug":"get_version","depth":3,"children":[]},{"title":"get_settings","slug":"get_settings","depth":3,"children":[]},{"title":"get_max_batch_size","slug":"get_max_batch_size","depth":3,"children":[]}]},{"title":"Admin Client Methods","slug":"admin-client-methods","depth":2,"children":[{"title":"create_tenant","slug":"create_tenant","depth":3,"children":[]},{"title":"get_tenant","slug":"get_tenant","depth":3,"children":[]},{"title":"create_database","slug":"create_database","depth":3,"children":[]},{"title":"get_database","slug":"get_database","depth":3,"children":[]},{"title":"delete_database","slug":"delete_database","depth":3,"children":[]},{"title":"list_databases","slug":"list_databases","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":[],"subdomain":"chroma-8943dec5","siteName":"Chroma Docs","title":"Client - Chroma Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-10-09T18:51:33.905Z","originalFileLocation":"reference/python/client.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"application-name\" content=\"Chroma Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Client - Chroma Docs\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Chroma Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.trychroma.com/reference/python/client\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://chroma-8943dec5.mintlify.site/_mintlify/api/og/v2?division=Python\u0026amp;title=Client\u0026amp;theme=d07ad52d696ec9dcc96b1828\u0026amp;signature=110df5ce649c3d6bda5c23ba283a8d2c1cf76144a41013c847a0949db3dbf8f0\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Client - Chroma Docs\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://chroma-8943dec5.mintlify.site/_mintlify/api/og/v2?division=Python\u0026amp;title=Client\u0026amp;theme=d07ad52d696ec9dcc96b1828\u0026amp;signature=110df5ce649c3d6bda5c23ba283a8d2c1cf76144a41013c847a0949db3dbf8f0\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/chroma-8943dec5/DnUzSTuBJGyCs29f/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Chroma Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#ff6446\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.trychroma.com/reference/python/client\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/reference/python/client.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.trychroma.com/#organization\",\"name\":\"Chroma Docs\",\"url\":\"https://docs.trychroma.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/chroma-8943dec5/zDKM3GBjHr8r61ad/images/light-logo.svg?fit=max\u0026auto=format\u0026n=zDKM3GBjHr8r61ad\u0026q=85\u0026s=d487d229a3d00bed252f4728417390fe\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.trychroma.com#website\",\"name\":\"Chroma Docs\",\"url\":\"https://docs.trychroma.com\",\"publisher\":{\"@id\":\"https://docs.trychroma.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.trychroma.com/reference/python/client#webpage\",\"url\":\"https://docs.trychroma.com/reference/python/client\",\"name\":\"Client\",\"dateModified\":\"2026-10-09T18:51:33.905Z\",\"isPartOf\":{\"@id\":\"https://docs.trychroma.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.trychroma.com/reference/python/client#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.trychroma.com/reference/python/client#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Chroma Docs\",\"item\":\"https://docs.trychroma.com\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Client\",\"item\":\"https://docs.trychroma.com/reference/python/client\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.trychroma.com/reference/python/client#article\",\"headline\":\"Client\",\"name\":\"Client\",\"url\":\"https://docs.trychroma.com/reference/python/client\",\"mainEntityOfPage\":{\"@id\":\"https://docs.trychroma.com/reference/python/client#webpage\"},\"dateModified\":\"2026-10-09T18:51:33.905Z\",\"publisher\":{\"@id\":\"https://docs.trychroma.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.trychroma.com#website\"}}]}\u003c/script>","agentPointerHref":"/reference/python/client.md","siteName":"Chroma Docs","nav":{"global":null,"tabs":[{"tab":"Docs","icon":"book","pages":[{"title":"Docs","href":"/docs/overview/introduction"}]},{"tab":"Chroma Cloud","icon":"cloud","pages":[{"title":"Chroma Cloud","href":"/cloud/getting-started"}]},{"tab":"Guides","icon":"map","pages":[{"title":"Guides","href":"/guides/build/building-with-ai"}]},{"tab":"Integrations","icon":"code-merge","pages":[{"title":"Integrations","href":"/integrations/chroma-integrations"}]},{"tab":"Reference","icon":"code","pages":[{"title":"Overview","href":"/reference/overview"},{"group":"Self-Hosted Chroma","pages":[{"title":"Chroma Configuration","description":"Environment variables when self-hosting a Chroma server.","href":"/reference/server-env-vars"}]},{"group":"SDKs","pages":[{"group":"Python","pages":[{"title":"Client","href":"/reference/python/client"},{"title":"Collection","description":null,"href":"/reference/python/collection"},{"title":"Embedding Functions","href":"/reference/python/embedding-functions"},{"title":"Search","href":"/reference/python/search"},{"title":"Schema","href":"/reference/python/schema"},{"title":"Where Filters","href":"/reference/python/where-filter"}]},{"group":"TypeScript","pages":[{"title":"Client","href":"/reference/typescript/client"},{"title":"Collection","href":"/reference/typescript/collection"},{"title":"Embedding Functions","href":"/reference/typescript/embedding-functions"},{"title":"Search","href":"/reference/typescript/search"},{"title":"Schema","href":"/reference/typescript/schema"},{"title":"Where Filters","href":"/reference/typescript/where-filter"}]},{"title":"Rust","url":"https://docs.rs/chroma/latest/chroma/","href":"/reference/rust"}]},{"group":"Beta SDKs","pages":[{"title":"Kotlin","url":"https://github.com/chroma-core/chroma-android","href":"/reference/kotlin"},{"title":"Swift","url":"https://github.com/chroma-core/chroma-swift","href":"/reference/swift"}]},{"group":"APIs","pages":[{"group":"Chroma Core API","pages":[{"group":"Tenant","pages":[{"title":"Create tenant","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants","href":"/reference/chroma-api/tenant/create-tenant"},{"title":"Get tenant","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant_name}","href":"/reference/chroma-api/tenant/get-tenant"},{"title":"Update tenant","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json patch /api/v2/tenants/{tenant_name}","href":"/reference/chroma-api/tenant/update-tenant"}]},{"group":"Database","pages":[{"title":"List databases","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases","href":"/reference/chroma-api/database/list-databases"},{"title":"Create database","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases","href":"/reference/chroma-api/database/create-database"},{"title":"Get database","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}","href":"/reference/chroma-api/database/get-database"},{"title":"Delete database","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json delete /api/v2/tenants/{tenant}/databases/{database}","href":"/reference/chroma-api/database/delete-database"}]},{"group":"Collection","pages":[{"title":"List collections","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections","href":"/reference/chroma-api/collection/list-collections"},{"title":"Get number of collections","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections_count","href":"/reference/chroma-api/collection/get-number-of-collections"},{"title":"Create collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections","href":"/reference/chroma-api/collection/create-collection"},{"title":"Get collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}","href":"/reference/chroma-api/collection/get-collection"},{"title":"Update collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json put /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}","href":"/reference/chroma-api/collection/update-collection"},{"title":"Delete collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json delete /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}","href":"/reference/chroma-api/collection/delete-collection"}]},{"group":"Record","pages":[{"title":"Add records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/add","href":"/reference/chroma-api/record/add-records"},{"title":"Get number of records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/count","href":"/reference/chroma-api/record/get-number-of-records"},{"title":"Delete records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/delete","href":"/reference/chroma-api/record/delete-records"},{"title":"Get indexing status","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/indexing_status","href":"/reference/chroma-api/record/get-indexing-status"},{"title":"Get records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/get","href":"/reference/chroma-api/record/get-records"},{"title":"Query collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/query","href":"/reference/chroma-api/record/query-collection"},{"title":"Search records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/search","href":"/reference/chroma-api/record/search-records"},{"title":"Update records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/update","href":"/reference/chroma-api/record/update-records"},{"title":"Upsert records","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/upsert","href":"/reference/chroma-api/record/upsert-records"}]},{"group":"System","pages":[{"title":"Healthcheck","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/healthcheck","href":"/reference/chroma-api/system/healthcheck"},{"title":"Heartbeat","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/heartbeat","href":"/reference/chroma-api/system/heartbeat"},{"title":"Pre-flight checks","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/pre-flight-checks","href":"/reference/chroma-api/system/pre-flight-checks"},{"title":"Get version","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/version","href":"/reference/chroma-api/system/get-version"}]},{"group":"Authentication","pages":[{"title":"Get user identity","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/auth/identity","href":"/reference/chroma-api/authentication/get-user-identity"}]}]},{"group":"Chroma Cloud API","pages":[{"group":"Collection","pages":[{"title":"Fork collection","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/fork","href":"/api-reference/collection/fork-collection"}]},{"group":"Function","pages":[{"title":"Attach function","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/functions/attach","href":"/api-reference/function/attach-function"},{"title":"Get attached function","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json get /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/functions/{function_name}","href":"/api-reference/function/get-attached-function"},{"title":"Detach function","deprecated":null,"version":null,"openapi":"https://api.trychroma.com/openapi.json post /api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/attached_functions/{name}/detach","href":"/api-reference/function/detach-function"}]}]},{"group":"Chroma Sync API","pages":[{"group":"Invocation","pages":[{"title":"List invocations","deprecated":null,"version":null,"openapi":"/sync.openapi.json get /api/v1/invocations","href":"/reference/sync-api/invocation/list-invocations"},{"title":"Get invocation","deprecated":null,"version":null,"openapi":"/sync.openapi.json get /api/v1/invocations/{invocation_id}","href":"/reference/sync-api/invocation/get-invocation"},{"title":"Cancel invocation","deprecated":null,"version":null,"openapi":"/sync.openapi.json put /api/v1/invocations/{invocation_id}","href":"/reference/sync-api/invocation/cancel-invocation"},{"title":"Create invocation","deprecated":null,"version":null,"openapi":"/sync.openapi.json post /api/v1/sources/{source_id}/invocations","href":"/reference/sync-api/invocation/create-invocation"},{"title":"Get latest invocations by keys","deprecated":null,"version":null,"openapi":"/sync.openapi.json post /api/v1/sources/{source_id}/invocations/latest-by-keys","href":"/reference/sync-api/invocation/get-latest-invocations-by-keys"}]},{"group":"Source","pages":[{"title":"List sources","deprecated":null,"version":null,"openapi":"/sync.openapi.json get /api/v1/sources","href":"/reference/sync-api/source/list-sources"},{"title":"Create source","deprecated":null,"version":null,"openapi":"/sync.openapi.json post /api/v1/sources","href":"/reference/sync-api/source/create-source"},{"title":"Get source","deprecated":null,"version":null,"openapi":"/sync.openapi.json get /api/v1/sources/{source_id}","href":"/reference/sync-api/source/get-source"},{"title":"Delete source","deprecated":null,"version":null,"openapi":"/sync.openapi.json delete /api/v1/sources/{source_id}","href":"/reference/sync-api/source/delete-source"}]},{"group":"System","pages":[{"title":"Get service health status","deprecated":null,"version":null,"openapi":"/sync.openapi.json get /health","href":"/reference/sync-api/system/get-service-health-status"}]},{"group":"File Upload","pages":[{"title":"Upload and index a file","deprecated":null,"version":null,"openapi":"/sync.openapi.json post /api/v1/add-file","href":"/reference/sync-api/file-upload/upload-and-index-a-file"}]}]},{"group":"Chroma Cloud Embeddings API","pages":[{"title":"Generate dense embeddings","deprecated":null,"version":null,"openapi":"https://embed.trychroma.com/openapi.json post /embed","href":"/reference/embeddings-api/generate-dense-embeddings"},{"title":"Generate sparse embeddings","deprecated":null,"version":null,"openapi":"https://embed.trychroma.com/openapi.json post /embed_sparse","href":"/reference/embeddings-api/generate-sparse-embeddings"}]}]},{"group":"Dictionary Syntax","pages":[{"title":"Search","href":"/reference/search"},{"title":"Where Filters","href":"/reference/where-filter"}]},{"group":"Architecture","pages":[{"title":"Architecture Overview","href":"/reference/architecture/overview"},{"title":"Distributed Architecture","href":"/reference/architecture/distributed"}]}]}]},"basePath":"","title":"Client - Chroma Docs","deploymentId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","buildId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","dynamics":[],"chunks":[]}