{"uid":"cap_8ZoZywNdahPoa6p3XAxcG","slug":"x-twitter-tweet-sentiment-analyzer-cef8b618","name":"X / Twitter Tweet Sentiment Analyzer","description":"Tweet sentiment analyzer / Twitter recent-search sentiment / X post sentiment API. Fetches recent public X posts for a query, excludes retweets, and returns per-tweet labels plus aggregate sentiment distribution and average score.","url":"https://x402.agentutility.ai/tweet-sentiment?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","bodyType","body"],"properties":{"body":{"required":["query"],"properties":{"query":{"type":"string","description":"X recent-search query."},"language":{"type":"string","description":"Optional two-letter language filter."},"max_results":{"type":"number","description":"Number of recent posts to fetch, clamped to 10-50."}}},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"distribution":{"type":"object","properties":{"neutral":{"type":"integer"},"negative":{"type":"integer"},"positive":{"type":"integer"}}},"result_count":{"type":"integer"},"overall_sentiment":{"type":"string"}}}}}}},"responseSchema":{"type":"json","example":{"distribution":{"neutral":5,"negative":1,"positive":4},"result_count":10,"overall_sentiment":"positive"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.03","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"registry","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_IeaJmJjscJ5GrR1lORYFQ","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Fetches recent public X (Twitter) posts for a search query, excludes retweets, and returns per-tweet sentiment labels plus aggregate sentiment distribution and average score.","exampleAgentPrompt":"Can you analyze the sentiment of recent tweets about 'Apple Vision Pro' and tell me the overall mood — how many are positive, negative, or neutral, and what the average sentiment score is?","exampleUseCases":[{"title":"Brand reputation check on X","prompt":"Analyze the sentiment of recent tweets about 'Nike' and tell me whether public opinion is mostly positive, negative, or neutral right now, along with the breakdown."},{"title":"Product launch reaction tracking","prompt":"How are people reacting to the new 'GPT-5' launch on Twitter? Fetch recent tweets about it and give me a sentiment breakdown with the average score."},{"title":"Crisis monitoring for a public figure","prompt":"Pull the latest tweets mentioning 'Elon Musk' and analyze the overall sentiment — I want to know the distribution of positive, negative, and neutral posts and the average sentiment score."}],"resultDescription":"Returns a list of recent public X posts matching the query (retweets excluded), each labeled with a sentiment classification (positive, negative, or neutral) and a numeric sentiment score. Also returns aggregate statistics including the distribution of sentiment labels across all fetched tweets and the overall average sentiment score.","failureModes":["Query returns no results — no recent public tweets matched the search term","X/Twitter API rate limits or access restrictions result in empty or truncated results","Ambiguous search query returns off-topic tweets, skewing sentiment results","Payment failure via x402 protocol prevents the call from completing","Network timeout if the X search or sentiment scoring takes longer than expected"],"whenToPreferThis":"Choose this endpoint when you need both raw per-tweet sentiment labels and aggregate sentiment statistics for a search query in a single call, rather than fetching tweets and running sentiment separately. It is ideal for brand monitoring, product launch reactions, and event tracking on X. Prefer it over generic sentiment APIs when you specifically want Twitter/X social data included automatically without managing your own X API credentials.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-23T12:39:01.647Z","isFirstParty":false,"canonicalSlug":"x-twitter-tweet-sentiment-analyzer-cef8b618"}