TranslatePress ability reference
Reference for the GoBuildWP Pro 1.12.4 source. Installed schemas and policy remain authoritative.
This TranslatePress ability reference covers existing page-string translations in a selected secondary language. It works with strings TranslatePress has collected as pages are viewed, rather than generating a complete translated site from an unseen page.
Read-only, write and destructive groups describe the source annotations. They do not establish a minimum safety profile, human approval or undo support. Those controls are separate: check the installed ability, the connected user and the active site policy before calling it. A read can still return sensitive data. These pages are not evidence that every operation passed an end-to-end runtime test.
What TranslatePress needs before these load
GoBuildWP Pro and an active, supported TranslatePress installation. The connected user needs manage_options. Choose a configured secondary language whose dictionary contains the strings you want to review.
- TranslatePress editions
- free, pro
Find the right string before writing
List strings in the target language and filter by text or translation status. Keep the returned IDs with their original text so repeated phrases are not confused. An empty dictionary may mean the page has not yet been viewed in that language.
Review language and recovery
Write at most 100 ID-and-translation pairs per call. Writes use TranslatePress's update_strings method and mark the result human-reviewed, so review the proposed language before applying it. That stored status is not evidence that a translator has approved an AI-generated suggestion.
Undo records each previous translation and status, restores them through the same API and reads them back to verify. Theme and plugin gettext strings are outside this module's scope. Inspect the translated page for context, links and layout after changing its strings.
Representative call sequence
This sequence describes the documented calls and checks to perform. It is not a recorded result from an installed WordPress site. Inspect returned errors and partial results, then verify the saved values and affected output before proceeding.
Correct the Spanish wording of an existing contact page.
- 01
wppilot/translatepress-list-stringsFind the collected page strings and inspect their existing translations and IDs. - 02
wppilot/translatepress-set-translationsApply the reviewed replacements in a bounded batch, then open the Spanish page to verify them in context.
Where these two calls fit next to TranslatePress's own
What TranslatePress does itself, and what these two add
TranslatePress registers abilities of its own for the language list: adding and removing languages, choosing the default and switching on automatic translation. What it does not offer is a way to read or write one translated string, which is where an agent adding a language usually gets stuck. These two GoBuildWP Pro 1.12.0 calls cover that: one lists the strings TranslatePress has collected from the site for a language, with the status of each, and the other saves translations, up to 100 per call.
A typical run lists the untranslated strings for one language, drafts translations, shows them to a person, and saves the approved batch. Saved strings are marked as reviewed by a person, so TranslatePress's automatic translation does not overwrite them later. Each save can be undone from the change log, which writes back every string's previous translation and status and reads them again to confirm.
Before you rely on it
Strings appear in the list only after TranslatePress has seen them, which normally means after the page has been visited in that language. A page nobody has opened since it changed may be missing strings; open it once in the target language, then list again. Machine-translated strings keep their status until a person, or a save through this ability, marks them reviewed.
TranslatePress reads
| Ability | What it does |
|---|---|
wppilot/translatepress-list-stringsList TranslatePress Strings | Lists the page strings TranslatePress has collected for one translation language, with their translation and status (untranslated, machine, human). status filters: untranslated (default), machine, human, translated (any translation), all. search matches the original or the translation. TranslatePress collects strings as pages are viewed in that language, so a page nobody opened in it has no strings yet. Translate them with wppilot/translatepress-set-translations. |
TranslatePress writes
| Ability | What it does |
|---|---|
wppilot/translatepress-set-translationsSet TranslatePress Translations | Saves translations for up to 100 TranslatePress strings in one language, as its translation editor does, and marks them human-reviewed so automatic translation does not overwrite them. translations is a list of {id, translated}, ids from wppilot/translatepress-list-strings. Keep HTML tags and placeholders such as %s exactly as in the original. Undo puts back each string's previous translation and status. |