handleInject function in the endpoint settings or via CLI.
Restrictions
- The inject transformer is supported only for webhook- and socket-based endpoints.
-
The return value is validated against a set of rules. If these rules aren’t met, the transformer throws an error. The following rules apply:
userIdis a string with up to 256 characters.sessionIdis a string with up to 256 characters.textis a string with up to 10,000 characters.datais an object.
Transformer function arguments
The following table shows an overview of the function arguments:Endpoint configuration object
endpoint object properties
endpoint object properties