AI Sentiment Analysis API
Pricing
from $0.01 / 1,000 results
AI Sentiment Analysis API
Analyze text sentiment with AI. Emotion detection, key phrase extraction. Supports OpenAI GPT-4, Claude. Webhook Integration for Zapier, Make, n8n, or custom webhook.
Pricing
from $0.01 / 1,000 results
Rating
0.0
(0)
Developer

John Rippy
Actor stats
0
Bookmarked
2
Total users
1
Monthly active users
3 days ago
Last modified
Categories
Share
Sentiment Analysis API
Analyze text sentiment using AI or rule-based analysis. Detect positive, negative, neutral, and mixed sentiments with emotion detection, confidence scores, and key phrase extraction.
Features
- Multi-Model Support: Use OpenAI GPT-4o, Claude 3, or built-in rule-based analysis
- Emotion Detection: Identify joy, anger, sadness, fear, surprise, and disgust
- Key Phrase Extraction: Find phrases that influenced the sentiment
- Topic Detection: Automatically detect subjects mentioned in the text
- Batch Processing: Analyze multiple texts in a single run
- Multi-Language: Support for English, Spanish, French, German, and more
- Webhook Integration: Get notified when analysis completes
Use Cases
- Review Analysis: Analyze customer reviews to understand sentiment trends
- Social Media Monitoring: Track sentiment of brand mentions
- Customer Feedback: Categorize support tickets by sentiment
- Content Moderation: Flag negative or toxic content
- Market Research: Analyze survey responses and feedback
- Brand Health: Monitor overall sentiment over time
Input Parameters
| Parameter | Type | Description |
|---|---|---|
texts | array | Array of texts to analyze (max 100 per run) |
text | string | Single text to analyze (use this OR texts array) |
includeEmotions | boolean | Detect specific emotions (default: true) |
includeKeyPhrases | boolean | Extract key phrases (default: true) |
includeTopics | boolean | Detect topics/subjects (default: false) |
language | string | Language code or "auto" (default: auto) |
openaiApiKey | string | Your OpenAI API key for GPT-4 analysis |
anthropicApiKey | string | Your Anthropic API key for Claude analysis |
model | string | Model to use: auto, gpt-4o-mini, gpt-4o, claude-3-haiku, claude-3-sonnet, rule-based |
webhookUrl | string | URL to receive completion notification |
demoMode | boolean | Return sample data for testing |
Output
The actor outputs a comprehensive analysis object:
{"totalTexts": 3,"overallSentiment": "mixed","averageScore": 0.07,"results": [{"text": "I love this product! It's amazing.","sentiment": "positive","score": 0.92,"confidence": 0.95,"magnitude": 0.88,"emotions": [{ "name": "joy", "score": 0.85 },{ "name": "surprise", "score": 0.15 }],"keyPhrases": ["love this product", "amazing"],"topics": ["product", "quality"],"language": "en","model": "gpt-4o-mini","processingTime": 245}],"summary": {"positive": 1,"negative": 1,"neutral": 1,"mixed": 0}}
Sentiment Scores
- score: -1 (most negative) to 1 (most positive)
- confidence: 0 to 1, how confident the model is
- magnitude: 0 to 1, strength of the sentiment
Sentiment Categories
- positive: Score > 0.2
- negative: Score < -0.2
- neutral: Score between -0.2 and 0.2 with no mixed signals
- mixed: Contains both positive and negative elements
Example Usage
Basic Sentiment Analysis
{"texts": ["I love this product! It's amazing.","Terrible customer service, never again.","The package arrived on time."]}
AI-Powered Analysis
{"texts": ["Your product transformed my business! Thank you!"],"openaiApiKey": "sk-...","model": "gpt-4o-mini","includeEmotions": true,"includeKeyPhrases": true}
Review Batch Analysis
{"texts": ["5 stars! Best purchase ever.","Product broke after 2 days.","Good value for money.","Shipping was slow but item was fine."],"anthropicApiKey": "sk-ant-...","model": "claude-3-haiku","includeTopics": true}
With Webhook Notification
{"texts": ["Great experience overall!"],"webhookUrl": "https://hooks.zapier.com/your-webhook-id"}
Models Comparison
| Model | Speed | Accuracy | Cost | API Key Required |
|---|---|---|---|---|
| rule-based | Fastest | Good | Free | No |
| gpt-4o-mini | Fast | Excellent | Low | Yes (OpenAI) |
| gpt-4o | Medium | Best | Medium | Yes (OpenAI) |
| claude-3-haiku | Fast | Excellent | Low | Yes (Anthropic) |
| claude-3-sonnet | Medium | Best | Medium | Yes (Anthropic) |
Pricing
This actor uses the pay-per-event pricing model:
- Base cost: $0.05 per run
- Per text: $0.002 per text analyzed (rule-based)
- AI models: Additional cost based on API token usage
Example: Analyzing 100 reviews with rule-based = ~$0.25
Integration
Zapier/Make/n8n
Use the webhook URL to trigger automations when analysis completes. The webhook payload includes:
- Total texts analyzed
- Overall sentiment
- Average score
- Summary counts
Supabase/Database
Store results in your database for trend analysis and reporting.
Limitations
- Maximum 100 texts per run
- Text length limited to 2000 characters for AI models
- Rule-based analysis works best with English text
- AI models require valid API keys with sufficient credits
Support
For issues or feature requests, contact support.
Keywords
sentiment api, sentiment analysis, review sentiment, ai sentiment, text analysis, opinion mining, openai integration, claude integration