Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9288395
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T19:54:21+00:00 2026-06-18T19:54:21+00:00

I have developed few apps in Rails, and I needed to develop an API.

  • 0

I have developed few apps in Rails, and I needed to develop an API. I received the advise to build it in Sinatra, so I started looking into it.

It seemed quite nice, but it seems that a lot of things you get automated in Rails does not seem to exist in Sinatra. Specifically, I seem to have to write my resources from scratch. eg. The model itself, the migrations, and the REST routes.

I was wondering if there are any generators for Sinatra like the ones provided by Rails? Or should I simply use Rails if I want these kind of things automated?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T19:54:22+00:00Added an answer on June 18, 2026 at 7:54 pm

    Check out the sinatra-rest gem that can be used to handle RESTful routes. Quoted below for convenience:


    [sinatra-rest is] a set of templates to introduce RESTful routes into Sinatra. The only thing for you to do is to provide the views. Automatically works nicely for models based on ActiveRecord, DataMapper, or Stone.

    For example, if your model’s class is called Person you only need to add this line:

    rest Person
    

    Which will add the following RESTful routes to your application. (Note the pluralization of Person to the /people/* routes.)

    Verb    Route            Controller   View
    GET     /people          index        /people/index.haml
    GET     /people/new      new          /people/new.haml
    POST    /people          create       → redirect to show
    GET     /people/1        show         /people/show.haml
    GET     /people/1/edit   edit         /people/edit.haml
    PUT     /people/1        update       → redirect to show
    DELETE  /people/1        destroy      → redirect to index
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I started to develop android apps a few days ago, but I'm stuck with
I have a few apps that I am trying to develop a reusable URL
It's been a few years since I have last developed android apps. Since then,
I have developed a few Delphi Win32 (currently using D2007) applications, which revolve around
I have developed sample api as jar file. This jar file contains the code
So I have developed iphone/ipad apps before using Xcode and Phonegap/Cordova for a while
I have developed a few app store applications but recently have been asked by
I am a novice software developer and have only developed a few Java based
I have developed 2 mobile apps using PhoneGap. One is a free ad supported
I'm a iOS developer. I have developed many apps for iPhone and iPad. Now

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.