Thanks Hiroshi, that got me started.  Soap4r is great, I just wish this 
app had a WSDL!

I may consider writing a WSDL for this application, but for now I only 
need a subset of fucntionality.  The request objects are all pretty 
simple, but I am having trouble accessing data from the response 
objects.

After calling:

get_account = driver.get_account('user / example.com')

The raw XML response for this command looks something like this:

<GetAccountResponse xmlns:ns0="urn:namespace">
  <account name="user / example.com" 
id="770316d9-qwe4-38eu-s84h-2dfe3c6cc874">
    <a n="key1">value1</a>
    <a n="key2">value2</a>
    <a n="key3">value3</a>
    ...
  </account>
</GetAccountResponse>

I need to access the key/value pairs in the a attributes, but 
get_account.account.a simply returns an array of [value1, value2, 
value3, ...] and seems to ignore the attributes.  Many response objects 
for this app take this form, so it would be nice to be able to create a 
hash, or ruby object dynamically based on the key/values.

Can I access the raw response XML somehow, or is there a better way to 
do this?

The app I am using is Zimbra, in case anyone has any experience or 
advice for use with Soap4r.

Thanks again,
Andrew


-- 
Posted via http://www.ruby-forum.com/.