const options = { method: "POST", headers: { "x-api-key": "<your-api-key>", "Content-Type": "application/json", }, body: JSON.stringify({ jobId: "123e4567-e89b-12d3-a456-426614174000", annotatedData: { name: "John Doe", amount: "1500", }, extractId: "123e4567-e89b-12d3-a456-426614174002", }), }; fetch("https://api.getomni.ai/extract-annotations", options) .then((response) => response.json()) .then((response) => console.log(response)) .catch((err) => console.error(err));
{ "success": true, "annotation": { "jobId": "123e4567-e89b-12d3-a456-426614174000", "documentUrl": "https://example.com/document.pdf", "originalData": { "name": "John Doe", "amount": "1000" }, "annotatedData": { "name": "John Doe", "amount": "1500" }, "createdAt": "2023-09-10T14:23:45.123Z", "updatedAt": "2023-09-10T14:23:45.123Z" } }
Save or update annotations for extracted data
annotationId
Show annotation