SDG Document
Get SDG Document
Request
Parameters
document_id*uuidUnique identifier of the document.
Example: "48b8c6bd-471a-423b-87f3-9c287da32967"fields(string (enum))[]Fields to include in the response
Default: ["id", "categories", "country", "cluster_size", "entity_keywords", "entity_id", "url", "extract_date", "dashboard_url", "language", "negative", "neutral", "positive", "polarity", "score", "site_type", "taxonomy_keywords", "title", "datamarts_document_id", "is_high_authority_source", "translated_title"]Values: "id", "categories", "country", "cluster_size", "entity_keywords", "entity_id", "url", "extract_date", "dashboard_url", "language", "negative", "neutral", "positive", "polarity", "score", "site_type", "taxonomy_keywords", "title", "d...translatelanguage-code (enum)In which language to translate the results.
Default translated fields are:
title.If empty,
translated_fields won't be returned.Example:
Values: "af", "afr", "afrikaans", "albanian", "am", "amh", "amharic", "ar", "ara", "arabic", "armenian", "az", "aze", "azerbaijani", "ben", "bengali", "bg", "bn", "bos", "bosnian", "bs", "bul", "bulgarian", "ca", "cat", "catalan", "chinese"...french
Response
Properties of the Document
iduuidUnique identifier of the document.
Example: "48b8c6bd-471a-423b-87f3-9c287da32967"categories(string (enum))[]List of categories assigned to the document.
Values: "SDG:1", "SDG:2", "SDG:3", "SDG:4", "SDG:5", "SDG:6", "SDG:7", "SDG:8", "SDG:9", "SDG:10", "SDG:11", "SDG:12", "SDG:13", "SDG:14", "SDG:15", "SDG:16", "SDG:17"countryiso3166-2 | null (enum)Country of origin of the document. The country code in ISO3166 alpha-2 standard (2 letters).
Values: "ad", "ae", "af", "ag", "ai", "al", "am", "ao", "aq", "ar", "as", "at", "au", "aw", "ax", "az", "ba", "bb", "bd", "be", "bf", "bg", "bh", "bi", "bj", "bl", "bm", "bn", "bo", "bq", "br", "bs", "bt", "bv", "bw", "by", "bz", "ca", "cc"...cluster_sizeintegerNumber of documents in the cluster associated with this document.
A cluster groups documents that are considered identical or highly similar on a daily level.
The value includes the current document (e.g. a value of 200 means 199 other similar documents).
entity_keywordsstring[]Keywords associated with the entity matched in the document.
entity_iduuidPermanent ID of the related entity.
urluriOriginal URL of the document.
Example: "https://domain.com/article#anchor"extract_datestringDate of extraction of the document.
dashboard_urluriLink to the document in SESAMm's Dashboard.
Example: "https://dashboards.textreveal.com/positive-impact-event/48b8c6bd-471a-423b-87f3-9c287da32967"languageiso639-2Language of the document. 3-letter ISO639-2 code.
Example: "fre"negativenumberLevel of negative sentiment towards the entity of interest in the whole document.
Range: [0, 1]neutralnumberLevel of neutral sentiment towards the entity of interest in the whole document.
Range: [0, 1]positivenumberLevel of positive sentiment towards the entity of interest in the whole document.
Range: [0, 1]polaritynumberOverall polarity score of the document.
Range: [-1, 1]scoreintegerIntensity score described in the document.
Range: [1, 5]site_typestring (enum)Type of website.
Values: "news", "blogs", "discussions"taxonomy_keywordsstring[]Keywords associated with the categories matched in the document.
titlestring | nullTitle of the document.
datamarts_document_idstringID of the raw document with no SDG metadata.
is_high_authority_sourcebooleanWhether the source is high authority.
Example: truetranslated_titlestring | nullTranslated version of
Example: "string"titlefield. Seetranslatequery parameter.
{
"id": "48b8c6bd-471a-423b-87f3-9c287da32967",
"categories": [
"SDG:1"
],
"country": "fr",
"cluster_size": 0,
"entity_keywords": [
"string"
],
"entity_id": "00000000-0000-0000-0000-000000000000",
"url": "https://domain.com/article#anchor",
"extract_date": "string",
"dashboard_url": "https://dashboards.textreveal.com/positive-impact-event/48b8c6bd-471a-423b-87f3-9c287da32967",
"language": "fre",
"negative": 0.01,
"neutral": 0.2,
"positive": 0.8,
"polarity": 0.78765434,
"score": 2,
"site_type": "news",
"taxonomy_keywords": [
"string"
],
"title": "string",
"datamarts_document_id": "string",
"is_high_authority_source": true,
"translated_title": "string"
}Error
Bad request
message*stringError message.
Example: "The server returned an unexpected response"code*integerError code.
Example: 400reason*string (enum)Error reason.
Values: "invalid", "timeout", "offline", "unknown", "not_found", "unauthorized", "forbidden", "internal", "too_many_requests"errorsobject[]Possible error causes, like query params, headers or body.
{
"message": "The server returned an unexpected response",
"code": 400,
"reason": "invalid",
"errors": [
{
"message": "Expected number, received string",
"field": "size",
"reason": "invalid_type"
}
]
}Not authorized
message*stringExample: "Not authorized to access this resource"code*number (enum)Error code.
Values: 403reason*string (enum)Values: "forbidden"
{
"message": "Not authorized to access this resource",
"code": 403,
"reason": "forbidden"
}Not found
message*stringExample: "[record] not found."code*number (enum)Error code.
Values: 404reason*string (enum)Values: "not_found"
{
"message": "[record] not found.",
"code": 404,
"reason": "not_found"
}