active model serializer

Smarter Rails Services with Active Record Modules

MVC is Not Enough! We're familiar with the MVC (Model-View-Controller) pattern that Rails offers us––our models map to database tables and wrap our data in objects; controllers receive requests for data and serve up data to the views; views present the data. A common analogy is that…

Rails API Painless Error Handling and Rendering

Are you sick and tired of handling endless exceptions, writing custom logic to handle bad API requests and serializing the same errors over and over? What if I told you there was a way to abstract away messy and repetitive error raising and response rendering in your Rails API? A…

Building a Super Simple Rails API, JSON API Edition

In an earlier post [https://www.thegreatcodeadventure.com/building-a-super-simple-rails-api/], we built a super quick and super simple Rails API using the Active Model Serializer gem and the Active Model Adapter. There's been a lot of growth lately, however, around JSON API. What is JSON API? So, what is…