Skip to main content
POST
/
v0
/
documents
/
upload
Upload documents via CSV, PDF, or XLSX file
curl --request POST \
  --url https://api.avidoai.com/v0/documents/upload \
  --header 'Content-Type: multipart/form-data' \
  --header 'x-api-key: <api-key>' \
  --header 'x-application-id: <api-key>' \
  --form 'file=<unknown>' \
  --form 'fileName=Knowledge Base Q1 2024' \
  --form documentType=KNOWLEDGE \
  --form quickstartId=456e7890-e89b-12d3-a456-426614174001 \
  --form topicId=789e0123-e89b-12d3-a456-426614174002 \
  --form 'metadata={"step":"KNOWLEDGE_BASE_REVIEW"}' \
  --form processFile=true
{
  "message": "Resource not found"
}

Documentation Index

Fetch the complete documentation index at: https://docs.avidoai.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

x-api-key
string
header
required

Your unique Avido API key

x-application-id
string
header
required

Your unique Avido Application ID

Body

multipart/form-data

Request for uploading documents via CSV, PDF, or XLSX file

file
any
required

CSV, PDF, or XLSX file containing documents

fileName
string
required

Name for this import

Required string length: 1 - 256
Example:

"Knowledge Base Q1 2024"

documentType
enum<string>
default:KNOWLEDGE

Type of the documents being uploaded. Defaults to KNOWLEDGE.

Available options:
KNOWLEDGE,
POLICY
Example:

"KNOWLEDGE"

quickstartId
string<uuid>

ID of the quickstart this upload belongs to.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Example:

"456e7890-e89b-12d3-a456-426614174001"

topicId
string<uuid>

ID of the topic to associate the uploaded document with.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Example:

"789e0123-e89b-12d3-a456-426614174002"

metadata
object

Optional extra metadata merged into document version metadata. Send as a JSON string in FormData.

Example:

"{\"step\":\"KNOWLEDGE_BASE_REVIEW\"}"

processFile
boolean
default:true

Whether to process the file asynchronously via background job. Defaults to true.

Example:

true

Response

File uploaded and queued for processing successfully