Index Management
Create and manage indexes for full-text search, vector similarity search, and multimodal content.
Index Types
Antfly supports two primary index types:
full_text - Full-Text Search Index
BM25-based full-text search using Antfly's native Zig full-text index (a segmented, Lucene-style inverted index). Automatically uses schema information for field mappings.
Configuration:
{
"type": "full_text",
"name": "search_idx",
"mem_only": false
}
Options:
mem_only(optional): If true, stores index in memory only (useful for testing)
Features:
- BM25 ranking algorithm
- Field-specific queries (
title:computer) - Boolean operators (
AND,OR,NOT) - Range queries (
year:>2020) - Phrase queries (
"exact phrase") - Uses schema's
x-antfly-typesfor field analyzers - Respects
x-antfly-include-in-allfor cross-field search
embeddings - Vector Similarity Index
Approximate k-nearest neighbors (AKNN) index for semantic similarity search using vector embeddings.
Performance Features:
- Hardware-accelerated distance calculations using SIMD instructions
- x86/AMD: AVX2 and AVX-512 optimizations for vector operations
- ARM: NEON and SME (Scalable Matrix Extension) acceleration
- RaBitQ quantization for reduced memory footprint and faster search
- No GPU required - optimized for CPU-based deployments
Basic Configuration:
{
"type": "embeddings",
"name": "embedding_idx",
"field": "description",
"embedder": {
"provider": "ollama",
"model": "all-minilm",
"url": "http://localhost:11434"
}
}
Index Modes:
Managed indexes (external: false, default)
- Antfly owns embedding generation
- Must specify
fieldortemplate - Must specify
embedder - Reject manual
_embeddingswrites for that index
External indexes (external: true)
- Your application owns embedding generation
- Must not specify
field,template, orembedder - Dense external indexes must specify
dimension - Vectors are written directly through the document
_embeddingsfield
Managed Index Fields:
field: Field to embed using JSONPath syntax (e.g.,"description","metadata.content","$.user.bio")template: Handlebars template for custom prompt generationembedder: Embedder configuration for generating vectorsdimension: Optional for dense indexes; inferred from the embedder if omittedmem_only: Store index in memory only
External Index Fields:
external: truedimension: Required for dense indexessparse: true: Use sparse vectors supplied through_embeddings
External Dense Example:
{
"type": "embeddings",
"name": "manual_dense_idx",
"external": true,
"dimension": 384
}
External Sparse Example:
{
"type": "embeddings",
"name": "manual_sparse_idx",
"external": true,
"sparse": true
}
Writing Manual Embeddings:
- Manual
_embeddingswrites are only accepted forexternal: trueindexes - Dense vectors use arrays:
"_embeddings": { "manual_dense_idx": [0.1, 0.2, 0.3] } - Sparse vectors use token-weight maps:
"_embeddings": { "manual_sparse_idx": { "7": 1.5, "42": 2.0 } } - Explicit delete uses
null:"_embeddings": { "manual_dense_idx": null } - Omitting
_embeddings[<index>]is a no-op; it does not delete the stored vector
Embedder Providers
Managed index creation supports antfly, ollama, openai, and bedrock
through the purpose-specific IndexEmbedderConfig. Other providers in the
broader EmbedderConfig are available only on surfaces whose runtime can
execute them.
Antfly Inference
{
"provider": "antfly",
"model": "BAAI/bge-small-en-v1.5"
}
Ollama (Local Models)
{
"provider": "ollama",
"model": "all-minilm",
"url": "http://localhost:11434"
}
Popular models: all-minilm, nomic-embed-text, mxbai-embed-large
OpenAI
{
"provider": "openai",
"model": "text-embedding-3-small",
"api_key": "sk-..."
}
Models: text-embedding-3-small (1536d), text-embedding-3-large (3072d), text-embedding-ada-002 (1536d)
AWS Bedrock
{
"provider": "bedrock",
"model": "amazon.titan-embed-text-v1",
"region": "us-east-1"
}
Models: amazon.titan-embed-text-v1, amazon.titan-embed-text-v2, cohere.embed-english-v3, cohere.embed-multilingual-v3
Multimodal Indexing
EmbeddingsIndexConfig does not accept a summarizer. For two-stage
multimodal indexing, generate a textual description into a document field
before indexing and configure the managed index against that field. If the
application already owns the final vectors, use an external: true index
and write them through _embeddings.
Template-Based Prompts
Customize how documents are converted to text before embedding using Handlebars templates:
{
"type": "embeddings",
"dimension": 384,
"field": "description",
"template": "Product: {{title}}\nCategory: {{category}}\nDescription: {{description}}",
"embedder": {
"provider": "ollama",
"model": "all-minilm"
}
}
Template System:
- Syntax: Handlebars templating (https://handlebarsjs.com/guide/)
- Caching: Templates are automatically cached with configurable TTL (default: 5 minutes)
- Context: Templates receive the full document as context
Basic Syntax:
{{fieldName}}: Insert field value{{#if field}}...{{/if}}: Conditional logic{{#each array}}...{{/each}}: Iterate arrays{{#unless condition}}...{{/unless}}: Inverse conditional{{@index}},{{@key}},{{@first}},{{@last}}: Loop variables
Built-in Helpers:
-
scrubHtml - Remove script/style tags and extract clean text from HTML
- Removes
<script>and<style>tags - Adds newlines after block elements (p, div, h1-h6, li, etc.)
- Returns plain text with preserved readability
- Removes
-
eq - Equality comparison for conditionals
Active Special field -
media - GenKit dotprompt media directive for multimodal content
Supported URL Schemes:
data:- Base64 encoded data URIs (e.g.,data:image/jpeg;base64,...)http:///https://- Web URLs with automatic content type detectionfile://- Local filesystem pathss3://- S3-compatible storage (format:s3://endpoint/bucket/key)
Automatic Content Processing:
- Images: Downloaded, resized (if needed), converted to data URIs
- PDFs: Text extracted or first page rendered as image
- HTML: Readable text extracted using Mozilla Readability
Security Controls: Downloads are protected by content security settings:
- Allowed host whitelist
- Private IP blocking (prevents SSRF attacks)
- Download size limits (default: 100MB)
- HTTP downloads time out after 30 seconds by default; zero disables the deadline
- Image dimension limits (default: 2048px, auto-resized)
-
encodeToon is not available in these templates. It is a helper of the retrieval agent's
document_renderer, which renders documents into the generation prompt as TOON by default.
Without a template, the field value is used directly, or the entire document is serialized.
Field Extraction with JSONPath
The field parameter supports JSONPath syntax for extracting values from nested document structures:
{
"type": "embeddings",
"field": "metadata.description",
"embedder": {"provider": "ollama", "model": "all-minilm"}
}
JSONPath Examples:
"title"- Top-level field"user.bio"- Nested field (auto-prepends$.if not present)"$.metadata.content"- Explicit JSONPath"$.items[0].name"- Array indexing
The extracted value must be a string. Use template for complex transformations or combining multiple fields.
Configuration Examples
Simple Text Embedding
{
"type": "embeddings",
"field": "content",
"embedder": {
"provider": "ollama",
"model": "all-minilm"
}
}
Note: dimension is omitted and will be inferred from the all-minilm model (384).
Text Embedding with Custom Template
{
"type": "embeddings",
"dimension": 1536,
"template": "{{title}}: {{description}}",
"embedder": {
"provider": "openai",
"model": "text-embedding-3-small"
}
}
Production OpenAI Setup
{
"type": "embeddings",
"dimension": 1536,
"field": "body",
"embedder": {
"provider": "openai",
"model": "text-embedding-3-small",
"api_key": "${OPENAI_API_KEY}"
}
}
Best Practices
- Choose dimension wisely: Higher dimensions improve accuracy but increase storage/compute costs
- Use templates for structured data: Combine multiple fields into meaningful prompts
- Local vs Cloud: Ollama for development/privacy, cloud providers for production/scale
- Field specification: Specify
fieldwhen embedding a single field to avoid whole-document serialization
Implementing Autocomplete Search
To implement autocomplete/search-as-you-type functionality:
1. Define schema with search_as_you_type type:
{
"document_schemas": {
"product": {
"schema": {
"type": "object",
"properties": {
"name": {
"type": "string",
"x-antfly-types": ["text", "search_as_you_type"]
}
}
}
}
}
}
2. Create full-text index:
{
"indexes": {
"search_idx": {
"type": "full_text"
}
}
}
3. Query with bool-prefix multi-match:
{
"full_text_search": {
"multi_match": {
"query": "lap",
"type": "bool_prefix",
"fields": ["name"]
}
}
}
The search_as_you_type type creates shingle and prefix subfields that match partial input
as users type. For example, "lap" matches "laptop", "lapel", etc.
Reindexing Data
What happens when you need to reindex? Antfly handles reindexing through async enrichment, automatically rebuilding indexes in the background. Here's what to expect when reindexing data (after adding a new index or changing configuration):
Adding a New Index to Existing Table
Antfly handles reindexing automatically through async enrichment:
1. Add the index:
POST /tables/{tableName}/indexes/{indexName}
{
"type": "embeddings",
"embedder": {...}
}
2. Enrichment happens automatically:
- Existing documents are enriched in the background
- New writes are enriched immediately
- Leader-only processing prevents duplicate work
- Check index status to monitor progress
3. Monitor progress:
GET /tables/{tableName}/indexes/{indexName}
Look at shard_status for enrichment progress per shard.
Error Handling for Async Enrichment
When embedding generation or enrichment fails, Antfly handles errors gracefully:
Retry Behavior:
- Failed enrichments are automatically retried with exponential backoff
- Leader-only processing ensures no duplicate work during retries
- Enrichment continues for other documents even if some fail
Monitoring Failures:
- Check index status (
GET /tables/{table}/indexes/{index}) for error counts - Prometheus metrics expose enrichment failure rates
- Failed documents remain searchable via full-text index (if configured)
Common Failure Scenarios:
-
Embedding API Unavailable
- Enrichment retries automatically when service recovers
- Documents remain indexed (without embeddings) for full-text search
- Use
sync_level: enrichmentsto precompute enrichments before committing. A synchronous producer failure rejects the write. Failures detected after a document has committed retain it and may reportcommitted_repair_requiredso operators can repair the derived state.
-
Rate Limiting
- Automatic backoff and retry
- Consider using local Ollama to avoid rate limits
- Or increase API quota with embedding provider
-
Model Errors (invalid input, size limits)
- Logged with document ID for investigation
- Retries stop after max attempts
- Document remains in table without enrichment
Changing Index Configuration
To change index configuration:
- Drop the existing index:
DELETE /tables/{table}/indexes/{index} - Recreate with new config:
POST /tables/{table}/indexes/{index} - Existing data is automatically re-enriched
Note: Full-text indexes (full_text) reindex immediately on creation and automatically
rebuild when schema changes are made. Vector indexes (embeddings) enrich asynchronously in the background.
Backup Before Major Reindexing
For large datasets, backup before reindexing:
POST /tables/{tableName}/backup
{
"backup_id": "before-reindex-2025-01",
"location": "s3://mybucket/backups/products"
}
Graph Indexes and Edge TTL
Graph indexes (graph) enable relationship modeling and traversal queries.
Edge TTL is under development. The stateful runtime currently stamps edge
artifacts and selects live projected contributors for adjacency reads, but
authoritative cleanup, metric invalidation, and
serverless visibility are not complete. Do not rely on graph TTL in
production until those pieces are implemented.
Graph Index Overview
Graph indexes store directed edges between documents, enabling queries like:
- Finding all connections from a document
- Traversing multi-hop paths
- Filtering relationships by type
Basic graph index:
{
"type": "graph",
"name": "social_graph"
}
Edge TTL Configuration
Graph indexes accept an index-level ttl.duration policy. The legacy
ttl_duration field is an alias; do not specify both.
{
"type": "graph",
"name": "recent_interactions",
"ttl": {"duration": "7d"}
}
The duration uses the same format as document TTL, such as 30s, 5m,
24h, or 7d. Each source contribution receives a server-assigned
creation timestamp. Stateful graph reads filter expired contributions
and select the highest-priority live source when sources overlap.
Graph TTL is currently incomplete. There is no authoritative edge
cleanup worker, published graph metric invalidation at a deadline, or
serverless segment expiration filter. See zig/GRAPH.md for the design
and current implementation status.
Execute a graph metric operational action
/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}Refresh, rebuild, delete, pause, or resume maintenance for a configured
graph metric. The metric configuration remains owned by the graph index.
Refresh and rebuild durably enqueue bounded, resumable maintenance and
return the aggregate shard status without waiting for graph-sized work.
delete clears materialized metric state and durably disables automatic
maintenance. A later refresh, rebuild, or resume action re-enables the
metric and can publish a new generation.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X POST "/db/v1/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post('/db/v1/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "/db/v1/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"status": {
"state": "string",
"phase": "idle",
"edge_filter": {
"mode": "all",
"types": [
"string"
]
},
"metadata_version": 0,
"config_fingerprint": "string",
"maintenance_paused": true,
"build_queued": true,
"published_generation": 0,
"edge_generation": 0,
"target_edge_generation": 0,
"queued_generation": 0,
"building_generation": 0,
"build_job_id": 0,
"build_started_at_ms": 0,
"build_iteration": 0,
"build_lease_expires_at_ms": 0,
"build_worker_id": "string",
"build_cursor": "string",
"build_completed_units": 0,
"build_total_units": 0,
"build_pages": [
{
"phase": "string",
"iteration": 0,
"page_id": 0,
"state": "pending",
"range_kind": "full",
"worker_id": "string",
"lease_expires_at_ms": 0,
"attempt": 0,
"cursor": "string",
"completed_units": 0,
"total_units": 0,
"last_error": "string"
}
],
"build_pages_truncated": true,
"retry_count": 0,
"last_error": "string",
"progress": 0,
"converged": true,
"iterations_completed": 0,
"delta": 0,
"computed_at_ms": 0,
"last_event": {
"sequence": 0,
"kind": "publish",
"at_ms": 0,
"target_edge_generation": 0,
"published_generation": 0,
"score_count": 0
},
"recent_events": [
{
"sequence": 0,
"kind": "publish",
"at_ms": 0,
"target_edge_generation": 0,
"published_generation": 0,
"score_count": 0
}
]
}
}{
"code": "string",
"error": "An error message",
"message": "string",
"retryable": true,
"retry_after_ms": 1
}{
"code": "string",
"error": "An error message",
"message": "string",
"retryable": true,
"retry_after_ms": 1
}Execute a graph metric operational action
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}Refresh, rebuild, delete, pause, or resume maintenance for a configured
graph metric. The metric configuration remains owned by the graph index.
Refresh and rebuild durably enqueue bounded, resumable maintenance and
return the aggregate shard status without waiting for graph-sized work.
delete clears materialized metric state and durably disables automatic
maintenance. A later refresh, rebuild, or resume action re-enables the
metric and can publish a new generation.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X POST "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/graph-metrics/{metricName}:{action}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"status": {
"state": "string",
"phase": "idle",
"edge_filter": {
"mode": "all",
"types": [
"string"
]
},
"metadata_version": 0,
"config_fingerprint": "string",
"maintenance_paused": true,
"build_queued": true,
"published_generation": 0,
"edge_generation": 0,
"target_edge_generation": 0,
"queued_generation": 0,
"building_generation": 0,
"build_job_id": 0,
"build_started_at_ms": 0,
"build_iteration": 0,
"build_lease_expires_at_ms": 0,
"build_worker_id": "string",
"build_cursor": "string",
"build_completed_units": 0,
"build_total_units": 0,
"build_pages": [
{
"phase": "string",
"iteration": 0,
"page_id": 0,
"state": "pending",
"range_kind": "full",
"worker_id": "string",
"lease_expires_at_ms": 0,
"attempt": 0,
"cursor": "string",
"completed_units": 0,
"total_units": 0,
"last_error": "string"
}
],
"build_pages_truncated": true,
"retry_count": 0,
"last_error": "string",
"progress": 0,
"converged": true,
"iterations_completed": 0,
"delta": 0,
"computed_at_ms": 0,
"last_event": {
"sequence": 0,
"kind": "publish",
"at_ms": 0,
"target_edge_generation": 0,
"published_generation": 0,
"score_count": 0
},
"recent_events": [
{
"sequence": 0,
"kind": "publish",
"at_ms": 0,
"target_edge_generation": 0,
"published_generation": 0,
"score_count": 0
}
]
}
}{
"code": "string",
"error": "An error message",
"message": "string",
"retryable": true,
"retry_after_ms": 1
}{
"code": "string",
"error": "An error message",
"message": "string",
"retryable": true,
"retry_after_ms": 1
}List table artifact enrichments
/tables/{tableName}/artifactsReturns table-level generated artifact enrichments configured for a table, including enrichments declared inline by indexes. This is the artifact control-plane view; use the document artifact routes to inspect materialized manifests for a specific source document.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X GET "/db/v1/tables/{tableName}/artifacts" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/artifacts', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/artifacts', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.get('/db/v1/tables/{tableName}/artifacts', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "/db/v1/tables/{tableName}/artifacts", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"table_name": "string",
"artifacts": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}Register or replace an artifact enrichment
/tables/{tableName}/artifacts/{artifactName}/enrichmentRegisters a table-level generated artifact definition. Reusing the same
artifact name replaces the existing mapping. Chunk or asset enrichments
may set full_text_index: true to map generated text into the table's
default full-text index.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
Code Examples
curl -X PUT "/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}'const response = await fetch('/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment', {
method: 'PUT',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
})
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment', {
method: 'PUT',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.put(
'/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment',
headers=headers,
json={
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}`)
req, _ := http.NewRequest("PUT", "/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{}Delete an artifact enrichment
/tables/{tableName}/artifacts/{artifactName}/enrichmentRemoves the table-level generated artifact definition. Local table reconciliation drops no-longer-desired enrichment registrations when it is safe to do so.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X DELETE "/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.delete('/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "/db/v1/tables/{tableName}/artifacts/{artifactName}/enrichment", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{}List all indexes for a table
/tables/{tableName}/indexesProvide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X GET "/db/v1/tables/{tableName}/indexes" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/indexes', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.get('/db/v1/tables/{tableName}/indexes', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "/db/v1/tables/{tableName}/indexes", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
[
{
"shard_status": {},
"config": {
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
},
"status": {
"index_type": "full_text",
"readiness": {
"state": "pending",
"queryable": true,
"complete": true,
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"pending_reasons": [
"load_failure"
],
"sources": [
{
"artifact": "string",
"state": "pending",
"complete": true,
"pending_reasons": [
"index_failed"
]
}
]
},
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"milestones": {
"queryable": {
"reached": true,
"blockers": [
"string"
]
},
"complete": {
"reached": true,
"blockers": [
"string"
]
}
},
"error": "string",
"total_indexed": 0,
"disk_usage": 0,
"rebuilding": true,
"repair": {
"state": "rebuilding",
"action_required": true,
"blocks_queryable": true,
"blocks_complete": true,
"reason": "string"
},
"backfill_active": true,
"backfill_progress": 0,
"backfill_items_processed": 0,
"backfill_state": "string",
"doc_count": 0,
"term_count": 0,
"replay_applied_sequence": 0,
"replay_target_sequence": 0,
"replay_catch_up_required": true,
"runtime_present": true,
"runtime_fresh": true,
"runtime_source": "string",
"runtime_freshness": "string",
"catch_up_active": true,
"catch_up_phase": "string",
"catch_up_applied_sequence": 0,
"catch_up_target_sequence": 0,
"text_merge": {},
"async_indexing": {},
"projection_checkpoint_status": "string",
"projection_checkpoint_applied_sequence": 0,
"projection_checkpoint_generation": 0,
"projection_checkpoint_config_fingerprint": "string",
"checkpoint_replay_tail_sequence_count": 0,
"repair_scan_issue_count": 0,
"edge_count": 0,
"node_count": 0,
"repair_degraded": true,
"repair_issue_count": 0,
"repair_summary_ready": true,
"repair_issue_count_estimated": true,
"expected_groups": 0,
"reported_groups": 0,
"fresh_groups": 0,
"stale_groups": 0,
"missing_groups": 0,
"unknown_remote_groups": 0,
"resolution": {},
"promotion": {}
}
}
]Retry a failed index build
/tables/{tableName}/indexes/{indexName}/retryGeneration-fenced relational index maintenance. Requires table ADMIN permission. Retry accepts failed generations. Owners are admitted independently and durably; exact request replay resumes after partial acknowledgements. Unsupported index types return 405.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
Code Examples
curl -X POST "/db/v1/tables/{tableName}/indexes/{indexName}/retry" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}'const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}/retry', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}/retry', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/tables/{tableName}/indexes/{indexName}/retry',
headers=headers,
json={
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/tables/{tableName}/indexes/{indexName}/retry", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"acknowledged_groups": [
"string"
]
}Repair an index generation
/tables/{tableName}/indexes/{indexName}/repairGeneration-fenced relational index maintenance. Requires table ADMIN permission. Repair accepts ready or failed generations and rebuilds their derived records. Owners are admitted independently and durably; exact request replay resumes after partial acknowledgements. Unsupported index types return 405.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
Code Examples
curl -X POST "/db/v1/tables/{tableName}/indexes/{indexName}/repair" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}'const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}/repair', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}/repair', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/tables/{tableName}/indexes/{indexName}/repair',
headers=headers,
json={
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/tables/{tableName}/indexes/{indexName}/repair", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"acknowledged_groups": [
"string"
]
}Add an index to a table
/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}
Code Examples
curl -X POST "/db/v1/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}'const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
})
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/tables/{tableName}/indexes/{indexName}',
headers=headers,
json={
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/tables/{tableName}/indexes/{indexName}", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
}{
"code": "string",
"error": "An error message",
"message": "string",
"retryable": true,
"retry_after_ms": 1
}Drop an index from a table
/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X DELETE "/db/v1/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.delete('/db/v1/tables/{tableName}/indexes/{indexName}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "/db/v1/tables/{tableName}/indexes/{indexName}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
Get index details
/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X GET "/db/v1/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/tables/{tableName}/indexes/{indexName}', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.get('/db/v1/tables/{tableName}/indexes/{indexName}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "/db/v1/tables/{tableName}/indexes/{indexName}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"shard_status": {},
"config": {
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
},
"status": {
"index_type": "full_text",
"readiness": {
"state": "pending",
"queryable": true,
"complete": true,
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"pending_reasons": [
"load_failure"
],
"sources": [
{
"artifact": "string",
"state": "pending",
"complete": true,
"pending_reasons": [
"index_failed"
]
}
]
},
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"milestones": {
"queryable": {
"reached": true,
"blockers": [
"string"
]
},
"complete": {
"reached": true,
"blockers": [
"string"
]
}
},
"error": "string",
"total_indexed": 0,
"disk_usage": 0,
"rebuilding": true,
"repair": {
"state": "rebuilding",
"action_required": true,
"blocks_queryable": true,
"blocks_complete": true,
"reason": "string"
},
"backfill_active": true,
"backfill_progress": 0,
"backfill_items_processed": 0,
"backfill_state": "string",
"doc_count": 0,
"term_count": 0,
"replay_applied_sequence": 0,
"replay_target_sequence": 0,
"replay_catch_up_required": true,
"runtime_present": true,
"runtime_fresh": true,
"runtime_source": "string",
"runtime_freshness": "string",
"catch_up_active": true,
"catch_up_phase": "string",
"catch_up_applied_sequence": 0,
"catch_up_target_sequence": 0,
"text_merge": {},
"async_indexing": {},
"projection_checkpoint_status": "string",
"projection_checkpoint_applied_sequence": 0,
"projection_checkpoint_generation": 0,
"projection_checkpoint_config_fingerprint": "string",
"checkpoint_replay_tail_sequence_count": 0,
"repair_scan_issue_count": 0,
"edge_count": 0,
"node_count": 0,
"repair_degraded": true,
"repair_issue_count": 0,
"repair_summary_ready": true,
"repair_issue_count_estimated": true,
"expected_groups": 0,
"reported_groups": 0,
"fresh_groups": 0,
"stale_groups": 0,
"missing_groups": 0,
"unknown_remote_groups": 0,
"resolution": {},
"promotion": {}
}
}List indexes for an explicit namespace table
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexesLists index metadata through an explicit database and namespace route.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X GET "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.get('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
[
{
"shard_status": {},
"config": {
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
},
"status": {
"index_type": "full_text",
"readiness": {
"state": "pending",
"queryable": true,
"complete": true,
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"pending_reasons": [
"load_failure"
],
"sources": [
{
"artifact": "string",
"state": "pending",
"complete": true,
"pending_reasons": [
"index_failed"
]
}
]
},
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"milestones": {
"queryable": {
"reached": true,
"blockers": [
"string"
]
},
"complete": {
"reached": true,
"blockers": [
"string"
]
}
},
"error": "string",
"total_indexed": 0,
"disk_usage": 0,
"rebuilding": true,
"repair": {
"state": "rebuilding",
"action_required": true,
"blocks_queryable": true,
"blocks_complete": true,
"reason": "string"
},
"backfill_active": true,
"backfill_progress": 0,
"backfill_items_processed": 0,
"backfill_state": "string",
"doc_count": 0,
"term_count": 0,
"replay_applied_sequence": 0,
"replay_target_sequence": 0,
"replay_catch_up_required": true,
"runtime_present": true,
"runtime_fresh": true,
"runtime_source": "string",
"runtime_freshness": "string",
"catch_up_active": true,
"catch_up_phase": "string",
"catch_up_applied_sequence": 0,
"catch_up_target_sequence": 0,
"text_merge": {},
"async_indexing": {},
"projection_checkpoint_status": "string",
"projection_checkpoint_applied_sequence": 0,
"projection_checkpoint_generation": 0,
"projection_checkpoint_config_fingerprint": "string",
"checkpoint_replay_tail_sequence_count": 0,
"repair_scan_issue_count": 0,
"edge_count": 0,
"node_count": 0,
"repair_degraded": true,
"repair_issue_count": 0,
"repair_summary_ready": true,
"repair_issue_count_estimated": true,
"expected_groups": 0,
"reported_groups": 0,
"fresh_groups": 0,
"stale_groups": 0,
"missing_groups": 0,
"unknown_remote_groups": 0,
"resolution": {},
"promotion": {}
}
}
]Get index details for an explicit namespace table
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X GET "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.get('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"shard_status": {},
"config": {
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
},
"status": {
"index_type": "full_text",
"readiness": {
"state": "pending",
"queryable": true,
"complete": true,
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"pending_reasons": [
"load_failure"
],
"sources": [
{
"artifact": "string",
"state": "pending",
"complete": true,
"pending_reasons": [
"index_failed"
]
}
]
},
"incarnation": "string",
"target_revision": 0,
"published_revision": 0,
"milestones": {
"queryable": {
"reached": true,
"blockers": [
"string"
]
},
"complete": {
"reached": true,
"blockers": [
"string"
]
}
},
"error": "string",
"total_indexed": 0,
"disk_usage": 0,
"rebuilding": true,
"repair": {
"state": "rebuilding",
"action_required": true,
"blocks_queryable": true,
"blocks_complete": true,
"reason": "string"
},
"backfill_active": true,
"backfill_progress": 0,
"backfill_items_processed": 0,
"backfill_state": "string",
"doc_count": 0,
"term_count": 0,
"replay_applied_sequence": 0,
"replay_target_sequence": 0,
"replay_catch_up_required": true,
"runtime_present": true,
"runtime_fresh": true,
"runtime_source": "string",
"runtime_freshness": "string",
"catch_up_active": true,
"catch_up_phase": "string",
"catch_up_applied_sequence": 0,
"catch_up_target_sequence": 0,
"text_merge": {},
"async_indexing": {},
"projection_checkpoint_status": "string",
"projection_checkpoint_applied_sequence": 0,
"projection_checkpoint_generation": 0,
"projection_checkpoint_config_fingerprint": "string",
"checkpoint_replay_tail_sequence_count": 0,
"repair_scan_issue_count": 0,
"edge_count": 0,
"node_count": 0,
"repair_degraded": true,
"repair_issue_count": 0,
"repair_summary_ready": true,
"repair_issue_count_estimated": true,
"expected_groups": 0,
"reported_groups": 0,
"fresh_groups": 0,
"stale_groups": 0,
"missing_groups": 0,
"unknown_remote_groups": 0,
"resolution": {},
"promotion": {}
}
}Add an index to an explicit namespace table
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}
Code Examples
curl -X POST "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}'const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
})
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}',
headers=headers,
json={
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"producer": {
"type": "copy",
"config": {
"generator": {
"provider": "openai",
"model": "gpt-4.1",
"temperature": 0.7,
"max_tokens": 2048
},
"instructions": "string",
"output_schema": {},
"output": "auto",
"batch": {
"max_items_per_call": 1,
"max_input_bytes": 1
}
}
},
"producer_json": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
},
"transcriber": {
"provider": "openai",
"model": "string",
"api_url": "https://example.com",
"base_url": "https://example.com",
"api_key": "string",
"project_id": "string",
"location": "string",
"credentials_path": "string",
"language_code": "string",
"timestamps": true,
"diarization": true,
"max_download_bytes": 1,
"download_assets": true
}
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"name": "string",
"description": "string",
"version": 0,
"enrichments": [
{
"name": "string",
"kind": "chunk",
"source": {
"group_by": "string",
"order_by": "string",
"segment_by": "string",
"field": "string",
"filter": {},
"max_bytes": 1,
"max_members": 1,
"window_ordinals": 1
},
"prior_context": {
"artifact": "string",
"render": "string",
"max_items": 1,
"max_bytes": 1,
"horizon_segments": 1
},
"field": "string",
"template": "string",
"source_artifact_name": "string",
"expected_dims": 0,
"vector_space": "string",
"chunk_size": 0,
"chunk_overlap": 0,
"chunker": {
"provider": "antfly",
"model": "fixed",
"text": {
"target_tokens": 500,
"overlap_tokens": 50
}
},
"chunker_json": "string",
"full_text_index": true,
"content_type": "string",
"neighbor_context": {
"graph_index": "string",
"edge_types": [
"string"
],
"direction": "out",
"limit": 1
},
"execution": {
"batch_items": 1,
"batch_bytes": 1,
"max_document_pages": 1
}
}
]
}Drop an index from an explicit namespace table
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Code Examples
curl -X DELETE "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}" \
-H "Authorization: Bearer YOUR_API_KEY"const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.delete('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}', headers=headers)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
Retry a failed index build
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retryGeneration-fenced relational index maintenance. Requires table ADMIN permission. Retry accepts failed generations. Owners are admitted independently and durably; exact request replay resumes after partial acknowledgements. Unsupported index types return 405.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
Code Examples
curl -X POST "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retry" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}'const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retry', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retry', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retry',
headers=headers,
json={
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/retry", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"acknowledged_groups": [
"string"
]
}Repair an index generation
/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repairGeneration-fenced relational index maintenance. Requires table ADMIN permission. Repair accepts ready or failed generations and rebuilds their derived records. Owners are admitted independently and durably; exact request replay resumes after partial acknowledgements. Unsupported index types return 405.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer YOUR_API_KEY
Request Body
Example:
{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
Code Examples
curl -X POST "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repair" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}'const response = await fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repair', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
});
const data = await response.json();fetch('/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repair', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
})
})
.then(response => response.json())
.then(data => console.log(data));import requests
headers = {
'Authorization': 'Bearer YOUR_API_KEY'
}
response = requests.post(
'/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repair',
headers=headers,
json={
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}
)
data = response.json()package main
import (
"bytes"
"encoding/json"
"net/http"
)
func main() {
body := []byte(`{
"table_id": "string",
"schema_version": 0,
"owners": [
{
"group_id": "string",
"generation": "string",
"slot": 0,
"owner": "string",
"comparison": "string",
"progress_digest": "string",
"maintenance_epoch": "string"
}
]
}`)
req, _ := http.NewRequest("POST", "/db/v1/databases/{databaseName}/namespaces/{namespaceName}/tables/{tableName}/indexes/{indexName}/repair", bytes.NewBuffer(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
}Responses
{
"acknowledged_groups": [
"string"
]
}