Articles in this section

base64Encode helper

Use the base64Encode helper to encode a given string or field value into UTF-8. Since this helper produces raw encoded output, Celigo recommends using triple braces ({{{ }}}). base64Encode only supports concatenation, not encoding formats.

Usage

{{{base64Encode base64String}}}
  • base64String: The input string or field (e.g., record.connection.http.unencrypted.apiKey) to be encoded.

Example

  1. Encoding a single field 

    {{{base64Encode record.email}}}

    If record.email is "jane.doe@example.com", it becomes something like "amFuZS5kb2VAZXhhbXBsZS5jb20=".

  2. Combining username and password 

    {{{base64Encode (join ":" connection.http.unencrypted.username connection.http.encrypted.secret)}}}

    If username=alice and secret=hunter2, the join form returns YWxpY2U6aHVudGVyMg== (base64 of alice:hunter2).

Tip

  • Always use triple braces ({{{ }}}) to prevent Celigo’s automatic quoting or formatting of the encoded string.

  • Make sure your input is a valid string; otherwise, the helper may produce unexpected output or an error.