Document file or text document with version control. Represents various document types like PDFs, Word documents, technical specifications, or any file-based content.
https://api.mockly.codes/documents?page=1&limit=10&count=10Configure your request and click Send Request to see the response here.
/documentsGet a collection of documents
/content/documents/documents/:idGet a single document by ID
/content/documents/:id/documents/metaGet resource metadata and schema
/content/documents/metaThe search feature allows you to filter results by searching for text across all or specific fields. Choose between ?q= or ?search= parameter names.
Search across all text fields:
GET https://api.mockly.codes/documents?q=laptopGET https://api.mockly.codes/documents?q=laptop&search_fields=name,descriptionsearch_fields, all text fields are searched// Get 10 documents
fetch('https://api.mockly.codes/documents?count=10')
.then(res => res.json())
.then(data => console.log(data));import requests
response = requests.get(
'https://api.mockly.codes/documents?count=10'
)
data = response.json()curl "https://api.mockly.codes/documents?count=10"fetch('https://api.mockly.codes/documents?nocache=true')idintegerUnique identifier for the document
random_inttitlestringDocument title or filename
sentencetypestringDocument type or format (e.g., pdf, docx, markdown, specification, manual)
wordcontentstringDocument content or text (if text-based), or description for file-based documents
paragraphauthorstringFull name of the document author or creator
nameversionstringDocument version number or identifier (e.g., 1.0, 2.1, v3)
wordfile_urlstringURL or file path where the document file is stored
urluricreated_atstringTimestamp when the document was created
past_datedate-timecountintegerNumber of items to return (default: 10, max: 100)
seedintegerSeed for reproducible data generation
nocachebooleanBypass cache and generate fresh data on every request