Serverless AI Tag Extraction

AI powered tag extraction from text. Extract relevant tags from content automatically or filter from a predefined set of tags. Perfect for content categorization, SEO optimization, and improving search functionality.

Endpoint

Extract relevant tags from text or filter content against predefined tags.

POSThttps://api.xtartapp.com/text/tag-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
textstringYes2500The text to analyze for tag extraction
tagsarray of stringsNo10Optional array of strings to filter against. If not provided, up to 10 tags will be automatically generated.

Response

NameTypeDescription
dataobjectThe result of the tag extraction
data.<tag>number or nullWhen tags are provided for filtering: relevance score (0.0 to 1.0) for each tag, or null if not relevant
data.tagsarrayWhen auto-generating tags: array of extracted tags with relevance scores
data.tags[].tagstringThe extracted tag text
data.tags[].relevancenumberRelevance score (0.0 to 1.0) for the tag
metadataobjectMetadata about the tag extraction process
metadata.costnumberThe cost of the tag extraction request

Errors

{
   "error": "string", 
   "code": "string"
}
HTTP StatusError CodeMessage
400INVALID_PAYLOADOccurs when the payload is invalid.
400INVALID_REQUESTEx.: The request is invalid.
400TEXT_TAG_EXTRACTION_ERROREx: could not extract tags from the text | parsing error
400HARM_CONTENTEx.: The content is harmful and cannot be processed.
400INSUFFICIENT_BALANCEThe user has insufficient balance
401UNAUTHORIZEDEx.: The token is invalid.
429TOO_MANY_REQUESTSEx.: The request limit has been reached.