I created a Physical Service for an external WebService (third part).
In a logical Service (inside a XQuery Extension Function) i am calling the previous Physical Service. However, I need to add some variables in the SOAP Header Request before to call that Physical Service.

Since your webservice accepts a SOAP Header, the wsdl for your webservice should describe that SOAP header (as well as the body). And when ODSI creates the physical data service from the wsdl, the read function will take two arguments - one is the SOAP header and the other is the SOAP body. All you need to do is populate the soap header and body.

If your wsdl does not describe the soap header - fix it so that it does. If need be, make a copy of the wsdl, modify it to describe the soap header, save it in your DataSpace, and then (re)create the physical data service from the wsdl.