Divvun API
Documentation for the Divvun API endpoints
Introduction
Welcome to the Divvun API documentation. This API provides endpoints for interacting with the Divvun service.
Base URL
All API endpoints are relative to the base URL:
https://beta.api.giellalt.org
Endpoints
Health Check
GET /health application/json
Check the health status of the API.
Response
{
"status": "ok"
}
Grammar Check
POST /grammar/:tag application/json
Check grammar for text. Available languages:
Request application/json
{
"text": "sami"
}
Response application/json
{
"text": "sami",
"errs": [
{
"error_text": "sami",
"start_index": 0,
"end_index": 4,
"error_code": "typo",
"description": "Ii leat sátnelisttus",
"suggestions": [
"sámi"
],
"title": "Čállinmeattáhus"
}
]
}
Spell Check
POST /speller/:tag application/json
Check spelling for text. Available languages:
Request application/json
{
"text": "sami"
}
Response application/json
{
"text": "sami",
"results": [
{
"word": "sami",
"is_correct": false,
"suggestions": [
{
"value": "sámi",
"weight": 14.529631
},
{
"value": "sama",
"weight": 40.2973
},
{
"value": "sáme",
"weight": 45.896103
},
{
"value": "sabmi",
"weight": 50.2973
},
{
"value": "samai",
"weight": 50.2973
},
{
"value": "sapmi",
"weight": 50.2973
},
{
"value": "satmi",
"weight": 50.2973
},
{
"value": "samo",
"weight": 55.2973
},
{
"value": "samu",
"weight": 55.2973
},
{
"value": "somá",
"weight": 56.623154
}
]
}
]
}
Text-to-Speech
POST /tts/:tag/:voice audio/wav
MP3: add Accept: audio/mpeg header to get MP3 audio instead of WAV.
Convert text to speech. Available languages and voices:
se- davvisámegiella (voices:biretBiret ♀,mahtteMáhtte ♂,sunnaSunná ♀)sma- Åarjelsaemien gïele (voices:aannaAanna ♀)smj- julevsámegiella (voices:abmutÁbmut ♂,nihkolNihkol ♂,siggaSiggá ♀)
Request application/json
{
"text": "Sample text to convert to speech"
}
Response audio/wav
WAV audio file containing the synthesized speech.
Response audio/mpeg
MP3 audio file containing the synthesized speech (if Accept: audio/mpeg header provided)