# Soap4r and WSDL

**URL:** <https://www.ruby-forum.com/t/soap4r-and-wsdl/167998>\
**Category:** Ruby\
**Created:** [May 14, 2009, 9:18pm UTC](https://www.ruby-forum.com/t/soap4r-and-wsdl/167998 "2009-05-14T21:18:53Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![xinit](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/x/9f8e36/32.png) [@xinit](https://www.ruby-forum.com/u/xinit)\
**Post date:** [May 14, 2009, 9:18pm UTC](https://www.ruby-forum.com/t/soap4r-and-wsdl/167998/1 "2009-05-14T21:18:53Z")

</div>

Hi all!

I’m trying to use a web service of my payment provider by making SOAP  
calls to their server. I’m using the WSDL that is attached to this post  
(couldn’t add urls though [ruby-forum.com](http://ruby-forum.com))

For some reason I can’t seem to call the provided services. I always get  
the error “nil not allowed: currency” when trying to call a method that  
doesn’t even has currency (or Amount) as a parameter. Maybe I’m doing  
something very wrong here, but I can’t seem to figure out how to get  
this thing working.

The latest thing I came up with was:

```
    wsdl = SOAP::WSDLDriverFactory.new(WSDL)
    soap = @wsdl.create_rpc_driver
    soap.options["protocol.http.basic_auth"] << [WSDL, USER_ID,

```

PASSWORD]

```
    result = soap.cancel(:cancel => {
                                :modificationRequest => {
                                    :merchantAccount => 'myAccount',
                                    :originalReference =>

```

‘8343424242056’  
}  
})

Anyone got an idea?

Thanks!

Wouter

---

<div class="post-metadata">

**Author:** ![xinit](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/x/9f8e36/32.png) [@xinit](https://www.ruby-forum.com/u/xinit)\
**Post date:** [May 15, 2009, 1:12pm UTC](https://www.ruby-forum.com/t/soap4r-and-wsdl/167998/2 "2009-05-15T13:12:52Z")

</div>

Ah, got it… After require ‘soap4r’ it works!
