Corpora, Query, Sources
Create Corpus Source
Agents
Calls, Messages, Stages
Corpora, Query, Sources
- Corpus Service (RAG) Overview
- GETList Corpora
- POSTCreate Corpus
- GETGet Corpus
- PATCHUpdate Corpus
- DELDelete Corpus
- POSTQuery Corpus
- GETList Corpus Sources
- POSTCreate Corpus Source
- GETGet Corpus Source
- PATCHUpdate Corpus Source
- DELDelete Corpus Source
- GETList Corpus Source Documents
- GETGet Corpus Source Document
- POSTCreate Corpus File Upload
Webhooks
Corpora, Query, Sources
Create Corpus Source
Creates a new source for the specified corpus
POST
/
api
/
corpora
/
{corpus_id}
/
sources
curl --request POST \
--url https://api.ultravox.ai/api/corpora/{corpus_id}/sources \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '{
"corpusId": "<string>",
"sourceId": "<string>",
"created": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>",
"stats": {
"status": "SOURCE_STATUS_UNSPECIFIED",
"lastUpdated": "2023-11-07T05:31:56Z",
"numDocs": 123
},
"loadSpec": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"crawl": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"upload": {
"documentIds": [
"<string>"
]
}
}'
{
"corpusId": "<string>",
"sourceId": "<string>",
"created": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>",
"stats": {
"status": "SOURCE_STATUS_UNSPECIFIED",
"lastUpdated": "2023-11-07T05:31:56Z",
"numDocs": 123
},
"loadSpec": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"crawl": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"upload": {
"documentIds": [
"<string>"
]
}
}
Authorizations
API key
Path Parameters
Body
application/json
A source of documents for building a corpus. A source defines where documents are pulled from.
Response
201 - application/json
A source of documents for building a corpus. A source defines where documents are pulled from.
curl --request POST \
--url https://api.ultravox.ai/api/corpora/{corpus_id}/sources \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '{
"corpusId": "<string>",
"sourceId": "<string>",
"created": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>",
"stats": {
"status": "SOURCE_STATUS_UNSPECIFIED",
"lastUpdated": "2023-11-07T05:31:56Z",
"numDocs": 123
},
"loadSpec": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"crawl": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"upload": {
"documentIds": [
"<string>"
]
}
}'
{
"corpusId": "<string>",
"sourceId": "<string>",
"created": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>",
"stats": {
"status": "SOURCE_STATUS_UNSPECIFIED",
"lastUpdated": "2023-11-07T05:31:56Z",
"numDocs": 123
},
"loadSpec": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"crawl": {
"maxDocuments": 123,
"maxDocumentBytes": 123,
"relevantDocumentTypes": {
"include": {
"mimeTypes": [
"<string>"
]
},
"exclude": {
"mimeTypes": [
"<string>"
]
}
},
"startUrls": [
"<string>"
],
"maxDepth": 123
},
"upload": {
"documentIds": [
"<string>"
]
}
}