Serverless AI Image Content Extraction

AI powered OCR service that extracts specific text content from images based on the provided content keys.

Endpoint

Extract text content from images based on specific keys

POSThttps://api.xtartapp.com/image/content-extraction

*Authentication

You must use a Bearer token provided by the dashboard to use for authentication. Add the token to the Authorization header.

Request body

NameTypeRequiredMaxDescription
imagestringYes-Filename of the optimized .ximage file previously uploaded to the platform.
contentsarrayYes-Array of content keys and descriptions to extract from the image. Maximum 25 items.

Response

NameTypeDescription
dataobjectAn object containing all extracted content with keys matching the input content keys
metadataobjectMetadata about the image analysis process
metadata.costnumberThe cost of the image extraction request

Errors

{
   "error": "string", 
   "code": "string"
}
HTTP StatusError CodeMessage
400INVALID_PAYLOADOccurs when the payload is invalid.
400INVALID_REQUESTThe request is invalid.
400IMAGE_CONTENT_EXTRACTION_ERRORCould not extract content from image | parsing error.
400INVALID_IMAGEThe image was not found or is invalid.
400HARM_CONTENTThe content is harmful and cannot be processed.
400INSUFFICIENT_BALANCEThe user has insufficient balance.
401UNAUTHORIZEDThe token is invalid.
429TOO_MANY_REQUESTSThe request limit has been reached.