Skip to content

Get Document

Retrieve a single document by its ID from Last Mile Intelligence.

getDocument

document

ParameterTypeRequiredDefaultDescription
Document IDstringYes-The ID of the document to retrieve
{
"id": "doc_abc123",
"name": "Delivery Receipt",
"type": "receipt",
"mimeType": "application/pdf",
"size": 125000,
"url": "https://storage.lmi.com/documents/doc_abc123.pdf",
"entityType": "order",
"entityId": "ord_xyz789",
"createdAt": "2024-06-15T14:30:00Z"
}
{
"success": false,
"error": "Document not found",
"documentId": "invalid_id"
}
  • Missing API Token: LMI credential is missing API token
  • Document Not Found: Document with specified ID does not exist
  • Permission Denied: API token lacks permission for this operation