Skip to content

New API endpoint

Romain edited this page Nov 5, 2020 · 2 revisions

These are the steps to add a new API endpoint to the IHR website:

  • Add a new serializer in serializers.py. Don't forget to import the new model!
  • Add a new class filter and class view (see views.py). Don't forget to import the new model and serializer!
  • Add a new entry in urls.py
  • restart apache: sudo service apache2 restart

In case of problems

Look at apache logs (/var/log/apache2/error.log) or django logs (/var/log/django-ihr/django-info.log)

Clone this wiki locally