Documentation Index
Fetch the complete documentation index at: https://docs.filefetch.app/llms.txt
Use this file to discover all available pages before exploring further.
Basic File Queries
All Recent Files (Latest Versions Only)
SELECT Id, Title, ContentDocumentId, FileExtension, ContentSize, CreatedDate
FROM ContentVersion
WHERE IsLatest = true
ORDER BY CreatedDate DESC
LIMIT 100
Files from Last 30 Days
SELECT Id, Title, ContentDocumentId, CreatedDate
FROM ContentVersion
WHERE IsLatest = true
AND CreatedDate = LAST_N_DAYS:30
ORDER BY CreatedDate DESC
PDFs Only
SELECT Id, Title, ContentDocumentId, FileExtension
FROM ContentVersion
WHERE IsLatest = true
AND FileExtension = 'pdf'
LIMIT 500
Large Files (>10MB)
SELECT Id, Title, ContentDocumentId, ContentSize
FROM ContentVersion
WHERE IsLatest = true
AND ContentSize > 10485760
ORDER BY ContentSize DESC
LIMIT 100
Legacy Attachments
Recent Attachments
SELECT Id, Name, BodyLength, ParentId, CreatedDate
FROM Attachment
WHERE CreatedDate = LAST_N_DAYS:90
ORDER BY CreatedDate DESC
LIMIT 200
PDF Attachments
SELECT Id, Name, BodyLength, CreatedDate
FROM Attachment
WHERE Name LIKE '%.pdf'
ORDER BY CreatedDate DESC
LIMIT 500
More Examples
Power Mode Guide
Complete SOQL reference and examples
Query Builder
Use visual filters instead