Forum Discussion

lalitha123's avatar
lalitha123
New Contributor
6 years ago
Solved

Missing Required Headers error

Am getting this error 'Missing Required Headers' in the response. But I can see in the Raw Request, that the Headers are sent.

Here is the raw request :

Client_id and client_secret are the headers that are being sent.

 

POST https://abc.com/trec/restconsumer/v1/profile.do HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: application/json
transaction_id: It8dozMcOKNx5HgfcvXkZXoUYM8k7Bxzmfms0n7faEbyELDXv
Host: abc.com
Accept-Encoding: gzip,deflate
Content-Type: application/json
transaction_id: It8dozMcOKNx5HgfcvXkZXoUYM8k7Bxzmfms0n7faEbyELDXv
client_secret: abc
client_id: abc
Content-Length: 1997
Host: abc.com
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)

 

My colleague has posted the exact same request with the headers and his test seems to run fine. 

This same test worked few months ago with older version of SOAP. My current version is SOAPUI 5.5.0 . I tried uninstalling SOAPUI 5.5.0 and installed SOAPUI 5.4.0. Still no luck. Can you please help.

 

  • lalitha123's avatar
    lalitha123
    6 years ago

    I figured the issue. In the URL endpoint, I gave http vs https . Once I gave https in the URL, the error is no longer seen :)

3 Replies

  • nmrao's avatar
    nmrao
    Champion Level 3
    Check with your team what head is missing, correct it and retest.
    • lalitha123's avatar
      lalitha123
      New Contributor

      Hi Rao,

      The header is already present in the Raw request and it displays the value fine.

      But when I run the test, it fails with the error 'Missing required headers' . Am using the same exact test as my team member. It works for him, but not me :(

      • lalitha123's avatar
        lalitha123
        New Contributor

        I figured the issue. In the URL endpoint, I gave http vs https . Once I gave https in the URL, the error is no longer seen :)