I want to build a simple API that can be accessed by myself in other clients. I want to use Rails 3 to build it but I do not know how to do it. I know that Rails got this more or less build in but I do not know how to interact with it.
Is there any resources on the Internet that I can read up on how to turn my Rails 3 application into a server with a remote API?
Thankful for all input.
Despite of what had been already told, you can start with rails api screencast. Although it's meant for an API only application.
If you want to add and API to an existent full rails app, check this blog post which covers the essentials on a Rails API, including tips for speed-up.
Since this should be a requirement too, for securing your API there's also a screencast on the subject: #352 Securing an API
Yehuda Katz and Ryan Bigg's book, Rails 3 in Action, has a chapter on building a test-driven JSON API on top of the example application that runs through the entire book.
The code for the sample application in the book, Ticketee, is open source and can be found on GitHub. In particular, everything API-related is namespaced under /app/controllers/api and you can find plenty of RSpec tests in /spec/api.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With