Skip to main content
GET
/
api
/
v1
/
documents
/
:id
const documentId = 'd29176d4-25c6-4345-852d-0792e3812c70';
const options = {
  method: 'GET',
  headers: {
    'x-api-key': '<your-api-key>',
  },
};

fetch(`https://api-v2.getomni.ai/api/v1/documents/${documentId}`, options)
  .then((response) => response.json())
  .then((response) => console.log(response))
  .catch((err) => console.error(err));
{
  "id": "d29176d4-25c6-4345-852d-0792e3812c70",
  "filename": "omniai-technology-inc-8961-monthly-statement-2025-05.pdf",
  "mimeType": "application/pdf",
  "size": 131777,
  "leadId": "4cc8af99-b313-4c1f-b98b-009f38a4721a",
  "workspaceId": "6048d78a-584a-4f1e-9e39-e011ca4cc48c",
  "signedUrl": "https://omniai-server-v2-dev.s3.us-east-2.amazonaws.com/...",
  "createdAt": "2025-10-30T20:07:24.663Z",
  "updatedAt": "2025-10-30T20:08:20.033Z"
}
This endpoint fetches a single document by ID, including metadata and a signed URL for accessing the document.

Path Parameters

id
string
required
The unique identifier of the document

Response

id
string
Unique identifier for the document
filename
string
Original filename
mimeType
string
MIME type of the document (e.g., “application/pdf”, “image/jpeg”)
size
number
File size in bytes
leadId
string
ID of the lead this document belongs to
workspaceId
string
ID of the workspace this document belongs to
signedUrl
string
Pre-signed URL for accessing the document (expires after 1 hour)
createdAt
string
ISO 8601 timestamp when the document was created
updatedAt
string
ISO 8601 timestamp when the document was last updated
Signed URLs expire after 1 hour. Request the document again to get a fresh signed URL if needed.
const documentId = 'd29176d4-25c6-4345-852d-0792e3812c70';
const options = {
  method: 'GET',
  headers: {
    'x-api-key': '<your-api-key>',
  },
};

fetch(`https://api-v2.getomni.ai/api/v1/documents/${documentId}`, options)
  .then((response) => response.json())
  .then((response) => console.log(response))
  .catch((err) => console.error(err));
{
  "id": "d29176d4-25c6-4345-852d-0792e3812c70",
  "filename": "omniai-technology-inc-8961-monthly-statement-2025-05.pdf",
  "mimeType": "application/pdf",
  "size": 131777,
  "leadId": "4cc8af99-b313-4c1f-b98b-009f38a4721a",
  "workspaceId": "6048d78a-584a-4f1e-9e39-e011ca4cc48c",
  "signedUrl": "https://omniai-server-v2-dev.s3.us-east-2.amazonaws.com/...",
  "createdAt": "2025-10-30T20:07:24.663Z",
  "updatedAt": "2025-10-30T20:08:20.033Z"
}