{
  "serviceId": "sentiment-classification",
  "displayName": "Sentiment Classification",
  "description": "Lexicon-based sentiment scoring: label a text positive, negative or neutral with a score and the positive and negative word hits behind it (AFINN-derived word list, not a trained model). POST /v1/sentiment with {text}. Deterministic. Pay per request in USDC; no account, no API key.",
  "category": "documents",
  "resourceUrl": "https://test.agent.pocket.network/v1/sentiment-classification",
  "priceUsd": "0.005000",
  "priceVersion": 1,
  "rails": [
    {
      "id": "base",
      "network": "eip155:84532",
      "chainId": 84532,
      "tokenAddress": "0x036CbD53842c5426634e7929541eC2318f3dCF7e",
      "tokenDecimals": 6,
      "payToAddress": "0xF732ea490c5766071785a2310523f7fA2CEbB829"
    }
  ],
  "paymentNetworks": [
    "eip155:84532"
  ],
  "paymentProtocols": [
    "x402"
  ],
  "protocols": [
    "rest"
  ],
  "inputSchema": {
    "type": "object",
    "description": "The request body for POST /v1/sentiment.",
    "properties": {
      "text": {
        "type": "string",
        "description": "The text to score."
      }
    },
    "required": [
      "text"
    ]
  },
  "outputSchema": {
    "type": "object",
    "description": "For POST /v1/sentiment, a JSON object with label, score, positive_hits, negative_hits and the lexicon used. The exact shape is the service's own and is not pinned here; errors return a JSON object with an `error` field."
  },
  "methods": {
    "GET /v1/health": "read",
    "GET /v1/version": "read",
    "POST /v1/sentiment": "read"
  },
  "example": {
    "method": "POST",
    "path": "/v1/sentiment",
    "request": {
      "text": "great service"
    },
    "response": {
      "portal": {
        "provenance": "third-party-supplier",
        "serviceId": "sentiment-classification",
        "schemaCheck": "unchecked"
      },
      "data": {
        "label": "positive",
        "score": 1,
        "positive_hits": 1,
        "negative_hits": 0,
        "lexicon": "lexicon-v2-enhanced",
        "deterministic": true,
        "service": "sentiment-classification"
      }
    },
    "capturedAt": "2026-09-25T15:53:29Z"
  },
  "firstParty": true,
  "networks": [
    "eip155:84532"
  ],
  "serving": true,
  "page": "https://test.agent.pocket.network/services/sentiment-classification",
  "descriptor": "https://test.agent.pocket.network/services/sentiment-classification/descriptor.json"
}