Skip to content
  • Auto
  • Light
  • Dark

Knowledge Bases

Knowledge Bases

Knowledge Bases

Create a Knowledge Base
post/v2/gen-ai/knowledge_bases
Delete a Knowledge Base
delete/v2/gen-ai/knowledge_bases/{uuid}
List Knowledge Bases
get/v2/gen-ai/knowledge_bases
Retrieve Information About an Existing Knowledge Base
get/v2/gen-ai/knowledge_bases/{uuid}
Update a Knowledge Base
put/v2/gen-ai/knowledge_bases/{uuid}
API Knowledge Base
APIKnowledgeBaseobject

Knowledgebase Description

ShowShow
added_to_agent_atstring
optional

Time when the knowledge base was added to the agent

formatdate-time
created_atstring
optional

Creation date / time

formatdate-time
database_idstring
optional
embedding_model_uuidstring
optional
is_publicboolean
optional

Whether the knowledge base is public or not

last_indexing_jobcompleted_datasourcesnumbercreated_atstringdata_source_uuidsarray of stringfinished_atstringknowledge_base_uuidstringphaseenumstarted_atstringstatusenumtokensnumbertotal_datasourcesnumberupdated_atstringuuidstringAPIIndexingJob
optional

IndexingJob description

namestring
optional

Name of knowledge base

project_idstring
optional
regionstring
optional

Region code

tagsarray of string
optional

Tags to organize related resources

updated_atstring
optional

Last modified

formatdate-time
user_idstring
optional

Id of user that created the knowledge base

formatint64
uuidstring
optional

Unique id for knowledge base

Knowledge BasesData Sources

Add Data Source to a Knowledge Base
post/v2/gen-ai/knowledge_bases/{knowledge_base_uuid}/data_sources
Delete a Data Source from a Knowledge Base
delete/v2/gen-ai/knowledge_bases/{knowledge_base_uuid}/data_sources/{data_source_uuid}
List Data Sources for a Knowledge Base
get/v2/gen-ai/knowledge_bases/{knowledge_base_uuid}/data_sources
API File Upload Data Source
APIFileUploadDataSourceobject

File to upload as data source for knowledge base.

ShowShow
original_file_namestring
optional

The original file name

size_in_bytesstring
optional

The size of the file in bytes

formatuint64
stored_object_keystring
optional

The object key the file was stored as

API Knowledge Base Data Source
APIKnowledgeBaseDataSourceobject

Data Source configuration for Knowledge Bases

ShowShow
aws_data_sourceobject
optional

AWS S3 Data Source for Display

Hide ParametersShow Parameters
bucket_namestring
optional

Spaces bucket name

item_pathstring
optional
regionstring
optional

Region of bucket

bucket_namestring
optional

Name of storage bucket - Deprecated, moved to data_source_details

created_atstring
optional

Creation date / time

formatdate-time
file_upload_data_sourceoriginal_file_namestringsize_in_bytesstringstored_object_keystringAPIFileUploadDataSource
optional

File to upload as data source for knowledge base.

item_pathstring
optional

Path of folder or object in bucket - Deprecated, moved to data_source_details

last_datasource_indexing_jobcompleted_atstringdata_source_uuidstringerror_detailsstringerror_msgstringfailed_item_countstringindexed_file_countstringindexed_item_countstringremoved_item_countstringskipped_item_countstringstarted_atstringstatusenumtotal_bytesstringtotal_bytes_indexedstringtotal_file_countstringAPIIndexedDataSource
optional
last_indexing_jobcompleted_datasourcesnumbercreated_atstringdata_source_uuidsarray of stringfinished_atstringknowledge_base_uuidstringphaseenumstarted_atstringstatusenumtokensnumbertotal_datasourcesnumberupdated_atstringuuidstringAPIIndexingJob
optional

IndexingJob description

regionstring
optional

Region code - Deprecated, moved to data_source_details

spaces_data_sourcebucket_namestringitem_pathstringregionstringAPISpacesDataSource
optional

Spaces Bucket Data Source

updated_atstring
optional

Last modified

formatdate-time
uuidstring
optional

Unique id of knowledge base

web_crawler_data_sourcebase_urlstringcrawling_optionenumembed_mediabooleanAPIWebCrawlerDataSource
optional

WebCrawlerDataSource

API Spaces Data Source
APISpacesDataSourceobject

Spaces Bucket Data Source

ShowShow
bucket_namestring
optional

Spaces bucket name

item_pathstring
optional
regionstring
optional

Region of bucket

API Web Crawler Data Source
APIWebCrawlerDataSourceobject

WebCrawlerDataSource

ShowShow
base_urlstring
optional

The base url to crawl.

crawling_optionenum
optional
"UNKNOWN" OR "SCOPED" OR "PATH" OR 2 more

