https://apisub.masala.one/v2/mediarating
Accepts an image as a public URL in a JSON request and returns a rating as result. The output returned by the API contains the rating of the image represented as below:
With the following rating code definitions:
N/A
{ "RatingCode": "V02", "RatingDescription": "Racy, Provocative", "Confidence": "High" }
curl --request POST "https://apisub.masala.one/v2/mediarating" \ --header "X-Masala-APIKey: xxxxxxxxxxxxxxxxxxxxxxxxxxx" \ --header "Content-Type: application/json" \ --data '{"payload": "https://rebrand.ly/z0i7egt"}'
import requests url = 'https://apisub.masala.one/v2/mediarating' payload = "{\r\n \"payload\": \"https://rebrand.ly/z0i7egt\"\r\n}\r\n" headers = { 'X-Masala-APIKey':'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type':'application/json' } response = requests.request('POST', url, headers=headers, data=payload,allow_redirects=false,timeout=undefined,allow_redirects=false) print(response.text)
var https = require('https'); var options = { 'method': 'POST', 'hostname': 'apisub.masala.one', 'path': '/v2/mediarating', 'headers': { 'X-Masala-APIKey': 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type': 'application/json' } }; var req = https.request(options, function (res) { var chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function (chunk) { var body = Buffer.concat(chunks); console.log(body.toString()); }); res.on("error", function (error) { console.error(error); }); }); var postData = "{\r\n \"payload\": \"https://rebrand.ly/z0i7egt\"\r\n}\r\n"; req.write(postData); req.end();
https://apisub.masala.one/v2/mediaratingb
Accepts an image encoded as a string in Base64 format in a JSON request and returns a rating as result. The output returned by the API contains the rating of the image represented as below:
With the following rating code definitions:
N/A
{
"payload": "b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'"
}
{ "RatingCode": "V02", "RatingDescription": "Racy, Provocative", "Confidence": "High" }
curl --request POST "https://apisub.masala.one/v2/mediaratingb" \ --header "X-Masala-APIKey: xxxxxxxxxxxxxxxxxxxxxxxxxxx" \ --header "Content-Type: application/json" \ --data "{\"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"}"
import requests url = 'https://apisub.masala.one/v2/mediaratingb' payload = "{\r\n \"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"\r\n}\r\n" headers = { 'X-Masala-APIKey':'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type':'application/json' } response = requests.request('POST', url, headers=headers, data=payload,allow_redirects=false,timeout=undefined,allow_redirects=false) print(response.text)
var https = require('https'); var options = { 'method': 'POST', 'hostname': 'apisub.masala.one', 'path': '/v2/mediaratingb', 'headers': { 'X-Masala-APIKey': 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type': 'application/json' } }; var req = https.request(options, function (res) { var chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function (chunk) { var body = Buffer.concat(chunks); console.log(body.toString()); }); res.on("error", function (error) { console.error(error); }); }); var postData = "{\r\n \"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"\r\n}\r\n"; req.write(postData); req.end();
https://apisub.masala.one/v2/humandetectb
Accepts an image encoded as a string in Base64 format in a JSON request and returns a rating along with a probability value for human presence as result. The output returned by the API contains the rating of the image represented as below:
With the following rating code definitions:
N/A
{
"payload": "b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'"
}
{ "HumanPresenceProbability": "1.0", "NudityRating": { "RatingCode": "V01", "RatingDescription": "2", "Confidence": "High" } }
curl --request POST "https://apisub.masala.one/v2/humandetectb" \ --header "X-Masala-APIKey: xxxxxxxxxxxxxxxxxxxxxxxxxxx" \ --header "Content-Type: application/json" \ --data "{\"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"}"
import requests url = 'https://apisub.masala.one/v2/humandetectb' payload = "{\r\n \"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"\r\n}\r\n" headers = { 'X-Masala-APIKey':'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type':'application/json' } response = requests.request('POST', url, headers=headers, data=payload,allow_redirects=false,timeout=undefined,allow_redirects=false) print(response.text)
var https = require('https'); var options = { 'method': 'POST', 'hostname': 'apisub.masala.one', 'path': '/v2/humandetectb', 'headers': { 'X-Masala-APIKey': 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type': 'application/json' } }; var req = https.request(options, function (res) { var chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function (chunk) { var body = Buffer.concat(chunks); console.log(body.toString()); }); res.on("error", function (error) { console.error(error); }); }); var postData = "{\r\n \"payload\": \"b'/9j/4AAQSkZJRgABAQEAYABgAAD/2wBD...'\"\r\n}\r\n"; req.write(postData); req.end();
https://text.masala.one/v1/textratingAccepts text in segments in a JSON request and returns a toxicity score as an indication of probability. The detected toxicity currently covers various aspects ranging from aggressive language, to profanity, and sexually explicit content. The output returned by the API contains the rating of the content toxicity represented as below:
N/A
{
"payload": "Sample text segment provided here"
}
{ "Description": "Safe", "RatingCode": "V01", "Scores": { "Hate": "0.0019561406", "Insult": "0.0015367505", "Obscene": "0.0052989633", "Severely Toxic": "0.00064276945", "Sexually Explicit": "0.0007140828", "Threat": "0.00077044003", "Toxic": "0.007277018" } }
curl --request POST "https://text.masala.one/v1/textrating" \ --header "X-Masala-APIKey: xxxxxxxxxxxxxxxxxxxxxxxxxxx" \ --header "Content-Type: application/json" \ --data '{"payload":"Sample text segment provided here"}'
import requests url = 'https://text.masala.one/v1/textrating' payload = "{\r\n \"payload\": \"Sample text segment provided here\"\r\n}\r\n" headers = { 'X-Masala-APIKey':'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type':'application/json' } response = requests.request('POST', url, headers=headers, data=payload,allow_redirects=false,timeout=undefined,allow_redirects=false) print(response.text)
var https = require('https'); var options = { 'method': 'POST', 'hostname': 'text.masala.one', 'path': '/v1/textrating', 'headers': { 'X-Masala-APIKey': 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', 'Content-Type': 'application/json' } }; var req = https.request(options, function (res) { var chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function (chunk) { var body = Buffer.concat(chunks); console.log(body.toString()); }); res.on("error", function (error) { console.error(error); }); }); var postData = "{\r\n \"payload\": \"Sample text segment provided here\"\r\n}\r\n"; req.write(postData); req.end();
1