does rails route provide same architecture as restful api has?
As an advice. When you’ll make a decision which technique to use take also look into grape gem.
i need to implement in rails
@rails6learner Reading a book is definitely good advice, but to clarify: Rails is one way to build a REST API. You could also use Rails to build other APIs (such as GraphQL or websockets-based). REST, however, is probably the biggest way that people have made APIs in Rails historically, so Rails definitely works for that.
grape is a gem which can work along with Rails (it can work with other frameworks too). I also recommend checking it out to maybe make things simpler
Not by itself but yes you can create RESTful APIs with RAILS. That requires from you that you set up your application in such a way that the data can be accessed as resources and that you create controllers that provide an API in a RESTful way. That said you do get a lot of support from RAILS.
You are shipping features gradually.
- Step 1: Create Rails API Skeleton.
- Step 2: Versioning your api.
- Step 3: Scaffold a resource.
- Step 4: Move the resource controller to its respective folder.
- Step 5: Update The controller.
- Step 6: Update the route file.
- Step 7: More resources.
- Step 8 : Try it! MyFordBenefits