Consuming a SOAP Service using Savon Gem

Discussion in 'Ruby' started by Saeed Bhuta, Jul 13, 2010.

  1. Saeed Bhuta

    Saeed Bhuta Guest

    Hi,

    I am trying to consume a SOAP service using the Savon gem but having
    difficulty.

    My code:

    "require 'rubygems'
    require 'savon'

    # Client instance with a WSDL endpoint
    client = Savon::Client.new
    "http://realtime.nationalrail.co.uk/ldbws/wsdl.aspx"

    p client.wsdl.namespace_uri

    p client.wsdl.soap_actions

    response = client.get_arrival_board"

    The error I am getting:

    "D, [2010-07-13T11:38:58.967684 #3909] DEBUG -- : Retrieving WSDL from:
    http://realtime.nationalrail.co.uk/ldbws/wsdl.aspx
    "http://thalesgroup.com/RTTI/2008-02-20/ldb/"
    []
    /home/abcb293/.gem/ruby/1.8/gems/savon-0.7.9/lib/savon/client.rb:92:in
    `method_missing': undefined method `get_arrival_board' for
    #<Savon::Client:0xb7597218> (NoMethodError)
    from natrail.rb:11"

    Appreciate any help.
    --
    Posted via http://www.ruby-forum.com/.
    Saeed Bhuta, Jul 13, 2010
    #1
    1. Advertising

  2. Saeed Bhuta

    Bruce Loving Guest

    check the results of the soap_actions
    usually a misspelling of the action

    > p client.wsdl.soap_actions
    >
    > response = client.get_arrival_board"
    >
    > `method_missing': undefined method `get_arrival_board' for

    --
    Posted via http://www.ruby-forum.com/.
    Bruce Loving, Jul 13, 2010
    #2
    1. Advertising

  3. Saeed Bhuta

    Saeed Bhuta Guest

    Bruce Loving wrote:
    > check the results of the soap_actions
    > usually a misspelling of the action
    >
    >> p client.wsdl.soap_actions
    >>
    >> response = client.get_arrival_board"
    >>
    >> `method_missing': undefined method `get_arrival_board' for


    p client.wsdl.soap_actions doesn't return anything...
    --
    Posted via http://www.ruby-forum.com/.
    Saeed Bhuta, Jul 13, 2010
    #3
  4. Saeed Bhuta

    Tony Arcieri Guest

    [Note: parts of this message were removed to make it a legal post.]

    On Tue, Jul 13, 2010 at 6:55 AM, Saeed Bhuta <>wrote:

    > p client.wsdl.soap_actions doesn't return anything...
    >


    It doesn't look like there are any SOAP actions in your WSDL

    --
    Tony Arcieri
    Medioh! A Kudelski Brand
    Tony Arcieri, Jul 13, 2010
    #4
  5. Saeed Bhuta

    Saeed Bhuta Guest

    Tony Arcieri wrote:
    > On Tue, Jul 13, 2010 at 6:55 AM, Saeed Bhuta
    > <>wrote:
    >
    >> p client.wsdl.soap_actions doesn't return anything...
    >>

    >
    > It doesn't look like there are any SOAP actions in your WSDL


    Hmmm. However when I use soapUI, it seems to find the actions from the
    WSDL without any problems...
    --
    Posted via http://www.ruby-forum.com/.
    Saeed Bhuta, Jul 13, 2010
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Nick Chan
    Replies:
    0
    Views:
    499
    Nick Chan
    Sep 13, 2007
  2. Tony C
    Replies:
    2
    Views:
    352
    Xiangyang Liu
    Jul 20, 2003
  3. Curt K
    Replies:
    3
    Views:
    451
    John Saunders [MVP]
    Jun 15, 2007
  4. ghettoiam

    Need help using Savon gem! (SOAP)

    ghettoiam, May 11, 2010, in forum: Ruby
    Replies:
    0
    Views:
    174
    ghettoiam
    May 11, 2010
  5. Moon Chy
    Replies:
    1
    Views:
    130
    Moon Chy
    Feb 25, 2011
Loading...

Share This Page