curl --request GET \
--url https://api.consensus.app/v1beta/papers/references \
--header 'x-api-key: <api-key>'import requests
url = "https://api.consensus.app/v1beta/papers/references"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.consensus.app/v1beta/papers/references', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.consensus.app/v1beta/papers/references",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.consensus.app/v1beta/papers/references"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.consensus.app/v1beta/papers/references")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.consensus.app/v1beta/papers/references")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"results": [
{
"paper_id": "<string>",
"full_text_available": true,
"abstract": "<string>",
"authors": [
"<string>"
],
"doi": "<string>",
"journal_name": "<string>",
"pages": "<string>",
"publish_year": 123,
"title": "<string>",
"url": "<string>",
"volume": "<string>",
"citation_count": 123,
"semantic_score": 123,
"study_type": "<string>",
"takeaway": "<string>",
"publisher_name": "<string>",
"full_text_chunks": [
"<string>"
],
"sjr_best_quartile": 123,
"sample_size": 123,
"study_count": 123,
"population_type": "<string>",
"is_preprint": true,
"countries_of_study": [
"<string>"
],
"study_duration_days": 123,
"influential_citation_count": 123,
"institutions": [
"<string>"
],
"publish_date": "<string>",
"institutional_access_url": "<string>",
"seeds_touched": 123
}
],
"page": 123,
"page_size": 123,
"is_end": true,
"credits_charged": 123,
"next_page": 123,
"unmatched_dois": [
"<string>"
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Get references
Find the papers that a set of seed papers cites, up to 20 seeds in one request. Each paper comes back in the same shape as a search result.
Which seeds: pass paper_ids (the paper_id on search, Thread, citations or references results), dois, or both. 1 to 20 in total. DOIs that match no Consensus paper come back in unmatched_dois.
Several seeds: each paper carries seeds_touched, how many of the seeds cite it. With the default sort, papers cited by more of the seeds rank first.
Filters and order: year_min, year_max and cite_min narrow the results. sort is recency_weighted (the default), most_cited or most_recent.
Paging: page starts at 0 and page_size defaults to 20, up to your plan’s maximum. Request next_page until is_end is true. Paging reaches the first 10,000 papers.
Cost: 1 credit per 100 papers returned, rounded up, with a minimum of 1 per request. credits_charged shows what the request used.
Access: paid plans only. A 403 means citations aren’t available to your key.
Rate limit: 1 request per second.
curl --request GET \
--url https://api.consensus.app/v1beta/papers/references \
--header 'x-api-key: <api-key>'import requests
url = "https://api.consensus.app/v1beta/papers/references"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.consensus.app/v1beta/papers/references', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.consensus.app/v1beta/papers/references",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.consensus.app/v1beta/papers/references"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.consensus.app/v1beta/papers/references")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.consensus.app/v1beta/papers/references")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"results": [
{
"paper_id": "<string>",
"full_text_available": true,
"abstract": "<string>",
"authors": [
"<string>"
],
"doi": "<string>",
"journal_name": "<string>",
"pages": "<string>",
"publish_year": 123,
"title": "<string>",
"url": "<string>",
"volume": "<string>",
"citation_count": 123,
"semantic_score": 123,
"study_type": "<string>",
"takeaway": "<string>",
"publisher_name": "<string>",
"full_text_chunks": [
"<string>"
],
"sjr_best_quartile": 123,
"sample_size": 123,
"study_count": 123,
"population_type": "<string>",
"is_preprint": true,
"countries_of_study": [
"<string>"
],
"study_duration_days": 123,
"influential_citation_count": 123,
"institutions": [
"<string>"
],
"publish_date": "<string>",
"institutional_access_url": "<string>",
"seeds_touched": 123
}
],
"page": 123,
"page_size": 123,
"is_end": true,
"credits_charged": 123,
"next_page": 123,
"unmatched_dois": [
"<string>"
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Query Parameters
Seed DOIs, with or without a https://doi.org/ or doi: prefix. Repeat the parameter for several. A DOI that names no Consensus paper comes back in unmatched_dois.
recency_weighted: papers linked to more of the seeds first, then by how fast they are cited, so new papers are not buried. most_cited: highest citation count first. most_recent: newest first, most cited first within a year.
recency_weighted, most_cited, most_recent Response
Successful Response