so I've stumbled upon a legacy app doing a lot of as_json overrides in models for API routes
which is super painful, because the API output is very different than what you would POST/PUT to create/update things
I've been reading about serializers, but all the examples I find reference using them in the index/show actions. Which makes sense to me. The question I have is that, would you/could you post back the structure you get from the index/show to an edit action and it would work?
eg I'm thinking I want my url to be like /devices/1/ports, and it would give me a list of all the Port objects with the device_id of 1, which I have working. I'm confused on how POST/PUT would work to create/update