Sentiment Analysis API

This API allows you to extract sentiments from text you gathered.


Personal Access Token

To make calls to the Data Source Management API, you need to first obtain your personal access token. Your personal access token can be found in your settings page under the developer settings section


Extract sentiments

Get sentiments from text

Call Structure

POST https://getdata.io/sentiment

HEADERS
  Authorization: Bearer :PERSONAL_ACCESS_TOKEN

BODY
{
  news_headline: :RAW_TEXT
}

Supported Params

PERSONAL_ACCESS_TOKEN Required String Your personal access token that can be obtained from your developer settings page
RAW_TEXT Required String A string you want to extract sentiments from

Sample JSON Request

POST https://getdata.io/sentiment
HEADER: 
  Authorization: Bearer :PERSONAL_ACCESS_TOKEN

BODY:
{
  "news_headline": "Facebook employees are in disbelief that a bombshell memo justifying questionable practices to grow at all costs was leaked and some think spies might be to blame"
}

Sample JSON Response

{
  "polarity": -0.5,
  "subjectivity": 1.0,
  "noun_phrases": [
    "facebook",
    "bombshell memo",
    "questionable practices",
    "disbelief",
    "bombshell",
    "memo"
  ]
}


More resources

To find out more about how GetData.IO works