Skip to main content
POST
/
embeddings
/
create_tenant
Create Embeddings Collection
curl --request POST \
  --url https://api.usecortex.ai/embeddings/create_tenant \
  --header 'Authorization: Bearer <token>'
{
  "tenant_id": "tenant_1234",
  "sub_tenant_id": "sub_tenant_4567",
  "success": true,
  "message": "Embeddings collection created successfully"
}
Hit the Try it button to try this API now in our playground. It’s the best way to check the full request and response in one place, customize your parameters, and generate ready-to-use code snippets.

Sample Request

curl --location --request POST 'https://api.usecortex.ai/embeddings/create_tenant?tenant_id={TENANT_ID}' \
  --header 'Authorization: Bearer {API_KEY}' \
  --header 'accept: application/json'
Create a tenant dedicated to directly storing and querying embeddings.
Use this API only if you plan to upload embeddings directly (via /upload/upload_embeddings) and query them (via /embeddings/*). For standard document, text/markdown, or webpage ingestion, use /user/create_tenant instead.

Query Parameters

  • tenant_id: Required string — The tenant identifier.

Sample Response

{
  "status": "success",
  "message": "Tenant 'embeddings_test' created successfully.",
  "tenant_id": "embeddings_test",
}

Error Responses

All endpoints return consistent error responses following the standard format. For detailed error information, see our Error Responses documentation.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

tenant_id
string
required

Unique identifier for the tenant/organization

Example:

"tenant_1234"

Response

Successful Response

tenant_id
string
required

Identifier for the tenant/organization

Example:

"tenant_1234"

sub_tenant_id
string
required

Identifier for the sub-tenant within the tenant

Example:

"sub_tenant_4567"

success
boolean
default:true

Indicates whether the embeddings tenant creation completed successfully

Example:

true

message
string
default:Embeddings collection created successfully

Status message about the tenant creation operation

I