Median

GET /knowledge/documents/{id}

Updated Oct 1, 20261 minute read

Get a document

One document in full, body included, plus a download URL when it arrived as a file.

Part of Knowledge.

Parameters

NameInTypeRequiredDescription
idpathstringYesA document id.

Responses

StatusDescription
200The document.
401The bearer token is missing, revoked, or expired.
404Not one of yours, or not there at all.
429Too many requests. Wait the seconds in Retry-After. Limits depend on the plan. See rate limits.

200 body

FieldTypeRequiredDescription
idstringNo
titlestringNo
source"upload" | "manual" | "github" | "notion" | "web" | "learned"No
status"indexing" | "ready" | "error"No
erroranyNo
originanyNoA repository path, a filename, or a page URL, when it came from one.
urlanyNoThe published page a customer can open, when the document has one. Null for words with no public home, which the agent never links.
folderIdanyNo
ordernumberNo
updatedAtintegerNo
bodystringNo
fileUrlanyNo
conversationIdanyNo

Example request

curl https://api.median.sh/v1/knowledge/documents/id \
  -H "Authorization: Bearer $BEARER_AUTH"

Still need help?

    Esc