Skip to main content

Transformer Libraries

A Transformer Library is a reusable block of code that you can share across multiple Transformer tasks in your Flows. Instead of copying the same helper functions, types, or interfaces into every Transformer, you write them once in a library and reference that library wherever you need it.

Transformer Libraries are part of Integration Flows, and are designed to keep your custom code organised, consistent, and easy to maintain.

Why use a library?

  • Reuse – write a helper once and use it in many Flows.
  • Consistency – everyone builds on the same trusted functions and types.
  • Maintainability – fix or improve code in one place and roll it out everywhere.
  • Governance – changes go through an approval step before they go live.

Concepts & glossary

TermDescription
Library ModuleA reusable code module that Transformer tasks can reference.
VersionEach change to a library produces a new, numbered version (v1, v2, …).
DraftA work-in-progress version you can edit before it is submitted for approval.
PublishedAn approved version that is live and available to your Flows.
Repository-managed libraryA library whose code is sourced directly from a connected Git repository. See Repository Connections.

How versioning works

Transformer Libraries use the same familiar versioning and approval model used elsewhere in Fenergo (Flows, Policy, Reference Data, etc.). A library can only be edited within a draft, and a draft has to be approved before it goes live:

  1. Create a library – this starts as a draft (v1).
  2. Edit the draft until the code is ready.
  3. Submit the draft for approval.
  4. Approve (or reject) the draft. Once approved, it becomes a published version.
  5. Create a new draft from the latest published version whenever you need to make further changes – this becomes the next version (v2, v3, …).

Your Flows always use the latest published version, so work-in-progress drafts never affect live integrations until they are approved.

Authoring helpers

When building a library you can speed up authoring with two built-in helpers:

  • Generate types from an API specification – provide an OpenAPI specification and generate matching types automatically.
  • Fetch a specification from a URL – load a specification directly from a remote address.

Guides