Web Service Connector tool – How to map a Constant to a HTTP header

In some cases a web service may require authentication or a string passed in the header. If this needs changing or editing you may want to use a Constant. This will allow you to make the change once instead of changing every operation.

This can be achieved as follows:

  1. Open your web service global connection and begin by creating a Constant within the Constants tab.1
  2. Within the Operationstabopen your operation and click Advanced. This will open the following:2
  3. Enter the name of theheader into theHeader Name column(this may be different per web service).
  4. The Header Valuerequires the name of the Constant in the following format:{=ThisService.Constants(“[CONSTANT NAME]“)}In this example the Constants name is auth_string, in the Header Value column the value will be:{=ThisService.Constants(“auth_string“)}3