Beta
Directories

Create Directory

Create a new directory within the specified project.

post/api/v1/beta/directories

Query parameters

project_idstring uuid nullable
organization_idstring uuid nullable

Cookies

sessionstring nullable

Request body

namestring required

Human-readable name for the directory.

descriptionstring nullable

Optional description shown to users.

type'user' | 'ephemeral'

Directory type. Use 'ephemeral' for batch processing with automatic cleanup.

expires_atstring date-time nullable

When this directory expires. Required for ephemeral directories.

system_metadataobject nullable

Reserved system-managed metadata.

Example request

{
  "type": "user",
  "expires_at": "2026-05-10T00:00:00Z"
}

Response

Successful Response

idstring required

Unique identifier for the directory.

created_atstring date-time nullable

Creation datetime

updated_atstring date-time nullable

Update datetime

project_idstring required

Project the directory belongs to.

namestring required

Human-readable name for the directory.

descriptionstring nullable

Optional description shown to users.

type'user' | 'index' | 'ephemeral' | 'system_ephemeral' nullable

Directory type: 'user', 'index', 'ephemeral', or 'system_ephemeral'.

expires_atstring date-time nullable

When this directory expires and is eligible for cleanup.

system_metadataobject nullable

Reserved system-managed metadata.

deleted_atstring date-time nullable

Optional timestamp of when the directory was deleted. Null if not deleted.

Changes

Changed in 7 of the 33 revisions of this API.612

    • added the optional property detail/items/ctx to the response with the 422 status

      response-optional-property-added

    • added the optional property detail/items/input to the response with the 422 status

      response-optional-property-added

    This revision also has 5 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • added the new optional request property expires_at

      new-optional-request-property

    • added the new optional request property system_metadata

      new-optional-request-property

    • added the new optional request property type

      new-optional-request-property

    • added the optional property expires_at to the response with the 201 status

      response-optional-property-added

    • added the optional property system_metadata to the response with the 201 status

      response-optional-property-added

    • added the optional property type to the response with the 201 status

      response-optional-property-added

    This revision also has 2 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • removed the request property data_source_id

      request-property-removed

    • removed the optional property data_source_id from the response with the 201 status

      response-optional-property-removed

    • added the new optional request property data_source_id

      new-optional-request-property

    • added the optional property data_source_id to the response with the 201 status

      response-optional-property-added

    This revision also has 46 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • removed the request property data_source_id

      request-property-removed

    • removed the optional property data_source_id from the response with the 201 status

      response-optional-property-removed

    • added the new optional request property data_source_id

      new-optional-request-property

    • added the optional property data_source_id to the response with the 201 status

      response-optional-property-added

    This revision also has 6 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • removed the request property data_source_id

      request-property-removed

    • removed the optional property data_source_id from the response with the 201 status

      response-optional-property-removed