Skip to main content
POST
/
create-datastore
Create Datastore
curl --request POST \
  --url https://api.agentbase.sh/create-datastore \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "<string>",
  "type": "<string>"
}'
{
  "datastore_id": "<string>",
  "name": "<string>",
  "type": "<string>",
  "created_at": "<string>"
}

Body Parameters

name
string
required
The name of the datastore. This helps you identify and organize your data.
type
string
required
The type of datastore to create. Supported values:
  • database - For structured database content
  • documents - For document files

Response

Returns the created datastore information including the datastore ID.
{
  "datastore_id": "ds_1234567890abcdef",
  "name": "My Documents",
  "type": "documents",
  "created_at": "2025-10-01T12:00:00Z"
}

Response Fields

datastore_id
string
The unique identifier for the created datastore. Use this ID when indexing documents.
name
string
The name of the datastore
type
string
The type of datastore (database or documents)
created_at
string
Timestamp of when the datastore was created