Legitimate API
Version 1.0
To be able to make API calls you need to have a Legitimate profile.
After creating a legitimate profile go to https://dev.legitimate.io/apis.html where you can sign up for an API account.
Once you sign up for an account your API credentials will be available in your settings area under "API Settings.

API credentials
To authenticate your call you need to use a Bearer Token made up from your API key and secret.
Uivayfc1Tvk2SED6rEohPvGt:8XCjPrzqCZ11r554JPWDn26g
post
https://www.legitimate.io/api
/verify_article
Verify Article
https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-do-enough-to-combat-fake-news
{
"verified": true,
"profile_first_name": "Niamh",
"profile_last_name": "Campbell",
"profile_title": "Journalist",
"profile_created_at": "2020-04-19T13:36:38.878Z",
"profile_bio": "Journalist with online & print magazine Sync NI, reporting on all things business and technology in Northern Ireland. I often freelance with BBC News and BBC Sport NI, and have contributed to BBC Radio Ulster. I have a regular slot with local Belfast radio station, Blast 106 FM every Sunday evening.",
"profile_employer": "Sync NI ",
"profile_residing": "Belfast",
"profile_slug": "niamh-campbell",
"profile_image": "https://dev.legitimate.io/rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBEdz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--00597287f0a920041807e62056af2c8be8a1f540/QN_8Hk7m_400x400.jpg",
"profile_social_profiles": {
"twitter": "@niamhcam94",
"facebook": "niamhcam94",
"linkedin": "niamh-campbell-374a52139",
"instagram": "ncampboxblog"
},
"user_location": "IRL",
"user_city": "Belfast",
"follower_count": 2,
"article_count": 25,
"articles": [
{
"id": 9558,
"title": "Are tech giants doing enough to combat fake news? ",
"description": "2020 has seen not only a global health pandemic, but a global epidemic of fakes news. Now, the tech giants are trying to combat this, but should it have been tackled long before the present?Whatsapp\r\nSince August, WhatsApp has been piloting a new feature ...",
"link": "https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news",
"profile_id": 18,
"created_at": "2020-09-30T10:24:50.074Z",
"updated_at": "2020-09-30T10:24:50.074Z",
"og_image": "https://d3ku2up3znex6l.cloudfront.net/public/sitereview_listing/41/53/01/150ef_0fbf.jpeg?c=bb3d",
"icon_path": "https://syncni.com//favicon.ico?c=1433",
"published_at": "2020-09-30T10:24:50.072Z",
"post_id": null,
"feature": false,
"lg_index": null,
"tag_list": [
"Tech",
"Fake News",
"social media",
"Opinion"
]
},
{
"id": 1997,
"title": "How is AI helping throughout the Covid-19 pandemic?",
"description": "Back in February 2020, a World Health Organisation report noted that artificial intelligence and big data were a key part of China’s response to the coronavirus outbreak. It has been almost six months since the UK and Ireland went into lockdown due...",
"link": "https://syncni.com/article/4614/how-is-ai-helping-throughout-the-covid-19-pandemic",
"profile_id": 18,
"created_at": "2020-08-07T12:08:53.016Z",
"updated_at": "2020-09-21T23:39:05.246Z",
"og_image": "https://d3ku2up3znex6l.cloudfront.net/public/sitereview_listing/b5/4d/01/14b69_ce44.jpeg?c=341d",
"icon_path": "https://syncni.com//favicon.ico?c=1433",
"published_at": "2020-08-07T12:08:53.016Z",
"post_id": null,
"feature": false,
"lg_index": null,
"tag_list": [
"AI",
"Tech",
"Covid",
"Artificial Intelligence"
]
},
{
"id": 1996,
"title": "Data shows lockdown deprivation causes domino distress on NI's children",
"description": "Back in early April, in the premature stages of lockdown, BBC Newsnight’s Emily Maitlis opened the programme announcing, “They tell us coronavirus is a great leveller. It’s not. It’s much, much harder if you’re poor.” ...",
"link": "https://syncni.com/article/4586/data-shows-lockdown-deprivation-causes-domino-distress-on-ni-s-children",
"profile_id": 18,
"created_at": "2020-08-07T12:06:02.441Z",
"updated_at": "2020-09-21T23:39:05.190Z",
"og_image": "https://d3ku2up3znex6l.cloudfront.net/public/sitereview_listing/e9/4c/01/14a9e_f734.jpg?c=a23b",
"icon_path": "https://syncni.com//favicon.ico?c=1433",
"published_at": "2020-08-07T12:06:02.441Z",
"post_id": null,
"feature": false,
"lg_index": null,
"tag_list": [
"data",
"Children",
"Covid",
"northern ireland"
]
}
]
}
Curl
Javascript
PHP
Python - http.client
Ruby
Java - OKHttp
curl --location --request POST 'https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news' \
--header 'Authorization: Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX'
var myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX");
var formdata = new FormData();
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: formdata,
redirect: 'follow'
};
fetch("https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
import http.client
import mimetypes
from codecs import encode
conn = http.client.HTTPSConnection("dev.legitimate.io")
boundary = ''
payload = ''
headers = {
'Authorization': 'Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX',
'Content-type': 'multipart/form-data; boundary={}'.format(boundary)
}
conn.request("POST", "/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
require "uri"
require "net/http"
url = URI("https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX"
form_data = []
request.set_form form_data, 'multipart/form-data'
response = https.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient().newBuilder()
.build();
MediaType mediaType = MediaType.parse("text/plain");
MediaType JSON = MediaType.parse("application/json; charset=utf-8");
RequestBody body = RequestBody.create(JSON, "{}");
Request request = new Request.Builder()
.url("https://dev.legitimate.io/api/verify_article?url=https://syncni.com/view/4879/are-tech-giants-doing-enough-to-combat-fake-news")
.method("POST", body)
.addHeader("Authorization", "Bearer Ak8fkrk9jf98kjr889:9XdkfkK9H7yy7g76ggTX")
.build();
Response response = client.newCall(request).execute();
Last modified 1yr ago