-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add API endpoint for phone verification(2) #1748
Merged
valaparthvi
merged 5 commits into
additional-login-options
from
phone/PhoneVerifyAPIendpoint
Aug 29, 2017
Merged
Add API endpoint for phone verification(2) #1748
valaparthvi
merged 5 commits into
additional-login-options
from
phone/PhoneVerifyAPIendpoint
Aug 29, 2017
Conversation
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
* Phone registration page, and authentication backend * Upgrade django-skivvy to 0.1.8 * 100% test coverage * Minor change to phone validator * Changes to default.py and tests as addressed by Oliver * Make all addressed changes * allow user to authenticate even if the account status is inactive * add changes addressed to PR * Minor changes to the code * Make VerificationDevice OneToOneField and make corresponding changes Solve migration merge conflicts, and create a new migration file for phone and verification device Pass all tests after rebasing Make all tests pass * change logger from info to debug
* Phone registration page, and authentication backend Upgrade django-skivvy to 0.1.8 100% test coverage Minor change to phone validator Changes to default.py and tests as addressed by Oliver Make all addressed changes * Phone registration page, and authentication backend Upgrade django-skivvy to 0.1.8 100% test coverage Minor change to phone validator Changes to default.py and tests as addressed by Oliver Make all addressed changes Phone registration page, and authentication backend * Edit Profile Page changes corresponding to setting user as OneToOneField in VerificationDevice add phone_format, instead of message Remove unnecessary lines of code and add required tests Check if new email/phone updated by user exists in EmailAddress/VerificationDevice, make sure user is redirected to AccountVerification Page only when they update phone, add tests for the same. delete identifier.html change to tests
* Reset Password with Phone * A single form for token verification, solve KeyErrors on direct URL access, write required tests * Changes addressed to PR
valaparthvi
added a commit
that referenced
this pull request
Aug 31, 2017
* Add API endpoint for phone verification * Changes addressed to PR
valaparthvi
added a commit
that referenced
this pull request
Sep 7, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 8, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 12, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 21, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 21, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 22, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Sep 26, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
clash99
pushed a commit
that referenced
this pull request
Oct 3, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
oliverroick
pushed a commit
that referenced
this pull request
Oct 4, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
clash99
pushed a commit
that referenced
this pull request
Oct 4, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 5, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 5, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 5, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 20, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 20, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 20, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Oct 26, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
valaparthvi
added a commit
that referenced
this pull request
Nov 8, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
oliverroick
pushed a commit
that referenced
this pull request
Nov 13, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
oliverroick
pushed a commit
that referenced
this pull request
Nov 30, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
oliverroick
pushed a commit
that referenced
this pull request
Dec 1, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
oliverroick
pushed a commit
that referenced
this pull request
Dec 6, 2017
* VerificationDevice model and Removal of 48hr email verification period (#1606) * Registration with Phone number (#1662) * Add phone to User Profile (#1698) * Add Ansible provisioning for Twilio * Allow user to login with phone and add Resend Token Page (#1708) * Reset Password with Phone (#1717) * Twilio Integration and More update notification (#1719) * Add API endpoint for phone verification(2) (#1748)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Proposed changes in this pull request
Add API endpoint to verify phone number.
Add
PhoneVerificationSerializer
to verify phone number. This serializer takes a phone and token. If Verification Device with this token exists, verify the token. If the token is successfully verified, setphone_verified
to True,is_active
to True, and if the phone needs to be updated then update it.Tests
Add
ConfirmPhoneView
toaccounts/views/api.py
. This view is hooked to thePhoneVerificationSerializer
. It sends HTTP_200_OK status if the phone is successfully verified, else sends HTTP_400_BAD_REQUEST status. Permission is set toAllowAny
, so that phone can be verified with both authenticated and unauthenticated request.Tests
Add a URL
/verify/phone/
connected to the view. Add test for the same.Minor addition to
accounts/forms.py
, add a string for translation.When should this PR be merged
Risks
Follow-up actions
Checklist (for reviewing)
General
migration
label if a new migration is added.Functionality
Code
Tests
Security
Documentation