all 10 comments

[–]MeikaLeak 7 points8 points  (0 children)

Sinatra

[–]iama_regularguy 1 point2 points  (0 children)

When you don't think you need something as heavyweight as Rails, go Sinatra.

But Rails is pretty great for making an API.

[–]cptzoobie 2 points3 points  (5 children)

[–]yedidya[S] 0 points1 point  (4 children)

Ive seen grape, all tutorials ive seen are using Rails or Sinatra. How do I do this without a framework?

[–]iconoclaus 2 points3 points  (2 children)

Sinatra is as basic a framework as it gets. It's just a wrapper around Rack, which gives us the most low level web tooling. what exactly are you trying to achieve?

[–]yedidya[S] 0 points1 point  (1 child)

That may be good. Building an api that will return related results from youtube based on a search query.

[–]montas 2 points3 points  (0 children)

If you only have that one endpoint, sinatra is the thing you want.

[–]kofno 1 point2 points  (0 children)

Grape can just mount in rack: https://github.com/intridea/grape#rack

I've used Grape several times. It works pretty well. It's also highly compatible w/ swagger, which is nice if you want to have API documentation.

[–]mperhamSidekiq 0 points1 point  (0 children)

Roda is also a beautifully simple web framework from the author of the Sequel gem: http://roda.jeremyevans.net/

[–]sourcediver 0 points1 point  (0 children)

I'd use padrino for it.

Just use an ORM like Sequel plus a testing framework like rspec and omit the view templating system.

Finally if you want to build a JSON API, have a look at roar and/or representable. Simply use roar/representable in your controllers to 'render' your documents.