Ask a Question

How to set http-headrar before a wsdl-definition is retrieved

New Contributor

How to set http-headrar before a wsdl-definition is retrieved


I have a problem, I need to retrieve a wsdl-definition with an url-address i order to create a SOAP-project, eg.



the problem is that I need to set a couple of HTTP-headrar that contains a "ticket" in order to grant access to the server. I cannot find a way to do this in SOAP-ui, you can set HTTP-headrar in restrospect, but I need to sett the http-headrar before I can retrieve the wsdl-definition. 


It should be a solution to this.

BR Alvaro

SmartBear Alumni (Retired)

Hi @alvarogrm,

Thanks for reaching out.


Community, has anyone faced a similar task? Can you please assist?


Olga Terentieva
SmartBear Assistant Community Manager

Champion Level 2



My best understanding of question is how to set a header...


In some groovy script that sets property values in a "Properties" named test step, set the desired header content:

   def xrequestid = UUID.randomUUID().toString();
   testRunner.testCase.testSteps["Properties"].setPropertyValue( "x-request-id-value-str", xrequestid);

   def xclientType = 'admin';
   testRunner.testCase.testSteps["Properties"].setPropertyValue( "x-client-type-value-str", xclientType);


In headers tab of the request, define Header column value of what is actually needed for the request.  In the Value column of the tab, use property expansion to set it to what is contained in the "Properties" named test step...  


Header             |      Value

----------             |     ----------

x-request-id      |     ${Properties#x-request-id-value-str}

x-client-type      |     ${Properties#x-client-type-value-str}


I hope I interpreted your question as you meant it.  🙂

SmartBear Alumni (Retired)

Hi all,


@TNeuschwanger, thank you for your time looking into this, I sincerely appreciate the assistance.

@alvarogrm, have you had a chance to check the solution on your side? Does this work for you?


Olga Terentieva
SmartBear Assistant Community Manager



I havn't had the time, but our test-expert is going to try out the solution, I still appreciate the effort you made in order to help us/me.

BR Alvaro



our test-expert told me that i doesn't solve the issue, what the solution describes is how to set properties (http-headrar) when invoking the WebService (SOAP), what we want to do is the following:


1) Setting two http-headrar in SOAP-UI (before the project is created or before a wsdl-definition is used), e.g.



2) Now create a soap-ui SOAP-project using and url, eg.


The problem is that the server uses two security mechanism first cert (no problem here) and apart from that further information must be supplied in the http-header before you can actually communicate with the server, meaning that you cannot get the wsdl-definition from the server if the http-headers are not set.

BR Alvaro

Hi Alvaro,


If it is that difficult to get wsdl content through the manually crafted request in SoapUI, may it be an option to get wsdl using any other means (e.g. web browser), save it to the file and use the saved file in SoapUI then? (By specifying it for the Initial WSDL field instead of web address.)


  /Alex [Community Champion]
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
Showing results for 
Search instead for 
Did you mean: