Momentum logo
Team 14 Classroom

🐻 API Progress Check-In 🐻

Posted on Sep 22nd, 2022

πŸ—“οΈ Today’s Topics

  • How are the projects coming along? πŸ‘€
  • Automatic deploys from GitHub
  • Paginating your API

🎯 Project

Keep on going. πŸ’ͺ πŸš€

We will use class time today to get you past any blockers you may be experiencing and to talk through next steps.

By now you should have provided your front end with endpoints to see data and gotten djoser installed so that your log in and log out endpoints are working.

By tomorrow you should have the ability to create at least questions or cards via POST requests, and maybe more.

πŸ“– Read | πŸ“Ί Watch | 🎧 Listen

On Monday we’ll be covering full-text search in your API, but if you have time you can check these resources out in advance.

πŸ”– Resources

Authentication

Make sure you are sharing the Djoser information with your front end. You should include the authentication endpoints in your API documentation or project README.

Creating a properly hashed password

In order to save a properly hashed password when you create a new user in the Django Admin, make sure you are using UserAdmin in admin.py so that you have that option in the admin interface. If you don’t do this and save an unhashed password, you will run into authentication errors.

from django.contrib import admin
from django.contrib.auth.admin import UserAdmin
...
admin.site.register(User, UserAdmin)

You can also change a password from the command line:

Pagination

Back to home