const options = { method: "POST", headers: { "x-api-key": "<your-api-key>", "Content-Type": "application/json", }, body: JSON.stringify({ classificationId: "<classification-id>", url: "https://example.com/document.pdf", }), }; fetch("https://api.getomni.ai/classify", options) .then((response) => response.json()) .then((response) => console.log(response)) .catch((err) => console.error(err));
{ "result": { "id": "4e3598e3-3ee2-423b-820e-176f4547ac4b", "name": "BANK_STATEMENT" } }
Classifies a document into predefined categories
NO_MATCH
multipart/form-data
Show result