|
Learning with Texts - Fork
2.10.0-fork
Learn foreign languages with texts
|
This documentation provides an overview of the REST API endpoints available for LWT-community. The LWT API allows developers to interact with various features of the application, such as retrieving media paths, getting sentences containing a specific term, managing settings, and more.
The base URL for all API endpoints is: http://[base_url]/api/v1, where base_url is your instance URL (e. g. localhost:8080).
Currently, the LWT API does not require authentication. However, authentication might be implemented in the future. Ensure that appropriate security measures are implemented on the client-side to protect user data.
The REST API should follow semantic versioning. In the API URL, v1 indicates "MAJOR version 1", and so on for the future versions. A track of all changes is kept in the CHANGELOG.md.
Retrieves the files paths to the audio and video files in the media folder.
/media-filesRetrieves how word should be read for a specific language.
/languages/{lang-id}/reading-configurationRetrieves the phonetic reading for any specified term.
/phonetic-readingtext and (lang or lg_id).Retrieves the next word to be reviewed.
/review/next-wordtest_key, selection, word_mode, lg_id, word_regex, typeRetrieves the number of reviews scheduled for tomorrow.
/review/tomorrow-counttest_key and selectionRetrieves sentences that contain the specified term.
/sentences-with-termlg_id, word_lc, and advanced_search (optional)Retrieves sentences that contain the specified term.
/sentences-with-term/{term-id}lg_id and word_lcRetrieves terms similar to the specified term.
/similar-termslg_id and termRetrieves the path for a file using the user theme.
/settings/theme-pathpathRetrieves the terms that were imported.
/terms/importedlast_update, page and countRetrieves the translations for a specific term.
/terms/{term-id}/translationstext_id and term_lcRetrieves statistics for multiple texts.
/texts/statisticstexts_idRetrieves the version of the LWT API.
/versionSaves user settings.
/settingskey and valueSets the annotation for a specific text.
/texts/{text-id}/annotationelem and dataUpdates the audio position for a specific text.
/texts/{text-id}/audio-positionpositionUpdates the reading position for a specific text.
/texts/{text-id}/reading-positionpositionDecrements the status of a term.
/terms/{term-id}/status/downIncrements the status of a term.
/terms/{term-id}/status/upSets the status of a term to a new value.
/terms/{term-id}/status/{new-status}Add a translation for an existing term.
/terms/{term-id}/translationstranslationAdds a new translation for a term.
/terms/newterm_text, lg_id and translationAll API endpoints return responses in JSON format.