Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6955745
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:46:39+00:00 2026-05-27T14:46:39+00:00

How would I remove the HTTP headers from a Savon request for example client.request

  • 0

How would I remove the HTTP headers from a Savon request for example

client.request 'v5:ProcessShipments' do
  client.http.headers["SOAPAction"] = "example_post"
end

This would generate

DEBUG -- : SOAPAction: example_post

And the server would respond

Server did not recognize the value of HTTP Header SOAPAction: example_post.

However I dont want to have any SOAPAction(s)

I have tried to clear the variable and delete it. I search for a while and couldn’t find anything so I hope this hasn’t been asked before.

Thanks in advance.

If I dont override it then by default Savon will use the client.request ‘v5:ProcessShipments’, which is also incorrect.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T14:46:40+00:00Added an answer on May 27, 2026 at 2:46 pm

    Here is a quote from savon documentation for the future references:

    SOAPAction is an HTTP header information required by legacy services.
    If present, the header value must have double quotes surrounding the
    URI-reference (SOAP 1.1. spec, section 6.1.1).

    By reading savon source code I figured out that Savon::Client#request method sets “SOAPAction” header automatically before it yields a block. I tried to delete SOAPAction header and it worked:

    require 'savon'
    
    client = Savon::Client.new do
      wsdl.document = "test.wsdl"
    end
    
    client.request :wsdl, "sayHello" do
        http.headers.delete("SOAPAction")
    end 
    

    Here is the request it generates:

    SOAP request: http://www.examples.com/SayHello/
    DEBUG -- : Content-Type: text/xml;charset=UTF-8, Content-Length: 332
    DEBUG -- : 
    <?xml version="1.0" encoding="UTF-8"?>
    <env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                                xmlns:wsdl="http://www.examples.com/wsdl/HelloService.wsdl"
                                xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
        <env:Body>
            <wsdl:sayHello></wsdl:sayHello>
        </env:Body>
    </env:Envelope>
    

    As you can see there is no SOAPAction HTTP header.

    HTH

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to remove a trailing slash from a string. For example if
The following example is taken from: http://php.net/manual/en/function.curl-multi-close.php#example-3540 This example will create two cURL handles,
How would I remove the border from an iframe embedded in my web app?
I would like to remove the domain/computer information from a login id in C#.
I would like to remove two files from a folder at the conclusion of
I would like to remove selected commit log entries from a linear commit tree,
I would like to remove an old JPanel from the Window (JFrame) and add
I would like to remove the upper and left elements from a web page
I need to remove the last line feed from a http webrequest in order
Is this possible.. for example, imagine I respond to a request with a 302

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.