How to use FTL in API request response transformation

How to use FTL in API

FTL [FreeMarker Template Language] in vConnect is used for templates.

Steps for that are:

  1. Go to API management.
  2. While configuring any API, In End point details you will get an option of ‘Request Transformation’ on the right side. Which is used to transform the request or response accordingly.
  3. In that we have different options: ‘Simple request’ is for response transformation. whereas, ‘Complex’ is for response and request both.
  4. After providing that , You have to provide the params in ‘Template Body Parameters Mapping’ section.

For example:

{
  "name": "${name}",
  "mobileNo": ${mobileNo},
  "password": "${password}",
  "designation": "${designation}",
  "branch": ${branch},
  "department": "${department}",
  "status": "${status}",
  "empcode": "${empcode}",
  "role": "${role}"
}

2 Likes

How to use FTL in API

FTL [FreeMarker Template Language] in vConnect is used for templates.

Steps for that are:

  1. Go to API management.
  2. While configuring any API, In End point details you will get an option of ‘Request Transformation’ on the right side. Which is used to transform the request or response accordingly.
  3. In that we have different options: ‘Simple request’ is for response transformation. whereas, ‘Complex’ is for response and request both.
  4. After providing that , You have to provide the params in ‘Template Body Parameters Mapping’ section.

For example:

{
  "name": "${name}",
  "mobileNo": ${mobileNo},
  "password": "${password}",
  "designation": "${designation}",
  "branch": ${branch},
  "department": "${department}",
  "status": "${status}",
  "empcode": "${empcode}",
  "role": "${role}"
}

3 Likes