This repository was archived by the owner on Apr 29, 2025. It is now read-only.

Description
How can we define a custom attribute for instances?
Using this route as example:
@ItemRoute.GET
def is_recent(self, book) -> fields.Boolean():
return datetime.date.today().year <= book.year_published + 10
How can we define is_recent at the instances level such as:
http GET :5000/book/1 would return book attributes containing is_recent: True | False as well