# Urgent ! Need Web Services Help

**URL:** <https://www.ruby-forum.com/t/urgent-need-web-services-help/170413>\
**Category:** Rails\
**Created:** [June 17, 2009, 11:00am UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413 "2009-06-17T11:00:09Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 11:00am UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/1 "2009-06-17T11:00:09Z")

</div>

I want to develop web services using ruby on rails , how can i , any  
help ?

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 12:33pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/2 "2009-06-17T12:33:56Z")

</div>

Hamid R. wrote:

> I want to develop web services using ruby on rails , how can i , any  
> help ?

How is this urgent? Have you even searched the Internet for web  
services on Rails?

Cheers,  
Mohit.  
6/17/2009 | 6:32 PM.

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 12:21pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/3 "2009-06-17T12:21:34Z")

</div>

> **[Getting Started with Rails — Ruby on Rails Guides](https://guides.rubyonrails.org/getting_started.html)**
>
> Getting Started with RailsThis guide covers getting up and running with Ruby on Rails.After reading this guide, you will know: How to install Rails, create a new Rails application, and connect your application to a database. The general layout of a...

On Jun 17, 5:00 am, Hamid R. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 12:46pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/4 "2009-06-17T12:46:10Z")

</div>

yup i searched and found this

[http://www.ibm.com/developerworks/opensource/library/os-ws-rubyrails/index.html](http://www.ibm.com/developerworks/opensource/library/os-ws-rubyrails/index.html)

but is there any other gem or plugin or way to make web services.

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 2:34pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/5 "2009-06-17T14:34:11Z")

</div>

This link may be useful for you.

[http://www.trynt.com/apis/](http://www.trynt.com/apis/)

On Wed, Jun 17, 2009 at 3:50 PM, p\_W [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > Posted viahttp://www.ruby-forum.com/.

–  
â€œKnowing others is intelligence;  
knowing yourself is true wisdom.  
Mastering others is strength;  
mastering yourself is true power.â€

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 18, 2009, 3:38pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/6 "2009-06-18T15:38:15Z")

</div>

@ Robert W. :

Thanks,

let me tell you what is my problem , m using ActionWebService.  
and have two applications on is server and other is client.  
In server:  
I defined an api in which i have a function which will return list of  
articles, let me show u that decleration:

api\_method :get\_baby\_growth\_articles,  
:expects =\> [{:userid=\>:string}, {:lastUpdateDate=\>:date}],  
:returns =\> [Article]

this is the function this will return objects of Articles when called by  
the cliet.

and the function’s definition defined in controller is :

def get\_baby\_growth\_articles(login, lastUpdateDate)  
unless is\_registered(login)  
return  
end  
return Article.find(:all,:conditions=\>[“updated\_at =\>  
?”,lastUpdateDate])  
end

now if ill get its wsdl through url by giving

[http://localhost:3000/baby\_wise/wsdl](http://localhost:3000/baby_wise/wsdl)

it simply returns wsdl

you can see its return type which is “typens:Article”

now the problem is

i m accessing this function in my other application just a dummy client  
applcation  
where i defined the same api(which is necessary) as defined in the api  
of server and the function’s defination is same which is

api\_method :get\_baby\_growth\_articles,  
:expects =\> [{:userid=\>:string}, {:lastUpdateDate=\>:date}],  
:returns =\> [Article]

but here it doesnt recognize “Article”.

as i have to return list form the server , so i used Article in the  
function’s decleration :returns =\> [Article]

notice: if i use :returns =\> [:string] it works , so the problem is  
how can i return list.

hope u got it 😊

thanx in advance.

---

<div class="post-metadata">

**Author:** ![hamidraza](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/e9a140/32.png) [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Post date:** [June 17, 2009, 9:59pm UTC](https://www.ruby-forum.com/t/urgent-need-web-services-help/170413/7 "2009-06-17T21:59:50Z")

</div>

Hamid R. wrote:

> yup i searched and found this
> 
> [IBM Developer](http://www.ibm.com/developerworks/opensource/library/os-ws-rubyrails/index.html)
> 
> but is there any other gem or plugin or way to make web services.

actionwebservice is pretty much still the way to do SOAP web services as  
far as I know. However, you won’t find much support of doing web  
services from the Rails core. Rails has a pretty clear opinion on how to  
provide web services and that is though REST services not SOAP. This  
opinion happens to coincide with my own. I’m ready for the rest of the  
world to wake up to REST and let SOAP die a quiet death.

Even though the Rails core isn’t supporting actionwebservice anymore,  
support is available in the latest Rails 2.3.2 in this project:

> **[GitHub - datanoise/actionwebservice: This project is discontinued](https://github.com/datanoise/actionwebservice/tree/master)**
>
> master

I’d only recommend this if you are stuck having to either implement an  
existing SOAP service you have no control over. Or you must provide a  
web service to clients that won’t accept REST.

There is a lot of information online regarding REST services in Rails.  
All you have to do is look. You practically get REST services for free  
just by building in Rails anyway (assuming you’re using the latest  
techniques).
