mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-05 02:41:14 -05:00
Merge pull request #840 from GSA/notify-admin-1277
fix login.gov to use user uuid instead of email (notify-admin-1277)
This commit is contained in:
@@ -19,6 +19,7 @@ from app.dao.users_dao import (
|
||||
create_secret_code,
|
||||
create_user_code,
|
||||
dao_archive_user,
|
||||
get_login_gov_user,
|
||||
get_user_and_accounts,
|
||||
get_user_by_email,
|
||||
get_user_by_id,
|
||||
@@ -537,6 +538,16 @@ def set_permissions(user_id, service_id):
|
||||
return jsonify({}), 204
|
||||
|
||||
|
||||
@user_blueprint.route("/get-login-gov-user", methods=["POST"])
|
||||
def get_user_login_gov_user():
|
||||
request_args = request.get_json()
|
||||
login_uuid = request_args["login_uuid"]
|
||||
email = request_args["email"]
|
||||
user = get_login_gov_user(login_uuid, email)
|
||||
result = user.serialize()
|
||||
return jsonify(data=result)
|
||||
|
||||
|
||||
@user_blueprint.route("/email", methods=["POST"])
|
||||
def fetch_user_by_email():
|
||||
email = email_data_request_schema.load(request.get_json())
|
||||
|
||||
Reference in New Issue
Block a user