Introduction
This is the API for the Social Media Value Calculator
You can Also use api.socialmediavalue.io as base url. Important the standard currency is USD If you want to get a different currency you have to give it as parameter "
Authenticating requests
This API is not authenticated.
Endpoints
POST /facebook
Example request:
curl --request POST \
"socialmediavalue.io/facebook" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"impressions\": 50,
\"reactions\": 7,
\"comments\": 20,
\"shares\": 13,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/facebook"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"impressions": 50,
"reactions": 7,
"comments": 20,
"shares": 13,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/facebook';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'impressions' => 50,
'reactions' => 7,
'comments' => 20,
'shares' => 13,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/facebook'
payload = {
"impressions": 50,
"reactions": 7,
"comments": 20,
"shares": 13,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST /instagram
Example request:
curl --request POST \
"socialmediavalue.io/instagram" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"impressions\": 50,
\"likes\": 1,
\"comments\": 6,
\"saved\": 3,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/instagram"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"impressions": 50,
"likes": 1,
"comments": 6,
"saved": 3,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/instagram';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'impressions' => 50,
'likes' => 1,
'comments' => 6,
'saved' => 3,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/instagram'
payload = {
"impressions": 50,
"likes": 1,
"comments": 6,
"saved": 3,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST /twitter
Example request:
curl --request POST \
"socialmediavalue.io/twitter" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"impressions\": 50,
\"likes\": 11,
\"comments\": 13,
\"retweets\": 5,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/twitter"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"impressions": 50,
"likes": 11,
"comments": 13,
"retweets": 5,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/twitter';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'impressions' => 50,
'likes' => 11,
'comments' => 13,
'retweets' => 5,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/twitter'
payload = {
"impressions": 50,
"likes": 11,
"comments": 13,
"retweets": 5,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST /youtube
Example request:
curl --request POST \
"socialmediavalue.io/youtube" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"views\": 50,
\"likes\": 17,
\"comments\": 13,
\"shares\": 2,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/youtube"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"views": 50,
"likes": 17,
"comments": 13,
"shares": 2,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/youtube';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'views' => 50,
'likes' => 17,
'comments' => 13,
'shares' => 2,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/youtube'
payload = {
"views": 50,
"likes": 17,
"comments": 13,
"shares": 2,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Post /linkedin
Example request:
curl --request POST \
"socialmediavalue.io/linkedin" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"impressions\": 50,
\"likes\": 5,
\"comments\": 13,
\"shares\": 14,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/linkedin"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"impressions": 50,
"likes": 5,
"comments": 13,
"shares": 14,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/linkedin';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'impressions' => 50,
'likes' => 5,
'comments' => 13,
'shares' => 14,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/linkedin'
payload = {
"impressions": 50,
"likes": 5,
"comments": 13,
"shares": 14,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST /tiktok
Example request:
curl --request POST \
"socialmediavalue.io/tiktok" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"views\": 50,
\"likes\": 14,
\"comments\": 10,
\"shares\": 20,
\"currency\": \"USD\"
}"
const url = new URL(
"socialmediavalue.io/tiktok"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"views": 50,
"likes": 14,
"comments": 10,
"shares": 20,
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$url = 'socialmediavalue.io/tiktok';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'views' => 50,
'likes' => 14,
'comments' => 10,
'shares' => 20,
'currency' => 'USD',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'socialmediavalue.io/tiktok'
payload = {
"views": 50,
"likes": 14,
"comments": 10,
"shares": 20,
"currency": "USD"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Example response (200):
{
"result": 1,
"currency": "USD"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.