Skip to main content

Social media ROI calculator API

Enter the revenue social media brought in and what it cost (ads, tools, hours, content), and get the ROI, the net return and where the money went.

Request​

FieldTypeDefaultDescription
revenuenumberRevenue attributed to social media in the period, in USD.
costsobjectWhat social media cost in the period, in USD. Every field is optional.
periodstringOptional label for the period, e.g. "Q3 2026".

Call it​

curl -X POST https://postboost.co/app/api/tools/social-media-roi-calculator \
-H 'Content-Type: application/json' \
-d '{"revenue":5000,"costs":{"ad_spend":1000,"labor_hours":10,"hourly_rate":50}}'

With a token, send Authorization: Bearer YOUR_API_TOKEN as a default header (how, per SDK).

Response​

{
"period": null,
"revenue": 5000,
"total_cost": 1500,
"net_return": 3500,
"roi_percent": 233.3,
"cost_breakdown": [
{
"key": "ad_spend",
"label": "Ad spend",
"amount": 1000,
"share_percent": 66.7
},
{
"key": "labor",
"label": "Labor",
"amount": 500,
"share_percent": 33.3
}
],
"warnings": [],
"formula": "(5,000 − 1,500) ÷ 1,500 × 100 = 233.3%"
}

With MCP​

Connect https://postboost.co/mcp/tools (setup) and ask, for example: Calculate social media ROI with the PostBoost calculate-social-roi tool.

Errors​

StatusWhen
401The Authorization header holds an invalid token. Leave it out to call as a guest.
413The JSON body is larger than 128 KB.
422A field is invalid; the body lists the errors per field.
429A limit is reached; see limits.