Multi-Dimensional Sentiment & Emotion
Detects positive, negative, neutral, and emotional sub-tones such as excitement, curiosity, or frustration.
Social media comment intelligence API for sentiment, intent, reply necessity, and priority scoring.
https://rsflowhub.com/api/v1/ai/comment-analyze
X-API-Key header{
"comment": "Do you ship to Mumbai? I would love to order this today!",
"platform": "Instagram",
"post_context": "Photo of our new handcrafted leather boots collection",
"business_context": "We are an artisanal e-commerce shop delivering worldwide. Shipping is free within India."
}
{
"result": {
"sentiment": "positive",
"intent": "purchase_question",
"language": "en",
"topics": [
"pricing",
"availability"
],
"requires_reply": true,
"priority": "high",
"recommended_action": "Reply with a link to the pricing page.",
"confidence": 0.9
}
}
Social Media Comment & Tone Analysis API is a REST API on RSFlowHub for web, mobile and AI agent applications. Send a JSON request to POST /api/v1/ai/comment-analyze with your API key; RSFlowHub runs it on a tuned AI model, falls back to a backup provider if needed, and returns a structured JSON result, usually within 1 to 3 seconds.
POST /api/v1/ai/comment-analyzeX-API-Key headerSend these fields as a JSON body. An invalid or missing field returns a 422 error that names the field.
| Field | Type | Required | Description |
|---|---|---|---|
comment |
string | Required | The social media comment text (Max: 5,000 characters). |
language |
string | Optional | Optional comment language identifier. |
platform |
string | Optional | Optional platform name (e.g. "Instagram", "Facebook", "YouTube", "LinkedIn"). |
post_context |
string | Optional | Optional post content or media brief context. |
business_context |
string | Optional | Optional business, product, or account rules context. |
author_context |
string | Optional | Optional commenter context details. |
Copy, replace rfh_your_api_key with your key and run. Prefer a client library? See the official SDKs.
curl -X POST "https://rsflowhub.com/api/v1/ai/comment-analyze" \
-H "Content-Type: application/json" \
-H "X-API-Key: rfh_your_api_key" \
-d '{"comment":"Do you ship to Mumbai? I would love to order this today!","platform":"Instagram","post_context":"Photo of our new handcrafted leather boots collection","business_context":"We are an artisanal e-commerce shop delivering worldwide. Shipping is free within India."}'
<?php
$client = new \GuzzleHttp\Client();
$response = $client->post('https://rsflowhub.com/api/v1/ai/comment-analyze', [
'headers' => [
'Content-Type' => 'application/json',
'X-API-Key' => 'rfh_your_api_key',
],
'json' => array (
'comment' => 'Do you ship to Mumbai? I would love to order this today!',
'platform' => 'Instagram',
'post_context' => 'Photo of our new handcrafted leather boots collection',
'business_context' => 'We are an artisanal e-commerce shop delivering worldwide. Shipping is free within India.',
),
]);
echo $response->getBody();
const response = await fetch('https://rsflowhub.com/api/v1/ai/comment-analyze', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': 'rfh_your_api_key'
},
body: JSON.stringify({"comment":"Do you ship to Mumbai? I would love to order this today!","platform":"Instagram","post_context":"Photo of our new handcrafted leather boots collection","business_context":"We are an artisanal e-commerce shop delivering worldwide. Shipping is free within India."})
});
const data = await response.json();
console.log(data);
import requests
url = "https://rsflowhub.com/api/v1/ai/comment-analyze"
headers = {
"Content-Type": "application/json",
"X-API-Key": "rfh_your_api_key"
}
payload = {"comment":"Do you ship to Mumbai? I would love to order this today!","platform":"Instagram","post_context":"Photo of our new handcrafted leather boots collection","business_context":"We are an artisanal e-commerce shop delivering worldwide. Shipping is free within India."}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
Every RSFlowHub endpoint uses the same envelope, so one parser handles all of them. Failed calls are not charged.
{
"success": true,
"request_id": "req_3f9a2c7e-5b1d-4e8a-9c2f-7d6e1a0b4c8d",
"data": {
"result": {
"sentiment": "positive",
"intent": "purchase_question",
"language": "en",
"topics": [
"pricing",
"availability"
],
"requires_reply": true,
"priority": "high",
"recommended_action": "Reply with a link to the pricing page.",
"confidence": 0.9
}
},
"meta": {
"version": "v1",
"timestamp": "2026-10-05T09:30:00Z"
}
}
{
"success": false,
"request_id": "req_8c1d4e2a-7f3b-4a9c",
"error": {
"code": "VALIDATION_ERROR",
"message": "The given data was invalid.",
"details": {
"comment": [
"This field is required."
]
}
},
"meta": {
"version": "v1",
"timestamp": "2026-10-05T09:30:00Z"
}
}
| Field | Type | Meaning |
|---|---|---|
success | boolean | true when the call worked, false on any error. |
request_id | string | Unique id for this call. Quote it when you contact support. |
data.result | object | The result of this endpoint (see the example). |
error | object | Only on failure: code, message and details per field. |
meta | object | API version and server timestamp. |
All error codes: Errors reference
Detects positive, negative, neutral, and emotional sub-tones such as excitement, curiosity, or frustration.
Automatically flags whether a comment requires an explicit business reply (e.g., shipping inquiries vs casual emojis).
Categorizes comments into pricing, shipping, product feedback, technical support, or general praise.
Contextualized analysis tailored for Instagram, TikTok, YouTube, LinkedIn, and X comment structures.
How teams use the Social Media Comment & Tone Analysis API in production.
Automatically prioritize buyer questions over generic emojis in multi-brand social media inboxes.
{"intent": "shipping_inquiry", "requires_reply": true, "priority": "high", "sentiment": "positive"}Shortens social media response time with ready-to-post reply drafts.
Analyze thousands of viewer comments on sponsored YouTube videos and Instagram reels to measure campaign ROI.
{"intent": "price_complaint", "sentiment": "negative", "topic": "pricing"}Provides instant feedback on product reception.
Flag urgent customer complaints posted on social channels for instant support ticket creation.
{"intent": "delivery_complaint", "requires_reply": true, "priority": "urgent", "sentiment": "negative"}Prevents social PR crises through rapid escalation.
The same job done three ways.
| Topic | RSFlowHub API | Raw LLM prompts | Rules / regex |
|---|---|---|---|
| Output | Validated JSON fields | Free text you have to parse | Fixed patterns only |
| Setup | One POST request, no prompts | Write and maintain prompts and parsing | Write and maintain rule lists |
| Provider outage | Automatic fallback to a backup model | You build retries and a second vendor | Not applicable |
| Pricing | 2 credits per call, failed calls free | Per token, per vendor | Your own servers and upkeep |
| Understands context | Yes, AI model | Yes, AI model | No, keywords only |
Free plan with 100 credits/month + 1,000 bonus credits when you sign in before 23 Nov. Test it in the playground first, no code needed.
Flowy
AI assistant