Get supported file types
Returns a list of all supported file types and MIME types for knowledge base entries. This endpoint provides information about which file formats can be uploaded to the knowledge base, organized by media type (documents, images, audio, video, etc.). Each file type includes the supported MIME types, file extensions, and support level (production or preview). This information can be used by client applications to validate file uploads and provide appropriate user interface elements.
GET
/v1/knowledge-base/file-types
curl \
--request GET 'https://api.sensay.io/v1/knowledge-base/file-types' \
--header "X-ORGANIZATION-SECRET: $API_KEY" \
--header "X-API-Version: 2025-03-25"
Response examples (200)
{
"success": true,
"mediaGroups": [
{
"label": "PDF Documents",
"mediaType": "document",
"limitation": "Maximum duration: 90 minutes",
"fileTypes": [
{
"mimeTypes": [
"application/pdf"
],
"extensions": [
".pdf",
".pdfa"
],
"supportLevel": "production"
}
]
}
]
}
Response examples (400)
{
"error": "A text representation of the error",
"success": false,
"request_id": "xyz1::reg1:reg1::ab3c4-1234567890123-0123456789ab",
"fingerprint": "14fceadd84e74ec499afe9b0f7952d6b"
}
Response examples (401)
{
"error": "A text representation of the error",
"success": false,
"request_id": "xyz1::reg1:reg1::ab3c4-1234567890123-0123456789ab",
"fingerprint": "14fceadd84e74ec499afe9b0f7952d6b"
}
Response examples (404)
{
"error": "A text representation of the error",
"success": false,
"request_id": "xyz1::reg1:reg1::ab3c4-1234567890123-0123456789ab"
}
Response examples (415)
{
"error": "A text representation of the error",
"success": false,
"request_id": "xyz1::reg1:reg1::ab3c4-1234567890123-0123456789ab",
"fingerprint": "14fceadd84e74ec499afe9b0f7952d6b"
}
Response examples (500)
{
"error": "A text representation of the error",
"success": false,
"request_id": "xyz1::reg1:reg1::ab3c4-1234567890123-0123456789ab",
"fingerprint": "14fceadd84e74ec499afe9b0f7952d6b",
"inner_exception": {
"name": "Server overheated",
"cause": "Request too complicated",
"stack": "Error: Server overheated due to an unexpected situation\n at Object.eval (eval at <anonymous>...",
"message": "The server overheated due to an unexpected situation"
}
}