Format posts into json working json resource