Let us say I have a model Post which belongs to a User. To convert to json, I do something like this
@reply.to_json(:include => {:user => {:only =>
You could add another method to ActiveRecord::Base, like self.to_minimal_json(*only_fields) and build your .to_json call there.
unspectacular, but may work.