working on get_posts.json and fixed issue with non-json-serializable error