curl --request GET \
--url https://api.example.com/v1/documents/{id}{
"data": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"mime_type": "<string>",
"size_bytes": 123,
"storage_path": "<string>",
"folder": "<string>",
"tags": [
{}
],
"linked_entities": [
{}
],
"download_url": "<string>",
"download_url_expires_at": "<string>",
"created_by": "<string>",
"created_at": "<string>",
"updated_at": "<string>"
}
}Retrieve metadata and a short-lived signed download URL for a stored document
curl --request GET \
--url https://api.example.com/v1/documents/{id}{
"data": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"mime_type": "<string>",
"size_bytes": 123,
"storage_path": "<string>",
"folder": "<string>",
"tags": [
{}
],
"linked_entities": [
{}
],
"download_url": "<string>",
"download_url_expires_at": "<string>",
"created_by": "<string>",
"created_at": "<string>",
"updated_at": "<string>"
}
}GET /v1/documents.true (default), the response includes a signed URL valid for 15 minutes. Set to false for a lightweight metadata-only fetch.Authorization: Bearer wbk_your_api_key_here
Show properties
entity_type, entity_id)download=true.X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, and X-Request-ID.
curl https://data.leadlex.com/functions/v1/api-gateway/v1/documents/doc_01HY1 \
-H "Authorization: Bearer wbk_your_api_key_here"
{
"data": {
"id": "doc_01HY1",
"name": "Acme-NDA-2026.pdf",
"description": "Mutual NDA with Acme Corp",
"mime_type": "application/pdf",
"size_bytes": 183204,
"storage_path": "workspaces/ws_123/documents/doc_01HY1.pdf",
"folder": "/clients/acme/ndas",
"tags": ["nda"],
"linked_entities": [
{ "entity_type": "contact", "entity_id": "123e4567-e89b-12d3-a456-426614174000" }
],
"download_url": "https://storage.leadlex.com/signed/...",
"download_url_expires_at": "2026-04-17T11:00:00Z",
"created_by": "usr_01HW0",
"created_at": "2026-04-17T09:00:00Z",
"updated_at": "2026-04-17T09:00:00Z"
}
}
| Status | Code | Description |
|---|---|---|
| 401 | invalid_key | Invalid or expired API key |
| 403 | insufficient_permissions | Missing read:documents permission |
| 404 | not_found | Document not found |
| 429 | rate_limited | Rate limit exceeded |