Sometimes, you may just want to have a reviewed percentage based on the actual amount of translated words, rather than total words (including untranslated). The following API endpoint can help you get a percentage of reviewed words vs. translated words:
https://www.transifex.com/api/2/project/project_slug/resource/resource_slug/stats/
The above API endpoint is described in our manual here:
The resulting output per language will look like this:
{
“en_US”: {
“reviewed_percentage”: “0%”,
“completed”: “0%”,
“untranslated_words”: 8,
“last_commiter”: “username_A”,
“reviewed”: 0,
“translated_entities”: 0,
“translated_words”: 0,
“last_update”: “2020-03-02 16:51:29”,
“untranslated_entities”: 4
},
“fr”: {
“reviewed_percentage”: “50%”,
“completed”: “75%”,
“untranslated_words”: 2,
“last_commiter”: “username_A”,
“reviewed”: 2,
“translated_entities”: 3,
“translated_words”: 6,
“last_update”: “2020-03-16 19:09:12”,
“untranslated_entities”: 1
},…
So, in order to calculate the desired percentage, you just need to do the following:
reviewed_words = [reviewed_percentage x (translated_words + untranslated_words)]/100
reviewed_percentage_based_on_translated_words = (reviewed_words x 100)/translated_words