forked from encode/django-rest-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added drfpasswordless to Authentication docs
- Loading branch information
Showing
1 changed file
with
1 addition
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -358,24 +358,7 @@ HTTP Signature (currently a [IETF draft][http-signature-ietf-draft]) provides a | |
|
||
## drfpasswordless | ||
|
||
[drfpasswordless][drfpasswordless] adds passwordless support to Django Rest Framework's own TokenAuthentication scheme. Users log in and sign up with a token sent to a contact point, either an email address or a mobile number. | ||
|
||
#### Example | ||
|
||
curl -X POST -d "[email protected]" localhost:8000/auth/email/ | ||
|
||
User receives an email: | ||
|
||
.. | ||
<h1>Your login token is 123456</h1> | ||
.. | ||
|
||
The client has 15 minutes to provide the correct token in exchange for an authentication token (provided by Django Rest Framework's Token Authentication). | ||
|
||
curl -X POST -d "token=815381" localhost:8000/callback/auth/ | ||
|
||
> HTTP/1.0 200 OK | ||
> {"token":"76be2d9ecfaf5fa4226d722bzdd8a4fff207ed0e”} | ||
[drfpasswordless][drfpasswordless] adds (Medium, Square Cash inspired) passwordless support to Django REST Framework's own TokenAuthentication scheme. Users log in and sign up with a token sent to a contact point like an email address or a mobile number. | ||
|
||
[cite]: http://jacobian.org/writing/rest-worst-practices/ | ||
[http401]: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.2 | ||
|