For the complete documentation index, see llms.txt. This page is also available as Markdown.

Retrieving content and translations

Interface api.repository.v1 provides mechanisms that allow dynamic retrieval of the contents of artifacts of type Content (TextContent) defined in the Eximee Designer module. This functionality is crucial when a script must return an error message, generate dynamic text for the user interface, or send a message to an external system, taking into account centralized multilingual mechanisms (i18n).

Availability: The functionality is available from platform version 3.332.0.

API methods

The process of retrieving a specific text consists of a chained call of three methods, which first locate the artifact itself, then select the appropriate language dictionary, and finally return the extracted plain text.

Method / Call
Return type
Operation description

api.repository.v1.textContent(name, version)

Object

Finds an artifact with the specified name in the repository name and version version. Most often, the character "*" (meaning the latest available).

.language(langCode)

Object

Method called on the artifact object. It specifies a particular language code (e.g. "pl", "en").

.text()

String

Method called on the language object. Returns the target translated text value.

Error handling and missing artifact

When retrieving content, special caution is required, because the engine rigorously verifies the correctness and existence of identifiers.

Usage examples

1. Retrieving the optimistic variant (Happy Path)

If we are absolutely sure that a given artifact exists in the database and has been published in the specified language, we can use the shortened form.

In a production environment – especially when search keys or language codes are passed dynamically (e.g. based on a parameter from context or the user's profile preferences) – errors should always be safely caught. This allows a fallback text to be returned instead of interrupting the entire script.

Last updated

Was this helpful?