Options for specifying how URLs found on pages should be handled.

  • UNKNOWN: Default unknown value
  • SCOPED: Only include the base URL.
  • PATH: Crawl the base URL and linked pages within the URL path.
  • DOMAIN: Crawl the base URL and linked pages within the same domain.
  • SUBDOMAINS: Crawl the base URL and linked pages for any subdomain.
Hide ParametersShow Parameters
"UNKNOWN"
"SCOPED"
"PATH"
"DOMAIN"
"SUBDOMAINS"
embed_mediaboolean
optional

Whether to ingest and index media (images, etc.) on web pages.

Aws Data Source
AwsDataSourceobject

AWS S3 Data Source

ShowShow
bucket_namestring
optional

Spaces bucket name

item_pathstring
optional
key_idstring
optional

The AWS Key ID

regionstring
optional

Region of bucket

secret_keystring
optional

The AWS Secret Key

Knowledge BasesIndexing Jobs

Start Indexing Job for a Knowledge Base
post/v2/gen-ai/indexing_jobs
List Indexing Jobs for a Knowledge Base
get/v2/gen-ai/indexing_jobs
List Data Sources for Indexing Job for a Knowledge Base
get/v2/gen-ai/indexing_jobs/{indexing_job_uuid}/data_sources
Cancel Indexing Job for a Knowledge Base
put/v2/gen-ai/indexing_jobs/{uuid}/cancel
API Indexed Data Source
APIIndexedDataSourceobject
ShowShow
completed_atstring
optional

Timestamp when data source completed indexing

formatdate-time
data_source_uuidstring
optional

Uuid of the indexed data source

error_detailsstring
optional

A detailed error description

error_msgstring
optional

A string code provinding a hint which part of the system experienced an error

failed_item_countstring
optional

Total count of files that have failed

formatuint64
indexed_file_countstring
optional

Total count of files that have been indexed

formatuint64
indexed_item_countstring
optional

Total count of files that have been indexed

formatuint64
removed_item_countstring
optional

Total count of files that have been removed

formatuint64
skipped_item_countstring
optional

Total count of files that have been skipped

formatuint64
started_atstring
optional

Timestamp when data source started indexing

formatdate-time
statusenum
optional
"DATA_SOURCE_STATUS_UNKNOWN" OR "DATA_SOURCE_STATUS_IN_PROGRESS" OR "DATA_SOURCE_STATUS_UPDATED" OR 3 more
Hide ParametersShow Parameters
"DATA_SOURCE_STATUS_UNKNOWN"
"DATA_SOURCE_STATUS_IN_PROGRESS"
"DATA_SOURCE_STATUS_UPDATED"
"DATA_SOURCE_STATUS_PARTIALLY_UPDATED"
"DATA_SOURCE_STATUS_NOT_UPDATED"
"DATA_SOURCE_STATUS_FAILED"
total_bytesstring
optional

Total size of files in data source in bytes

formatuint64
total_bytes_indexedstring
optional

Total size of files in data source in bytes that have been indexed

formatuint64
total_file_countstring
optional

Total file count in the data source

formatuint64
API Indexing Job
APIIndexingJobobject

IndexingJob description

ShowShow
completed_datasourcesnumber
optional

Number of datasources indexed completed

formatint64
created_atstring
optional

Creation date / time

formatdate-time
data_source_uuidsarray of string
optional
finished_atstring
optional
formatdate-time
knowledge_base_uuidstring
optional

Knowledge base id

phaseenum
optional
"BATCH_JOB_PHASE_UNKNOWN" OR "BATCH_JOB_PHASE_PENDING" OR "BATCH_JOB_PHASE_RUNNING" OR 4 more
Hide ParametersShow Parameters
"BATCH_JOB_PHASE_UNKNOWN"
"BATCH_JOB_PHASE_PENDING"
"BATCH_JOB_PHASE_RUNNING"
"BATCH_JOB_PHASE_SUCCEEDED"
"BATCH_JOB_PHASE_FAILED"
"BATCH_JOB_PHASE_ERROR"
"BATCH_JOB_PHASE_CANCELLED"
started_atstring
optional
formatdate-time
statusenum
optional
"INDEX_JOB_STATUS_UNKNOWN" OR "INDEX_JOB_STATUS_PARTIAL" OR "INDEX_JOB_STATUS_IN_PROGRESS" OR 4 more
Hide ParametersShow Parameters
"INDEX_JOB_STATUS_UNKNOWN"
"INDEX_JOB_STATUS_PARTIAL"
"INDEX_JOB_STATUS_IN_PROGRESS"
"INDEX_JOB_STATUS_COMPLETED"
"INDEX_JOB_STATUS_FAILED"
"INDEX_JOB_STATUS_NO_CHANGES"
"INDEX_JOB_STATUS_PENDING"
tokensnumber
optional

Number of tokens

formatint64
total_datasourcesnumber
optional

Number of datasources being indexed

formatint64
updated_atstring
optional

Last modified

formatdate-time
uuidstring
optional

Unique id