Skip to main content

Groovy Script

Explanation

This script performs the following operations:
  1. SOAP Message Preparation: SOAP Envelope, Header and Body are created
  2. HTTP Request: SOAP message is sent with HTTP POST request
  3. Response Parse: Incoming SOAP response is parsed
  4. Token Extraction: Token value is extracted from response
  5. Adding to Header: Token value is added to header
This script should be run on the request line (Request Policy) because it uses the requestHeaderMapToTargetAPI variable.