Implement getting the authentication link

This commit is contained in:
Mark Veidemanis 2022-04-20 13:24:00 +01:00
parent 87d96f6c41
commit ed5fd3dafd
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
1 changed files with 10 additions and 0 deletions

View File

@ -19,6 +19,16 @@ class Verify(util.Base):
""" """
Get an external authentication link for a user. Get an external authentication link for a user.
""" """
# /resources/sdkIntegrations/levels/{levelName}/websdkLink?ttlInSecs={lifetime}&externalUserId={externalUserId}&lang={locale}
url = (
f"{settings.Verify.Base}/resources/sdkIntegrations/levels/{settings.Verify.LevelName}"
f"/websdkLink?ttlInSecs=36000&externalUserId={external_user_id}"
)
resp = self.sign_request(requests.Request("POST", url))
s = requests.Session()
response = s.send(resp)
verification_url = response.json()["url"]
return verification_url
def get_applicant_status(self, applicant_id): def get_applicant_status(self, applicant_id):
""" """