API Documentation - Response

The response is always in json format. It contains the analyzed text and the language of the text, and for every requested service the response contains a block. The content of the response block is service-specific and contains the actual analysis result for this service. For clear documentation, the response block will be omitted here, but will be described later in detail for each service.

Response Format

An empty result list will be returned if a service has successfully analyzed the text, but found no results. In case of an error of a single service, the returned HTTP status will be 200 and the response content will contain the results of all the services, except for the failed service block.

Description of each field:

text

The analyzed text. If you passed an URL, the extracted plain text (with boiler plate removal) will be displayed. If you passed an plain text within the parameter 'text', the unchanged text will be shown.

language

The language for the text, eg "de" , "en", or "ru" or others.

timestamp

The timestamp of the response (in milliseconds since January 1, 1970).

Response Format: Entities

{

entities: [

{

confidence: 47.150089263916016,

end: 13,

label: "Angela Merkel",

start: 0,

surface: "Angela Merkel",

type: "PERSON",

uri: "https://www.wikidata.org/wiki/Q567"

},

{

confidence: 46.01070785522461,

end: 47,

label: "Hamburg",

start: 40,

surface: "Hamburg",

type: "PLACE",

uri: "https://www.wikidata.org/wiki/Q1055"

},

{

confidence: 75.0,

end: 74,

label: null,

start: 52,

surface: "Angela Dorothea Kasner",

type: "PERSON",

uri: null

}

]

}

Description of each field:

label

The unique label of the entity.

surface

The surface form of the entity in the text.

type

Type of entity. Possible values ​​are "PERSON", "PLACE", "ORGANISATION", "JOB TITLE", "WORK", "EVENT", "CONCEPT". This is determined heuristically and may vary in some cases from the expected value. Example: A city can act as an employer and can be therefore classified as an organization.

uri

The Wikidata URI of the named entity. Set to 'null' if there is no entity URI in the Wikidata knowledge base.

confidence

Confidence value about the discovered entity. A higher value represents a more secure detection. The upper value of the confidence is unlimited.

start

The start position of the entity in the text.

end

The end position of the entity in the text.

Response Format: Entities ML

The machine learning (ML) Service uses a machine learning model to detect the correct entities. Generally speaking, it is more accurate for lesser known entities as they may occur in blog posts. For more well-known entities - as they often occur in news articles - the regular entity service will generally perform better. If you are unsure which service to pick, use the regular Entity service. The response format of the Entity ML service is identical to that of the regular Entity service.

Response Format: Tags

{

tags: [

{

confidence: 0.9967904107197822,

term: "Angela Merkel"

},

{

confidence: 0.9927268430144784,

term: "Juli"

},

{

confidence: 0.9751561498425574,

term: "Hamburg"

},

{

confidence: 0.7406453816287002,

term: "Angela Dorothea Kasner"

}

]

}

Description of each field:

term

The found Keyword.

confidence

The confidence value of the phrase. The value is always between 0 to 1.

Response Format: Dates

{

dates: [

{

dateEnd:

{

bc: false,

day: 17,

month: 7,

year: 1954

}

dateStart:

{

bc: false,

day: 17,

month: 7,

year: 1954

}

end: 36,

start: 23,

surface: "17. Juli 1954"

}

]

}

Description of each field:

surface

The surface form of the date in the text.

start

The start position of the date in the text.

end

The final position of the date in the text.

dateStart

The start date. A date is always represented as time periods, e.g. start and end date may have the same value.

dateEnd

The end date.

day

The day of the start or end date. Possible values ​​are 1-31.

month

The month of the start or end date. Possible values ​​are 1-12.

year

The year of the start or end date.

bc

Describes whether the date refers to the time before Christ. Possible values ​​are true and false.