This add-on adds a new session management type which supports an arbitrary number of headers.
The header values can include the following tokens:
{%json:path.to.data%} |
JSON authentication response data | |
{%env:env_var%} |
Environmental variable | |
{%script:glob_var%} |
Global script variable | |
{%header:env_var%} |
Authentication response header | |
{%url:key%} |
Authentication URL param |
When adding Header Based Session Management via the API the headers
parameter is a string of header:value
pairs separated by newline characters: \n
.
Header Based Session Management can be configured in the environment section of an Automation Framework plan using:
sessionManagement:
method: "headers"
parameters: # list of header: value pairs which can include any of the tokens defined above, e.g.
Authorization: "Bearer: {%json:AuthenticationResult.AccessToken%}"
Note that due to restrictions in the core:
These restrictions will be addressed in a future release.
Latest code: HeaderBasedSessionManagementMethodType.java