# AgentUtility Sentiment Analysis

> AgentUtility Sentiment Analysis is a paid API for AI agents from x402.agentutility.ai, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Analyzes text to return overall sentiment polarity, a numeric score (-1 to +1), per-emotion labels (joy, anger, sadness, fear, surprise, disgust), and optional aspect-based sentiment scoring.

## Facts

- Endpoint: POST https://x402.agentutility.ai/sentiment-analysis
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agentutility-sentiment-analysis-5e8cbe36
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_3Z2uXbH3M5FbKkkkCl66K

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agentutility-sentiment-analysis-5e8cbe36 -d '<json body>'
```

Example prompt: Can you analyze the sentiment of this customer review and tell me the overall polarity score, whether it's positive or negative, and which emotions like joy or anger are present: 'The battery life is incredible but the camera quality was deeply disappointing'?

## When to prefer this

Choose this endpoint when you need fine-grained emotional classification (joy, anger, sadness, fear, surprise, disgust) alongside a continuous sentiment score and optional aspect-level breakdown — going beyond simple positive/negative polarity. Ideal for agents processing product reviews, support tickets, or social comments where understanding specific emotions or per-feature sentiment matters. At $0.01 USDC per call with x402 micropayment settlement, it's well-suited for per-document billing in agentic workflows.

## Known failure modes

- Empty or missing text input returns a validation error
- Text exceeding maximum character limits may be rejected or truncated
- Non-text or binary payloads will fail
- Payment not included or insufficient USDC results in 402 Payment Required
- Ambiguous or very short text may return low-confidence or neutral scores
- Non-English text may yield reduced accuracy depending on underlying model support

## How this service works

Analyzes sentiment in arbitrary text, returning overall sentiment, a score (-1 to +1), per-emotion labels (joy/anger/sadness/fear/surprise/disgust), and optional aspect-based scoring. A text-only analysis endpoint for product reviews, tickets, comments, and support logs. Use it as a sentiment analyzer, text sentiment classifier, emotion classifier, or aspect-based sentiment API.

## Output

Returns a JSON object containing: an overall sentiment label (positive/negative/neutral), a numeric sentiment score from -1 to +1, per-emotion labels covering joy, anger, sadness, fear, surprise, and disgust with their intensities, and optionally aspect-level sentiment scores if aspect terms are provided.

## Request schema (JSON Schema)

```json
{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "type": "object",
 "properties": {
  "input": {
   "type": "object",
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "type": "string",
     "enum": [
      "POST"
     ]
    },
    "bodyType": {
     "type": "string",
     "enum": [
      "json",
      "form-data",
      "text"
     ]
    },
    "body": {
     "properties": {
      "text": {
       "type": "string",
       "description": "Text to analyze. Max 12,000 chars."
      },
      "aspects": {
       "type": "array",
       "description": "Optional. Up to 15 aspect names (e.g. 'food', 'service') to score individually alongside overall sentiment."
      }
     },
     "required": [
      "text"
     ]
    }
   },
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "overall_sentiment": {
       "type": "string"
      },
      "overall_score": {
       "type": "number"
      }
     }
    }
   },
   "required": [
    "type"
   ]
  }
 },
 "required": [
  "input"
 ]
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "overall_score": 0.1,
  "overall_sentiment": "mixed"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agentutility-sentiment-analysis-5e8cbe36/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.agentutility.ai](https://www.zero.xyz/host/x402.agentutility.ai/llms.txt)
