Guides

Publish and Use Bundles

Bundles are the JSON files your app can read at runtime or during a build.

Publish a Release

POST /v1/i18n/projects/project_123/releases
Authorization: ApiKey lez_...
Content-Type: application/json
{
  "environment": "production",
  "version": "1.0.0",
  "reviewedOnly": true,
  "locales": ["en", "nl", "fr"]
}

Use reviewedOnly: true when you only want reviewed values in the release.

Fetch a Bundle

GET /v1/i18n/bundles/project_123/production/nl

The response includes the bundle messages and content for the selected locale.

Use It In An App

Your app can load a bundle and read UI translation keys from messages:

const response = await fetch("https://api.lezu.app/v1/i18n/bundles/project_123/production/nl");
const bundle = await response.json();

console.log(bundle.data.messages["home.title"]);

The content object is reserved for long-form markdown/text content.

Release Tips

  • Publish releases from CI after source content changes.
  • Use development environments for testing bundle output.
  • Use production environments for live app traffic.
  • Keep release versions meaningful for your team, such as app version numbers or dates.