Adding custom fields in the WordPress REST API
Adding a new field with the register_api_field function
The described below requires more code, but it’s more elegant and opens up many more possibilities for expanding our functionality.
Adding a new field with the register_api_field function
The described below requires more code, but it’s more elegant and opens up many more possibilities for expanding our functionality.
Okay, so based on what we know, what are the steps to creating a REST API?
Set up Django
Create a model in the database that the Django ORM will manage
Set up the Django REST Framework
Serialize the model from step 2
Create the URI endpoints to view the serialized data
Access data on COVID19 through an easy API for free. Build dashboards, mobile apps or integrate in to other applications. Data is sourced from Johns Hopkins CSSE