Skip to main content
GET
/
api
/
corpora
/
{corpus_id}
/
sources
/
{source_id}
cURL
curl --request GET \
  --url https://api.ultravox.ai/api/corpora/{corpus_id}/sources/{source_id} \
  --header 'X-API-Key: <api-key>'
{
  "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>"
    ]
  },
  "advanced": {
    "documents": [
      {
        "documentId": "<string>",
        "exampleQueries": [
          "<string>"
        ]
      }
    ]
  }
}

Authorizations

X-API-Key
string
header
required

API key

Path Parameters

corpus_id
string<uuid>
required
source_id
string<uuid>
required

Response

200 - application/json

A source of documents for building a corpus. A source defines where documents are pulled from.

corpusId
string

The id of this source's corpus.

sourceId
string

The unique ID of this source.

created
string<date-time>

When this source was created.

name
string

The name of this source.

description
string

A description of this source.

stats
object

The current stats for this source.

loadSpec
object

DEPRECATED. Prefer setting crawl instead. If either crawl or upload is set, this field will be ignored.

crawl
object

Allows loading documents by crawling the web.

upload
object

Allows loading from a uploaded document.

advanced
object

Allows loading from an advanced documents source. This is similar to an upload source, but requires setting example queries for each document. When a similar query is issued, the document will be returned in its entirety.