The Sentiment Detection API automatically identifies the sentiment of a text, classifying it as positive or negative. In addition to classification, the API also provides a numerical score indicating the intensity of the detected sentiment, allowing for a more in-depth and nuanced analysis of emotional content.
Its operation is simple: a text string is sent as input, and the API returns a JSON structure with the analyzed text, the detected sentiment (“POSITIVE” or “NEGATIVE”), and a score ranging from -1 to 1. A score close to -1 reflects a highly negative emotion, while a value close to 1 indicates a strongly positive sentiment. For example, the text “I hate it” returns a “NEGATIVE” sentiment with a score of -0.556.
This API is ideal for a wide range of applications such as product review analysis, social media monitoring, customer service, surveys, user-generated content analysis, and more. It can be easily integrated into CRM systems, marketing dashboards, brand monitoring tools, support bots, or any platform that processes natural language.
To use this endpoint, you must specify text in the parameter.
Sentiment Analyzer - Endpoint Features
| Object | Description |
|---|---|
text |
[Required] Indicate a text |
{"score": 0.639, "text": "i love it", "sentiment": "POSITIVE"}
curl --location --request GET 'https://zylalabs.com/api/8453/sentiment+detection+api/14816/sentiment+analyzer?text=i love it' --header 'Authorization: Bearer YOUR_API_KEY'
| Header | Description |
|---|---|
Authorization
|
[Required] Should be Bearer access_key. See "Your API Access Key" above when you are subscribed. |
No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.
The Sentiment Detection API returns a JSON structure containing the analyzed text, the detected sentiment (either "POSITIVE" or "NEGATIVE"), and a numerical emotional intensity score ranging from -1 to 1.
The key fields in the response data include "text" (the input text), "sentiment" (the sentiment classification), and "score" (the numerical intensity of the sentiment).
The response data is organized in a JSON format with three main fields: "text" for the original input, "sentiment" for the classification, and "score" for the emotional intensity, allowing for easy parsing and integration.
The primary parameter for the Sentiment Detection API is "text," which must be provided as input. Users can customize their requests by varying the text content they analyze.
Typical use cases include analyzing product reviews, monitoring social media sentiment, enhancing customer service interactions, conducting surveys, and evaluating user-generated content for emotional insights.
Data accuracy is maintained through continuous model training and validation against diverse datasets, ensuring the sentiment analysis reflects real-world language use and emotional expression.
Users can utilize the returned data by integrating the sentiment and score into applications for real-time feedback, trend analysis, or automated responses in customer service and marketing strategies.
Standard data patterns include a clear classification of sentiment and a corresponding score that indicates emotional intensity, such as "NEGATIVE" with a score of -0.556 for negative sentiments.
Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.
Service Level:
100%
Response Time:
379ms
Service Level:
100%
Response Time:
1,884ms
Service Level:
100%
Response Time:
346ms
Service Level:
100%
Response Time:
16ms
Service Level:
100%
Response Time:
19ms
Service Level:
100%
Response Time:
474ms
Service Level:
100%
Response Time:
20ms
Service Level:
100%
Response Time:
2,244ms
Service Level:
100%
Response Time:
1,541ms
Service Level:
100%
Response Time:
62ms
Service Level:
100%
Response Time:
15ms
Service Level:
100%
Response Time:
16ms
Service Level:
100%
Response Time:
15ms
Service Level:
100%
Response Time:
15ms
Service Level:
100%
Response Time:
6,852ms
Service Level:
100%
Response Time:
10,959ms
Service Level:
100%
Response Time:
72ms
Service Level:
100%
Response Time:
19,933ms
Service Level:
100%
Response Time:
7,015ms
Service Level:
100%
Response Time:
9,055ms