diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..19a461b
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,35 @@
+lib-cov
+*.seed
+*.log
+*.csv
+*.dat
+*.out
+*.pid
+*.gz
+
+pids
+logs
+results
+
+npm-debug.log
+prepros.cfg
+.DS_Store
+.idea/
+
+/nbproject/private/
+nbproject/project.properties
+nbproject/project.xml
+/sdk-node-js-customer-identity/nbproject/private/
+__pycache__/
+*.py[cod]
+*$py.class
+
+.installed.cfg
+bin
+develop-eggs
+dist
+downloads
+eggs
+parts
+src/*.egg-info
+lib64
\ No newline at end of file
diff --git a/CHANGELOG.md b/CHANGELOG.md
index fd46034..46b03a4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,8 +1,81 @@
# LoginRadius Python SDK Change Log
-# Version 10.0.0-beta
+# Version 10.0.0
+Release on **September 30,2019**
+
## Enhancements
-This beta version release includes major changes with several improvements and optimizations :
+This full version release includes major breaking changes with several improvements and optimizations :
+
+ - Enhanced the coding standards of SDK to follow industry programming styles and best practices.
+ - Enhanced security standards of SDK.
+ - Reduced code between the business layer and persistence layer for optimization of SDK performance.
+ - Added internal parameter validations in the API function.
+ - ApiKey and ApiSecret usage redundancy removed.
+ - All LoginRadius related features need to be defined once only and SDK will handle them automatically.
+ - Improved the naming conventions of API functions for better readability.
+ - Better Exception Handling for LoginRadius API Response in SDK.
+ - Revamped complete SDK and restructured it with latest API function names and parameters.
+ - Added detailed description to API functions and parameters for better understanding.
+ - Updated the demo according to latest SDK changes.
+ - Implemented API Region Feature.
+ - Added PIN Authentication feature APIs.
+ - Added Consent Management feature APIs.
+ - Added Local SOTT generation
+
+
+## Added new multiple APIs for better user experience
+
+ - Update Phone ID by UID
+ - Upsert Email
+ - Role Context profile
+ - MFA Resend OTP
+ - User Registration By Captcha
+ - Get Access Token via Linkedin Token
+ - Get Access Token By Foursquare Access Token
+ - Get Active Session By Account Id
+ - Get Active Session By Profile Id
+ - Delete User Profiles By Email
+ - Verify Multifactor OTP Authentication
+ - Verify Multifactor Password Authentication
+ - Verify Multifactor PIN Authentication
+ - Update UID
+ - MFA Re-authentication by PIN
+ - PIN Login
+ - Forgot PIN By Email
+ - Forgot PIN By UserName
+ - Reset PIN By ResetToken
+ - Reset PIN By SecurityAnswer And Email
+ - Reset PIN By SecurityAnswer And Username
+ - Reset PIN By SecurityAnswer And Phone
+ - Forgot PIN By Phone
+ - Change PIN By Token
+ - Reset PIN by Phone and OTP
+ - Reset PIN by Email and OTP
+ - Reset PIN by Username and OTP
+ - Set PIN By PinAuthToken
+ - Invalidate PIN Session Token
+ - Submit Consent By ConsentToken
+ - Get Consent Logs
+ - Submit Consent By AccessToken
+ - Verify Consent By AccessToken
+ - Update Consent Profile By AccessToken
+ - Get Consent Logs By Uid
+ - Album With Cursor
+ - Audio With Cursor
+ - Check In With Cursor
+ - Event With Cursor
+ - Following With Cursor
+ - Group With Cursor
+ - Like With Cursor
+
+
+## Removed APIs:
+
+ - GetCompanies API
+ - Getstatus API
+
+# Version 10.0.0-beta
+## This beta version release includes major changes with several improvements and optimizations :
- Enhanced the coding standards of SDK to follow industry programming styles and best practices.
- Enhanced security standards of SDK.
- Reduced code between the business layer and persistence layer for optimization of SDK performance.
diff --git a/Demo/LoginRadius/api/__init__.py b/Demo/LoginRadius/api/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/Demo/LoginRadius/api/account/__init__.py b/Demo/LoginRadius/api/account/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/Demo/LoginRadius/api/account/account_api.py b/Demo/LoginRadius/api/account/account_api.py
index 89a5b1f..37051c7 100644
--- a/Demo/LoginRadius/api/account/account_api.py
+++ b/Demo/LoginRadius/api/account/account_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -315,7 +315,7 @@ def invalidate_account_email_verification(self, uid, email_template='', verifica
return self._lr_object.execute("PUT", resource_path, query_parameters, None)
def get_forgot_password_token(self, email, email_template=None, reset_password_url=None,
- send_email=False):
+ send_email=None):
"""This API Returns a Forgot Password Token it can also be used to send a Forgot Password email to the customer. Note: If you have the UserName workflow enabled, you may replace the 'email' parameter with 'username' in the body.
Args:
@@ -544,3 +544,50 @@ def get_account_identities_by_email(self, email, fields=''):
resource_path = "identity/v2/manage/account/identities"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def account_delete_by_email(self, email):
+ """This API is used to delete all user profiles associated with an Email.
+
+ Args:
+ email: Email of the user
+
+ Returns:
+ Response containing Definition of Delete Request
+ 18.36
+ """
+
+ if(self._lr_object.is_null_or_whitespace(email)):
+ raise Exception(self._lr_object.get_validation_message("email"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+ query_parameters["email"] = email
+
+ resource_path = "identity/v2/manage/account"
+ return self._lr_object.execute("DELETE", resource_path, query_parameters, None)
+
+ def account_update_uid(self, update_uid_model, uid):
+ """This API is used to update a user's Uid. It will update all profiles, custom objects and consent management logs associated with the Uid.
+
+ Args:
+ update_uid_model: Payload containing Update UID
+ uid: UID, the unified identifier for each user account
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 18.41
+ """
+ if(update_uid_model is None):
+ raise Exception(self._lr_object.get_validation_message("update_uid_model"))
+
+ if(self._lr_object.is_null_or_whitespace(uid)):
+ raise Exception(self._lr_object.get_validation_message("uid"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+ query_parameters["uid"] = uid
+
+ resource_path = "identity/v2/manage/account/uid"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, update_uid_model)
diff --git a/Demo/LoginRadius/api/account/role_api.py b/Demo/LoginRadius/api/account/role_api.py
index 54e4153..28c7c40 100644
--- a/Demo/LoginRadius/api/account/role_api.py
+++ b/Demo/LoginRadius/api/account/role_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/account/sott_api.py b/Demo/LoginRadius/api/account/sott_api.py
index 3bc8c4e..13fbbf8 100644
--- a/Demo/LoginRadius/api/account/sott_api.py
+++ b/Demo/LoginRadius/api/account/sott_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/advanced/__init__.py b/Demo/LoginRadius/api/advanced/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/Demo/LoginRadius/api/advanced/configuration_api.py b/Demo/LoginRadius/api/advanced/configuration_api.py
index 7e827dc..dd35f2d 100644
--- a/Demo/LoginRadius/api/advanced/configuration_api.py
+++ b/Demo/LoginRadius/api/advanced/configuration_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/advanced/consentmanagement_api.py b/Demo/LoginRadius/api/advanced/consentmanagement_api.py
new file mode 100644
index 0000000..dfd9fb0
--- /dev/null
+++ b/Demo/LoginRadius/api/advanced/consentmanagement_api.py
@@ -0,0 +1,155 @@
+# -- coding: utf-8 --
+# Created by LoginRadius Development Team
+# Copyright 2019 LoginRadius Inc. All rights reserved.
+#
+
+
+class ConsentManagementApi:
+
+ def __init__(self, lr_object):
+ """
+ :param lr_object: this is the reference to the parent LoginRadius object.
+ """
+ self._lr_object = lr_object
+
+ def get_consent_logs_by_uid(self, uid):
+ """This API is used to get the Consent logs of the user.
+
+ Args:
+ uid: UID, the unified identifier for each user account
+
+ Returns:
+ Response containing consent logs
+ 18.37
+ """
+
+ if(self._lr_object.is_null_or_whitespace(uid)):
+ raise Exception(self._lr_object.get_validation_message("uid"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+
+ resource_path = "identity/v2/manage/account/" + uid + "/consent/logs"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def submit_consent_by_consent_token(self, consent_token, consent_submit_model):
+ """This API is to submit consent form using consent token.
+
+ Args:
+ consent_token: The consent token received after login error 1226
+ consent_submit_model: Model class containing list of multiple consent
+
+ Returns:
+ Response containing User Profile Data and access token
+ 43.1
+ """
+
+ if(self._lr_object.is_null_or_whitespace(consent_token)):
+ raise Exception(self._lr_object.get_validation_message("consent_token"))
+ if(consent_submit_model is None):
+ raise Exception(self._lr_object.get_validation_message("consent_submit_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["consentToken"] = consent_token
+
+ resource_path = "identity/v2/auth/consent"
+ return self._lr_object.execute("POST", resource_path, query_parameters, consent_submit_model)
+
+ def get_consent_logs(self, access_token):
+ """This API is used to fetch consent logs.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+
+ Returns:
+ Response containing consent logs
+ 43.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/consent/logs"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def submit_consent_by_access_token(self, access_token, consent_submit_model):
+ """API to provide a way to end user to submit a consent form for particular event type.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ consent_submit_model: Model class containing list of multiple consent
+
+ Returns:
+ Response containing Definition for Complete profile data
+ 43.3
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(consent_submit_model is None):
+ raise Exception(self._lr_object.get_validation_message("consent_submit_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/consent/profile"
+ return self._lr_object.execute("POST", resource_path, query_parameters, consent_submit_model)
+
+ def verify_consent_by_access_token(self, access_token, event, is_custom):
+ """This API is used to check if consent is submitted for a particular event or not.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ event: Allowed events: Login, Register, UpdateProfile, ResetPassword, ChangePassword, emailVerification, AddEmail, RemoveEmail, BlockAccount, DeleteAccount, SetUsername, AssignRoles, UnassignRoles, SetPassword, LinkAccount, UnlinkAccount, UpdatePhoneId, VerifyPhoneNumber, CreateCustomObject, UpdateCustomobject, DeleteCustomObject
+ is_custom: true/false
+
+ Returns:
+ Response containing consent profile
+ 43.4
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(event)):
+ raise Exception(self._lr_object.get_validation_message("event"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["event"] = event
+ query_parameters["isCustom"] = is_custom
+
+ resource_path = "identity/v2/auth/consent/verify"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def update_consent_profile_by_access_token(self, access_token, consent_update_model):
+ """This API is to update consents using access token.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ consent_update_model: Model class containg list of multiple consent
+
+ Returns:
+ Response containing consent profile
+ 43.5
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(consent_update_model is None):
+ raise Exception(self._lr_object.get_validation_message("consent_update_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/consent"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, consent_update_model)
diff --git a/Demo/LoginRadius/api/advanced/customobject_api.py b/Demo/LoginRadius/api/advanced/customobject_api.py
index 5a81e74..ce07db2 100644
--- a/Demo/LoginRadius/api/advanced/customobject_api.py
+++ b/Demo/LoginRadius/api/advanced/customobject_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -42,7 +42,7 @@ def create_custom_object_by_token(self, access_token, object_name, payload):
return self._lr_object.execute("POST", resource_path, query_parameters, payload)
def update_custom_object_by_token(self, access_token, object_name, object_record_id,
- payload, update_type=''):
+ payload, update_type=None):
"""This API is used to update the specified custom object data of the specified account. If the value of updatetype is 'replace' then it will fully replace custom object with the new custom object and if the value of updatetype is 'partialreplace' then it will perform an upsert type operation
Args:
@@ -194,7 +194,7 @@ def create_custom_object_by_uid(self, object_name, payload, uid):
return self._lr_object.execute("POST", resource_path, query_parameters, payload)
def update_custom_object_by_uid(self, object_name, object_record_id, payload,
- uid, update_type=''):
+ uid, update_type=None):
"""This API is used to update the specified custom object data of a specified account. If the value of updatetype is 'replace' then it will fully replace custom object with new custom object and if the value of updatetype is partialreplace then it will perform an upsert type operation.
Args:
diff --git a/Demo/LoginRadius/api/advanced/customregistrationdata_api.py b/Demo/LoginRadius/api/advanced/customregistrationdata_api.py
index c3d3d48..3a0dc22 100644
--- a/Demo/LoginRadius/api/advanced/customregistrationdata_api.py
+++ b/Demo/LoginRadius/api/advanced/customregistrationdata_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/advanced/multifactorauthentication_api.py b/Demo/LoginRadius/api/advanced/multifactorauthentication_api.py
index 8b25d51..f630077 100644
--- a/Demo/LoginRadius/api/advanced/multifactorauthentication_api.py
+++ b/Demo/LoginRadius/api/advanced/multifactorauthentication_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -509,129 +509,6 @@ def mfa_resend_otp(self, second_factor_authentication_token, sms_template2_f_a=N
resource_path = "identity/v2/auth/login/2fa/resend"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
- def mfa_re_authenticate(self, access_token, sms_template2_f_a=None):
- """This API is used to trigger the Multi-Factor Autentication workflow for the provided access_token
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
- sms_template2_f_a: SMS Template Name
-
- Returns:
- Response containing Definition of Complete Multi-Factor Authentication Settings data
- 14.3
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
- query_parameters["apiKey"] = self._lr_object.get_api_key()
- if(not self._lr_object.is_null_or_whitespace(sms_template2_f_a)):
- query_parameters["smsTemplate2FA"] = sms_template2_f_a
-
- resource_path = "identity/v2/auth/account/reauth/2fa"
- return self._lr_object.execute("GET", resource_path, query_parameters, None)
-
- def mfa_re_authenticate_by_otp(self, access_token, reauth_by_otp_model):
- """This API is used to re-authenticate via Multi-factor authentication by passing the One Time Password received via SMS
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
- reauth_by_otp_model: Model Class containing Definition for MFA Reauthentication by OTP
-
- Returns:
- Complete user Multi-Factor Authentication Token data
- 14.4
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
- if(reauth_by_otp_model is None):
- raise Exception(self._lr_object.get_validation_message("reauth_by_otp_model"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
- query_parameters["apiKey"] = self._lr_object.get_api_key()
-
- resource_path = "identity/v2/auth/account/reauth/2fa/otp"
- return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_otp_model)
-
- def mfa_re_authenticate_by_backup_code(self, access_token, reauth_by_backup_code_model):
- """This API is used to re-authenticate by set of backup codes via access_token on the site that has Multi-factor authentication enabled in re-authentication for the user that does not have the device
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
- reauth_by_backup_code_model: Model Class containing Definition for MFA Reauthentication by Backup code
-
- Returns:
- Complete user Multi-Factor Authentication Token data
- 14.5
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
- if(reauth_by_backup_code_model is None):
- raise Exception(self._lr_object.get_validation_message("reauth_by_backup_code_model"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
- query_parameters["apiKey"] = self._lr_object.get_api_key()
-
- resource_path = "identity/v2/auth/account/reauth/2fa/backupcode"
- return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_backup_code_model)
-
- def mfa_re_authenticate_by_google_auth(self, access_token, reauth_by_google_authenticator_code_model):
- """This API is used to re-authenticate via Multi-factor-authentication by passing the google authenticator code
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
- reauth_by_google_authenticator_code_model: Model Class containing Definition for MFA Reauthentication by Google Authenticator
-
- Returns:
- Complete user Multi-Factor Authentication Token data
- 14.6
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
- if(reauth_by_google_authenticator_code_model is None):
- raise Exception(self._lr_object.get_validation_message("reauth_by_google_authenticator_code_model"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
- query_parameters["apiKey"] = self._lr_object.get_api_key()
-
- resource_path = "identity/v2/auth/account/reauth/2fa/googleauthenticatorcode"
- return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_google_authenticator_code_model)
-
- def mfa_re_authenticate_by_password(self, access_token, password_event_based_auth_model_with_lockout, sms_template2_f_a=None):
- """This API is used to re-authenticate via Multi-factor-authentication by passing the password
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
- password_event_based_auth_model_with_lockout: Model Class containing Definition of payload for PasswordEventBasedAuthModel with Lockout API
- sms_template2_f_a: SMS Template Name
-
- Returns:
- Complete user Multi-Factor Authentication Token data
- 14.7
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
- if(password_event_based_auth_model_with_lockout is None):
- raise Exception(self._lr_object.get_validation_message("password_event_based_auth_model_with_lockout"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
- query_parameters["apiKey"] = self._lr_object.get_api_key()
- if(not self._lr_object.is_null_or_whitespace(sms_template2_f_a)):
- query_parameters["smsTemplate2FA"] = sms_template2_f_a
-
- resource_path = "identity/v2/auth/account/reauth/password"
- return self._lr_object.execute("PUT", resource_path, query_parameters, password_event_based_auth_model_with_lockout)
-
def mfa_reset_sms_authenticator_by_uid(self, otpauthenticator, uid):
"""This API resets the SMS Authenticator configurations on a given account via the UID.
diff --git a/Demo/LoginRadius/api/advanced/reauthentication_api.py b/Demo/LoginRadius/api/advanced/reauthentication_api.py
new file mode 100644
index 0000000..24b8bda
--- /dev/null
+++ b/Demo/LoginRadius/api/advanced/reauthentication_api.py
@@ -0,0 +1,235 @@
+# -- coding: utf-8 --
+# Created by LoginRadius Development Team
+# Copyright 2019 LoginRadius Inc. All rights reserved.
+#
+
+
+class ReAuthenticationApi:
+
+ def __init__(self, lr_object):
+ """
+ :param lr_object: this is the reference to the parent LoginRadius object.
+ """
+ self._lr_object = lr_object
+
+ def mfa_re_authenticate(self, access_token, sms_template2_f_a=None):
+ """This API is used to trigger the Multi-Factor Autentication workflow for the provided access_token
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ sms_template2_f_a: SMS Template Name
+
+ Returns:
+ Response containing Definition of Complete Multi-Factor Authentication Settings data
+ 14.3
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(sms_template2_f_a)):
+ query_parameters["smsTemplate2FA"] = sms_template2_f_a
+
+ resource_path = "identity/v2/auth/account/reauth/2fa"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def mfa_re_authenticate_by_otp(self, access_token, reauth_by_otp_model):
+ """This API is used to re-authenticate via Multi-factor authentication by passing the One Time Password received via SMS
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ reauth_by_otp_model: Model Class containing Definition for MFA Reauthentication by OTP
+
+ Returns:
+ Complete user Multi-Factor Authentication Token data
+ 14.4
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(reauth_by_otp_model is None):
+ raise Exception(self._lr_object.get_validation_message("reauth_by_otp_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/account/reauth/2fa/otp"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_otp_model)
+
+ def mfa_re_authenticate_by_backup_code(self, access_token, reauth_by_backup_code_model):
+ """This API is used to re-authenticate by set of backup codes via access_token on the site that has Multi-factor authentication enabled in re-authentication for the user that does not have the device
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ reauth_by_backup_code_model: Model Class containing Definition for MFA Reauthentication by Backup code
+
+ Returns:
+ Complete user Multi-Factor Authentication Token data
+ 14.5
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(reauth_by_backup_code_model is None):
+ raise Exception(self._lr_object.get_validation_message("reauth_by_backup_code_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/account/reauth/2fa/backupcode"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_backup_code_model)
+
+ def mfa_re_authenticate_by_google_auth(self, access_token, reauth_by_google_authenticator_code_model):
+ """This API is used to re-authenticate via Multi-factor-authentication by passing the google authenticator code
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ reauth_by_google_authenticator_code_model: Model Class containing Definition for MFA Reauthentication by Google Authenticator
+
+ Returns:
+ Complete user Multi-Factor Authentication Token data
+ 14.6
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(reauth_by_google_authenticator_code_model is None):
+ raise Exception(self._lr_object.get_validation_message("reauth_by_google_authenticator_code_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/account/reauth/2fa/googleauthenticatorcode"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reauth_by_google_authenticator_code_model)
+
+ def mfa_re_authenticate_by_password(self, access_token, password_event_based_auth_model_with_lockout, sms_template2_f_a=None):
+ """This API is used to re-authenticate via Multi-factor-authentication by passing the password
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ password_event_based_auth_model_with_lockout: Model Class containing Definition of payload for PasswordEventBasedAuthModel with Lockout API
+ sms_template2_f_a: SMS Template Name
+
+ Returns:
+ Complete user Multi-Factor Authentication Token data
+ 14.7
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(password_event_based_auth_model_with_lockout is None):
+ raise Exception(self._lr_object.get_validation_message("password_event_based_auth_model_with_lockout"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(sms_template2_f_a)):
+ query_parameters["smsTemplate2FA"] = sms_template2_f_a
+
+ resource_path = "identity/v2/auth/account/reauth/password"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, password_event_based_auth_model_with_lockout)
+
+ def verify_multi_factor_otp_reauthentication(self, event_based_multi_factor_token, uid):
+ """This API is used on the server-side to validate and verify the re-authentication token created by the MFA re-authentication API. This API checks re-authentications created by OTP.
+
+ Args:
+ event_based_multi_factor_token: Model Class containing Definition for SecondFactorValidationToken
+ uid: UID, the unified identifier for each user account
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 18.38
+ """
+ if(event_based_multi_factor_token is None):
+ raise Exception(self._lr_object.get_validation_message("event_based_multi_factor_token"))
+
+ if(self._lr_object.is_null_or_whitespace(uid)):
+ raise Exception(self._lr_object.get_validation_message("uid"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+
+ resource_path = "identity/v2/manage/account/" + uid + "/reauth/2fa"
+ return self._lr_object.execute("POST", resource_path, query_parameters, event_based_multi_factor_token)
+
+ def verify_multi_factor_password_reauthentication(self, event_based_multi_factor_token, uid):
+ """This API is used on the server-side to validate and verify the re-authentication token created by the MFA re-authentication API. This API checks re-authentications created by password.
+
+ Args:
+ event_based_multi_factor_token: Model Class containing Definition for SecondFactorValidationToken
+ uid: UID, the unified identifier for each user account
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 18.39
+ """
+ if(event_based_multi_factor_token is None):
+ raise Exception(self._lr_object.get_validation_message("event_based_multi_factor_token"))
+
+ if(self._lr_object.is_null_or_whitespace(uid)):
+ raise Exception(self._lr_object.get_validation_message("uid"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+
+ resource_path = "identity/v2/manage/account/" + uid + "/reauth/password"
+ return self._lr_object.execute("POST", resource_path, query_parameters, event_based_multi_factor_token)
+
+ def verify_multi_factor_pin_reauthentication(self, event_based_multi_factor_token, uid):
+ """This API is used on the server-side to validate and verify the re-authentication token created by the MFA re-authentication API. This API checks re-authentications created by PIN.
+
+ Args:
+ event_based_multi_factor_token: Model Class containing Definition for SecondFactorValidationToken
+ uid: UID, the unified identifier for each user account
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 18.40
+ """
+ if(event_based_multi_factor_token is None):
+ raise Exception(self._lr_object.get_validation_message("event_based_multi_factor_token"))
+
+ if(self._lr_object.is_null_or_whitespace(uid)):
+ raise Exception(self._lr_object.get_validation_message("uid"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["apiSecret"] = self._lr_object.get_api_secret()
+
+ resource_path = "identity/v2/manage/account/" + uid + "/reauth/pin"
+ return self._lr_object.execute("POST", resource_path, query_parameters, event_based_multi_factor_token)
+
+ def verify_pin_authentication(self, access_token, pin_auth_event_based_auth_model_with_lockout, sms_template2_f_a=None):
+ """This API is used to validate the triggered MFA authentication flow with a password.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ pin_auth_event_based_auth_model_with_lockout: Model Class containing Definition of payload for PIN
+ sms_template2_f_a: SMS Template Name
+
+ Returns:
+ Response containing Definition response of MFA reauthentication
+ 42.13
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(pin_auth_event_based_auth_model_with_lockout is None):
+ raise Exception(self._lr_object.get_validation_message("pin_auth_event_based_auth_model_with_lockout"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(sms_template2_f_a)):
+ query_parameters["smsTemplate2FA"] = sms_template2_f_a
+
+ resource_path = "identity/v2/auth/account/reauth/pin"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, pin_auth_event_based_auth_model_with_lockout)
diff --git a/Demo/LoginRadius/api/advanced/webhook_api.py b/Demo/LoginRadius/api/advanced/webhook_api.py
index b34ca62..553a969 100644
--- a/Demo/LoginRadius/api/advanced/webhook_api.py
+++ b/Demo/LoginRadius/api/advanced/webhook_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/authentication/__init__.py b/Demo/LoginRadius/api/authentication/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/Demo/LoginRadius/api/authentication/authentication_api.py b/Demo/LoginRadius/api/authentication/authentication_api.py
index 2483e02..1757eb5 100644
--- a/Demo/LoginRadius/api/authentication/authentication_api.py
+++ b/Demo/LoginRadius/api/authentication/authentication_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -932,46 +932,6 @@ def user_registration_by_email(self, auth_user_registration_model, sott, email_t
resource_path = "identity/v2/auth/register"
return self._lr_object.execute("POST", resource_path, query_parameters, auth_user_registration_model)
- def user_registration_by_phone(self, auth_user_registration_model, sott, fields='',
- options='', sms_template=None, verification_url=None, welcome_email_template=None):
- """This API registers the new users into your Cloud Storage and triggers the phone verification process.
-
- Args:
- auth_user_registration_model: Model Class containing Definition of payload for Auth User Registration API
- sott: LoginRadius Secured One Time Token
- fields: The fields parameter filters the API response so that the response only includes a specific set of fields
- options: PreventVerificationEmail (Specifying this value prevents the verification email from being sent. Only applicable if you have the optional email verification flow)
- sms_template: SMS Template name
- verification_url: Email verification url
- welcome_email_template: Name of the welcome email template
-
- Returns:
- Response containing Definition of Complete Validation, UserProfile data and Access Token
- 17.1.2
- """
- if(auth_user_registration_model is None):
- raise Exception(self._lr_object.get_validation_message("auth_user_registration_model"))
-
- if(self._lr_object.is_null_or_whitespace(sott)):
- raise Exception(self._lr_object.get_validation_message("sott"))
-
- query_parameters = {}
- query_parameters["apiKey"] = self._lr_object.get_api_key()
- query_parameters["sott"] = sott
- if(not self._lr_object.is_null_or_whitespace(fields)):
- query_parameters["fields"] = fields
- if(not self._lr_object.is_null_or_whitespace(options)):
- query_parameters["options"] = options
- if(not self._lr_object.is_null_or_whitespace(sms_template)):
- query_parameters["smsTemplate"] = sms_template
- if(not self._lr_object.is_null_or_whitespace(verification_url)):
- query_parameters["verificationUrl"] = verification_url
- if(not self._lr_object.is_null_or_whitespace(welcome_email_template)):
- query_parameters["welcomeEmailTemplate"] = welcome_email_template
-
- resource_path = "identity/v2/auth/register"
- return self._lr_object.execute("POST", resource_path, query_parameters, auth_user_registration_model)
-
def user_registration_by_captcha(self, auth_user_registration_model_with_captcha, email_template=None, fields='',
options='', sms_template=None, verification_url=None, welcome_email_template=None):
"""This API creates a user in the database as well as sends a verification email to the user.
diff --git a/Demo/LoginRadius/api/authentication/onetouchlogin_api.py b/Demo/LoginRadius/api/authentication/onetouchlogin_api.py
index be00562..ca6af53 100644
--- a/Demo/LoginRadius/api/authentication/onetouchlogin_api.py
+++ b/Demo/LoginRadius/api/authentication/onetouchlogin_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/authentication/passwordlesslogin_api.py b/Demo/LoginRadius/api/authentication/passwordlesslogin_api.py
index 70e9bd9..cd46d45 100644
--- a/Demo/LoginRadius/api/authentication/passwordlesslogin_api.py
+++ b/Demo/LoginRadius/api/authentication/passwordlesslogin_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/authentication/phoneauthentication_api.py b/Demo/LoginRadius/api/authentication/phoneauthentication_api.py
index 6ce862d..b85706a 100644
--- a/Demo/LoginRadius/api/authentication/phoneauthentication_api.py
+++ b/Demo/LoginRadius/api/authentication/phoneauthentication_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -125,7 +125,7 @@ def phone_verification_otp_by_access_token(self, access_token, otp, sms_template
"""This API is used to consume the verification code sent to verify a user's phone number. Use this call for front-end purposes in cases where the user is already logged in by passing the user's access token.
Args:
- access_token: Access_Token
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
otp: The Verification Code
sms_template: SMS Template name
@@ -141,16 +141,14 @@ def phone_verification_otp_by_access_token(self, access_token, otp, sms_template
raise Exception(self._lr_object.get_validation_message("otp"))
query_parameters = {}
+ query_parameters["access_token"] = access_token
query_parameters["apiKey"] = self._lr_object.get_api_key()
query_parameters["otp"] = otp
if(not self._lr_object.is_null_or_whitespace(sms_template)):
query_parameters["smsTemplate"] = sms_template
- body_parameters = {}
- body_parameters["access_token"] = access_token
-
resource_path = "identity/v2/auth/phone/otp"
- return self._lr_object.execute("PUT", resource_path, query_parameters, body_parameters)
+ return self._lr_object.execute("PUT", resource_path, query_parameters, None)
def phone_resend_verification_otp(self, phone, sms_template=None):
"""This API is used to resend a verification OTP to verify a user's Phone Number. The user will receive a verification code that they will need to input
@@ -198,12 +196,12 @@ def phone_resend_verification_otp_by_token(self, access_token, phone, sms_templa
raise Exception(self._lr_object.get_validation_message("phone"))
query_parameters = {}
+ query_parameters["access_token"] = access_token
query_parameters["apiKey"] = self._lr_object.get_api_key()
if(not self._lr_object.is_null_or_whitespace(sms_template)):
query_parameters["smsTemplate"] = sms_template
body_parameters = {}
- body_parameters["access_token"] = access_token
body_parameters["phone"] = phone
resource_path = "identity/v2/auth/phone/otp"
@@ -244,7 +242,7 @@ def check_phone_number_availability(self, phone):
"""This API is used to check the Phone Number exists or not on your site.
Args:
- phone: LoginRadius API Key
+ phone: The Registered Phone Number
Returns:
Response containing Definition Complete ExistResponse data
@@ -281,3 +279,43 @@ def remove_phone_id_by_access_token(self, access_token):
resource_path = "identity/v2/auth/phone"
return self._lr_object.execute("DELETE", resource_path, query_parameters, None)
+
+ def user_registration_by_phone(self, auth_user_registration_model, sott, fields='',
+ options='', sms_template=None, verification_url=None, welcome_email_template=None):
+ """This API registers the new users into your Cloud Storage and triggers the phone verification process.
+
+ Args:
+ auth_user_registration_model: Model Class containing Definition of payload for Auth User Registration API
+ sott: LoginRadius Secured One Time Token
+ fields: The fields parameter filters the API response so that the response only includes a specific set of fields
+ options: PreventVerificationEmail (Specifying this value prevents the verification email from being sent. Only applicable if you have the optional email verification flow)
+ sms_template: SMS Template name
+ verification_url: Email verification url
+ welcome_email_template: Name of the welcome email template
+
+ Returns:
+ Response containing Definition of Complete Validation, UserProfile data and Access Token
+ 17.1.2
+ """
+ if(auth_user_registration_model is None):
+ raise Exception(self._lr_object.get_validation_message("auth_user_registration_model"))
+
+ if(self._lr_object.is_null_or_whitespace(sott)):
+ raise Exception(self._lr_object.get_validation_message("sott"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["sott"] = sott
+ if(not self._lr_object.is_null_or_whitespace(fields)):
+ query_parameters["fields"] = fields
+ if(not self._lr_object.is_null_or_whitespace(options)):
+ query_parameters["options"] = options
+ if(not self._lr_object.is_null_or_whitespace(sms_template)):
+ query_parameters["smsTemplate"] = sms_template
+ if(not self._lr_object.is_null_or_whitespace(verification_url)):
+ query_parameters["verificationUrl"] = verification_url
+ if(not self._lr_object.is_null_or_whitespace(welcome_email_template)):
+ query_parameters["welcomeEmailTemplate"] = welcome_email_template
+
+ resource_path = "identity/v2/auth/register"
+ return self._lr_object.execute("POST", resource_path, query_parameters, auth_user_registration_model)
diff --git a/Demo/LoginRadius/api/authentication/pinauthentication_api.py b/Demo/LoginRadius/api/authentication/pinauthentication_api.py
new file mode 100644
index 0000000..5042fd5
--- /dev/null
+++ b/Demo/LoginRadius/api/authentication/pinauthentication_api.py
@@ -0,0 +1,311 @@
+# -- coding: utf-8 --
+# Created by LoginRadius Development Team
+# Copyright 2019 LoginRadius Inc. All rights reserved.
+#
+
+
+class PINAuthenticationApi:
+
+ def __init__(self, lr_object):
+ """
+ :param lr_object: this is the reference to the parent LoginRadius object.
+ """
+ self._lr_object = lr_object
+
+ def pin_login(self, login_by_pin_model, session_token):
+ """This API is used to login a user by pin and session_token.
+
+ Args:
+ login_by_pin_model: Model Class containing Definition of payload for LoginByPin API
+ session_token: Session Token of user
+
+ Returns:
+ Response containing User Profile Data and access token
+ 9.22
+ """
+ if(login_by_pin_model is None):
+ raise Exception(self._lr_object.get_validation_message("login_by_pin_model"))
+
+ if(self._lr_object.is_null_or_whitespace(session_token)):
+ raise Exception(self._lr_object.get_validation_message("session_token"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["session_token"] = session_token
+
+ resource_path = "identity/v2/auth/login/pin"
+ return self._lr_object.execute("POST", resource_path, query_parameters, login_by_pin_model)
+
+ def send_forgot_pin_email_by_email(self, forgot_pin_link_by_email_model, email_template=None, reset_pin_url=None):
+ """This API sends the reset pin email to specified email address.
+
+ Args:
+ forgot_pin_link_by_email_model: Model Class containing Definition for Forgot Pin Link By Email API
+ email_template: Email template name
+ reset_pin_url: Reset PIN Url
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.1
+ """
+ if(forgot_pin_link_by_email_model is None):
+ raise Exception(self._lr_object.get_validation_message("forgot_pin_link_by_email_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(email_template)):
+ query_parameters["emailTemplate"] = email_template
+ if(not self._lr_object.is_null_or_whitespace(reset_pin_url)):
+ query_parameters["resetPINUrl"] = reset_pin_url
+
+ resource_path = "identity/v2/auth/pin/forgot/email"
+ return self._lr_object.execute("POST", resource_path, query_parameters, forgot_pin_link_by_email_model)
+
+ def send_forgot_pin_email_by_username(self, forgot_pin_link_by_user_name_model, email_template=None, reset_pin_url=None):
+ """This API sends the reset pin email using username.
+
+ Args:
+ forgot_pin_link_by_user_name_model: Model Class containing Definition for Forgot Pin Link By UserName API
+ email_template: Email template name
+ reset_pin_url: Reset PIN Url
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.2
+ """
+ if(forgot_pin_link_by_user_name_model is None):
+ raise Exception(self._lr_object.get_validation_message("forgot_pin_link_by_user_name_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(email_template)):
+ query_parameters["emailTemplate"] = email_template
+ if(not self._lr_object.is_null_or_whitespace(reset_pin_url)):
+ query_parameters["resetPINUrl"] = reset_pin_url
+
+ resource_path = "identity/v2/auth/pin/forgot/username"
+ return self._lr_object.execute("POST", resource_path, query_parameters, forgot_pin_link_by_user_name_model)
+
+ def reset_pin_by_reset_token(self, reset_pin_by_reset_token):
+ """This API is used to reset pin using reset token.
+
+ Args:
+ reset_pin_by_reset_token: Model Class containing Definition of payload for Reset Pin By Reset Token API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.3
+ """
+ if(reset_pin_by_reset_token is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_reset_token"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/token"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_reset_token)
+
+ def reset_pin_by_email_and_security_answer(self, reset_pin_by_security_question_answer_and_email_model):
+ """This API is used to reset pin using security question answer and email.
+
+ Args:
+ reset_pin_by_security_question_answer_and_email_model: Model Class containing Definition of payload for Reset Pin By Security Question and Email API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.4
+ """
+ if(reset_pin_by_security_question_answer_and_email_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_security_question_answer_and_email_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/securityanswer/email"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_security_question_answer_and_email_model)
+
+ def reset_pin_by_username_and_security_answer(self, reset_pin_by_security_question_answer_and_username_model):
+ """This API is used to reset pin using security question answer and username.
+
+ Args:
+ reset_pin_by_security_question_answer_and_username_model: Model Class containing Definition of payload for Reset Pin By Security Question and UserName API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.5
+ """
+ if(reset_pin_by_security_question_answer_and_username_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_security_question_answer_and_username_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/securityanswer/username"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_security_question_answer_and_username_model)
+
+ def reset_pin_by_phone_and_security_answer(self, reset_pin_by_security_question_answer_and_phone_model):
+ """This API is used to reset pin using security question answer and phone.
+
+ Args:
+ reset_pin_by_security_question_answer_and_phone_model: Model Class containing Definition of payload for Reset Pin By Security Question and Phone API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.6
+ """
+ if(reset_pin_by_security_question_answer_and_phone_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_security_question_answer_and_phone_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/securityanswer/phone"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_security_question_answer_and_phone_model)
+
+ def send_forgot_pin_sms_by_phone(self, forgot_pin_otp_by_phone_model, sms_template=None):
+ """This API sends the OTP to specified phone number
+
+ Args:
+ forgot_pin_otp_by_phone_model: Model Class containing Definition for Forgot Pin Otp By Phone API
+ sms_template:
+
+ Returns:
+ Response Containing Validation Data and SMS Data
+ 42.7
+ """
+ if(forgot_pin_otp_by_phone_model is None):
+ raise Exception(self._lr_object.get_validation_message("forgot_pin_otp_by_phone_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ if(not self._lr_object.is_null_or_whitespace(sms_template)):
+ query_parameters["smsTemplate"] = sms_template
+
+ resource_path = "identity/v2/auth/pin/forgot/otp"
+ return self._lr_object.execute("POST", resource_path, query_parameters, forgot_pin_otp_by_phone_model)
+
+ def change_pin_by_access_token(self, access_token, change_pin_model):
+ """This API is used to change a user's PIN using access token.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ change_pin_model: Model Class containing Definition for change PIN Property
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.8
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(change_pin_model is None):
+ raise Exception(self._lr_object.get_validation_message("change_pin_model"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/change"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, change_pin_model)
+
+ def reset_pin_by_phone_and_otp(self, reset_pin_by_phone_and_otp_model):
+ """This API is used to reset pin using phoneId and OTP.
+
+ Args:
+ reset_pin_by_phone_and_otp_model: Model Class containing Definition of payload for Reset Pin By Phone and Otp API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.9
+ """
+ if(reset_pin_by_phone_and_otp_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_phone_and_otp_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/otp/phone"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_phone_and_otp_model)
+
+ def reset_pin_by_email_and_otp(self, reset_pin_by_email_and_otp_model):
+ """This API is used to reset pin using email and OTP.
+
+ Args:
+ reset_pin_by_email_and_otp_model: Model Class containing Definition of payload for Reset Pin By Email and Otp API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.10
+ """
+ if(reset_pin_by_email_and_otp_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_email_and_otp_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/otp/email"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_email_and_otp_model)
+
+ def reset_pin_by_username_and_otp(self, reset_pin_by_username_and_otp_model):
+ """This API is used to reset pin using username and OTP.
+
+ Args:
+ reset_pin_by_username_and_otp_model: Model Class containing Definition of payload for Reset Pin By Username and Otp API
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 42.11
+ """
+ if(reset_pin_by_username_and_otp_model is None):
+ raise Exception(self._lr_object.get_validation_message("reset_pin_by_username_and_otp_model"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+
+ resource_path = "identity/v2/auth/pin/reset/otp/username"
+ return self._lr_object.execute("PUT", resource_path, query_parameters, reset_pin_by_username_and_otp_model)
+
+ def set_pin_by_pin_auth_token(self, pin_required_model, pin_auth_token):
+ """This API is used to change a user's PIN using Pin Auth token.
+
+ Args:
+ pin_required_model: Model Class containing Definition for PIN
+ pin_auth_token: Pin Auth Token
+
+ Returns:
+ Response containing User Profile Data and access token
+ 42.12
+ """
+ if(pin_required_model is None):
+ raise Exception(self._lr_object.get_validation_message("pin_required_model"))
+
+ if(self._lr_object.is_null_or_whitespace(pin_auth_token)):
+ raise Exception(self._lr_object.get_validation_message("pin_auth_token"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["pinAuthToken"] = pin_auth_token
+
+ resource_path = "identity/v2/auth/pin/set/pinauthtoken"
+ return self._lr_object.execute("POST", resource_path, query_parameters, pin_required_model)
+
+ def in_validate_pin_session_token(self, session_token):
+ """This API is used to invalidate pin session token.
+
+ Args:
+ session_token: Session Token of user
+
+ Returns:
+ Response containing Definition of Complete Validation data
+ 44.1
+ """
+
+ if(self._lr_object.is_null_or_whitespace(session_token)):
+ raise Exception(self._lr_object.get_validation_message("session_token"))
+
+ query_parameters = {}
+ query_parameters["apiKey"] = self._lr_object.get_api_key()
+ query_parameters["session_token"] = session_token
+
+ resource_path = "identity/v2/auth/session_token/invalidate"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
diff --git a/Demo/LoginRadius/api/authentication/riskbasedauthentication_api.py b/Demo/LoginRadius/api/authentication/riskbasedauthentication_api.py
index f060def..5181f0d 100644
--- a/Demo/LoginRadius/api/authentication/riskbasedauthentication_api.py
+++ b/Demo/LoginRadius/api/authentication/riskbasedauthentication_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/authentication/smartlogin_api.py b/Demo/LoginRadius/api/authentication/smartlogin_api.py
index 229ea5d..7bd82a4 100644
--- a/Demo/LoginRadius/api/authentication/smartlogin_api.py
+++ b/Demo/LoginRadius/api/authentication/smartlogin_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
diff --git a/Demo/LoginRadius/api/social/__init__.py b/Demo/LoginRadius/api/social/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/Demo/LoginRadius/api/social/nativesocial_api.py b/Demo/LoginRadius/api/social/nativesocial_api.py
index 268312d..395d05a 100644
--- a/Demo/LoginRadius/api/social/nativesocial_api.py
+++ b/Demo/LoginRadius/api/social/nativesocial_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -13,7 +13,7 @@ def __init__(self, lr_object):
self._lr_object = lr_object
def get_access_token_by_facebook_access_token(self, fb__access__token):
- """The API is used to get LoginRadius access token by sending Facebook’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Facebook's access token. It will be valid for the specific duration of time specified in the response.
Args:
fb__access__token: Facebook Access Token
@@ -34,7 +34,7 @@ def get_access_token_by_facebook_access_token(self, fb__access__token):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_twitter_access_token(self, tw__access__token, tw__token__secret):
- """The API is used to get LoginRadius access token by sending Twitter’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Twitter's access token. It will be valid for the specific duration of time specified in the response.
Args:
tw__access__token: Twitter Access Token
@@ -60,7 +60,7 @@ def get_access_token_by_twitter_access_token(self, tw__access__token, tw__token_
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_google_access_token(self, google__access__token, client_id=None, refresh_token=None):
- """The API is used to get LoginRadius access token by sending Google’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Google's access token. It will be valid for the specific duration of time specified in the response.
Args:
google__access__token: Google Access Token
@@ -108,7 +108,7 @@ def get_access_token_by_google_j_w_t_access_token(self, id__token):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_linkedin_access_token(self, ln__access__token):
- """The API is used to get LoginRadius access token by sending Linkedin’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Linkedin's access token. It will be valid for the specific duration of time specified in the response.
Args:
ln__access__token: Linkedin Access Token
@@ -129,7 +129,7 @@ def get_access_token_by_linkedin_access_token(self, ln__access__token):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_foursquare_access_token(self, fs__access__token):
- """The API is used to get LoginRadius access token by sending Foursquare’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Foursquare's access token. It will be valid for the specific duration of time specified in the response.
Args:
fs__access__token: Foursquare Access Token
@@ -150,7 +150,7 @@ def get_access_token_by_foursquare_access_token(self, fs__access__token):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_vkontakte_access_token(self, vk_access_token):
- """The API is used to get LoginRadius access token by sending Vkontakte’s access token. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Vkontakte's access token. It will be valid for the specific duration of time specified in the response.
Args:
vk_access_token: Vkontakte Access Token
@@ -171,7 +171,7 @@ def get_access_token_by_vkontakte_access_token(self, vk_access_token):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_access_token_by_google_auth_code(self, google_authcode):
- """The API is used to get LoginRadius access token by sending Google’s AuthCode. It will be valid for the specific duration of time specified in the response.
+ """The API is used to get LoginRadius access token by sending Google's AuthCode. It will be valid for the specific duration of time specified in the response.
Args:
google_authcode: Google AuthCode
diff --git a/Demo/LoginRadius/api/social/social_api.py b/Demo/LoginRadius/api/social/social_api.py
index 132a692..9b6550c 100644
--- a/Demo/LoginRadius/api/social/social_api.py
+++ b/Demo/LoginRadius/api/social/social_api.py
@@ -1,5 +1,5 @@
# -- coding: utf-8 --
-# Created by LoginRadius Development Team
+# Created by LoginRadius Development Team
# Copyright 2019 LoginRadius Inc. All rights reserved.
#
@@ -109,7 +109,7 @@ def get_active_session(self, token):
Returns:
Response containing Definition for Complete active sessions
- 20.11
+ 20.11.1
"""
if(self._lr_object.is_null_or_whitespace(token)):
@@ -131,7 +131,7 @@ def get_active_session_by_account_id(self, account_id):
Returns:
Response containing Definition for Complete active sessions
- 20.12
+ 20.11.2
"""
if(self._lr_object.is_null_or_whitespace(account_id)):
@@ -153,7 +153,7 @@ def get_active_session_by_profile_id(self, profile_id):
Returns:
Response containing Definition for Complete active sessions
- 20.13
+ 20.11.3
"""
if(self._lr_object.is_null_or_whitespace(profile_id)):
@@ -175,7 +175,7 @@ def get_albums(self, access_token):
Returns:
Response Containing List of Album Data
- 22.1
+ 22.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -187,15 +187,40 @@ def get_albums(self, access_token):
resource_path = "api/v2/album"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_albums_with_cursor(self, access_token, next_cursor):
+ """Supported Providers: Facebook, Google, Live, Vkontakte.
This API returns the photo albums associated with the passed in access tokens Social Profile.
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Albums with next cursor
+ 22.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/album"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_audios(self, access_token):
- """The Audio API is used to get audio files data from the user’s social account.
Supported Providers: Live, Vkontakte
+ """The Audio API is used to get audio files data from the user's social account.
Supported Providers: Live, Vkontakte
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of Audio Data
- 24.1
+ 24.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -207,15 +232,40 @@ def get_audios(self, access_token):
resource_path = "api/v2/audio"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_audios_with_cursor(self, access_token, next_cursor):
+ """The Audio API is used to get audio files data from the user's social account.
Supported Providers: Live, Vkontakte
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Audio with next cursor
+ 24.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/audio"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_check_ins(self, access_token):
- """The Check In API is used to get check Ins data from the user’s social account.
Supported Providers: Facebook, Foursquare, Vkontakte
+ """The Check In API is used to get check Ins data from the user's social account.
Supported Providers: Facebook, Foursquare, Vkontakte
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of CheckIn Data
- 25.1
+ 25.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -227,8 +277,33 @@ def get_check_ins(self, access_token):
resource_path = "api/v2/checkin"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_check_ins_with_cursor(self, access_token, next_cursor):
+ """The Check In API is used to get check Ins data from the user's social account.
Supported Providers: Facebook, Foursquare, Vkontakte
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Checkins with next cursor
+ 25.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/checkin"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_contacts(self, access_token, next_cursor=''):
- """The Contact API is used to get contacts/friends/connections data from the user’s social account.This is one of the APIs that makes up the LoginRadius Friend Invite System. The data will normalized into LoginRadius’ standard data format. This API requires setting permissions in your LoginRadius Dashboard.
Note: Facebook restricts access to the list of friends that is returned. When using the Contacts API with Facebook you will only receive friends that have accepted some permissions with your app.
Supported Providers: Facebook, Foursquare, Google, LinkedIn, Live, Twitter, Vkontakte, Yahoo
+ """The Contact API is used to get contacts/friends/connections data from the user's social account.This is one of the APIs that makes up the LoginRadius Friend Invite System. The data will normalized into LoginRadius' standard data format. This API requires setting permissions in your LoginRadius Dashboard.
Note: Facebook restricts access to the list of friends that is returned. When using the Contacts API with Facebook you will only receive friends that have accepted some permissions with your app.
Supported Providers: Facebook, Foursquare, Google, LinkedIn, Live, Twitter, Vkontakte, Yahoo
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -251,34 +326,59 @@ def get_contacts(self, access_token, next_cursor=''):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_events(self, access_token):
- """The Event API is used to get the event data from the user’s social account.
Supported Providers: Facebook, Live
+ """The Event API is used to get the event data from the user's social account.
Supported Providers: Facebook, Live
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of Events Data
- 28.1
+ 28.2.1
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+
+ resource_path = "api/v2/event"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
+ def get_events_with_cursor(self, access_token, next_cursor):
+ """The Event API is used to get the event data from the user's social account.
Supported Providers: Facebook, Live
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Events with next cursor
+ 28.2.2
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
raise Exception(self._lr_object.get_validation_message("access_token"))
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
query_parameters = {}
query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
resource_path = "api/v2/event"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_followings(self, access_token):
- """Get the following user list from the user’s social account.
Supported Providers: Twitter
+ """Get the following user list from the user's social account.
Supported Providers: Twitter
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of Contacts Data
- 29.1
+ 29.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -290,15 +390,40 @@ def get_followings(self, access_token):
resource_path = "api/v2/following"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_followings_with_cursor(self, access_token, next_cursor):
+ """Get the following user list from the user's social account.
Supported Providers: Twitter
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response containing Definition of Contact Data with Cursor
+ 29.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/following"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_groups(self, access_token):
- """The Group API is used to get group data from the user’s social account.
Supported Providers: Facebook, Vkontakte
+ """The Group API is used to get group data from the user's social account.
Supported Providers: Facebook, Vkontakte
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of Groups Data
- 30.1
+ 30.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -310,15 +435,40 @@ def get_groups(self, access_token):
resource_path = "api/v2/group"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_groups_with_cursor(self, access_token, next_cursor):
+ """The Group API is used to get group data from the user's social account.
Supported Providers: Facebook, Vkontakte
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Groups with next cursor
+ 30.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/group"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_likes(self, access_token):
- """The Like API is used to get likes data from the user’s social account.
Supported Providers: Facebook
+ """The Like API is used to get likes data from the user's social account.
Supported Providers: Facebook
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
Returns:
Response Containing List of Likes Data
- 31.1
+ 31.2.1
"""
if(self._lr_object.is_null_or_whitespace(access_token)):
@@ -330,8 +480,33 @@ def get_likes(self, access_token):
resource_path = "api/v2/like"
return self._lr_object.execute("GET", resource_path, query_parameters, None)
+ def get_likes_with_cursor(self, access_token, next_cursor):
+ """The Like API is used to get likes data from the user's social account.
Supported Providers: Facebook
+
+ Args:
+ access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
+ next_cursor: Cursor value if not all contacts can be retrieved once.
+
+ Returns:
+ Response Model containing Likes with next cursor
+ 31.2.2
+ """
+
+ if(self._lr_object.is_null_or_whitespace(access_token)):
+ raise Exception(self._lr_object.get_validation_message("access_token"))
+
+ if(self._lr_object.is_null_or_whitespace(next_cursor)):
+ raise Exception(self._lr_object.get_validation_message("next_cursor"))
+
+ query_parameters = {}
+ query_parameters["access_token"] = access_token
+ query_parameters["nextCursor"] = next_cursor
+
+ resource_path = "api/v2/like"
+ return self._lr_object.execute("GET", resource_path, query_parameters, None)
+
def get_mentions(self, access_token):
- """The Mention API is used to get mentions data from the user’s social account.
Supported Providers: Twitter
+ """The Mention API is used to get mentions data from the user's social account.
Supported Providers: Twitter
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -352,7 +527,7 @@ def get_mentions(self, access_token):
def post_message(self, access_token, message, subject,
to):
- """Post Message API is used to post messages to the user’s contacts.
Supported Providers: Twitter, LinkedIn
The Message API is used to post messages to the user’s contacts. This is one of the APIs that makes up the LoginRadius Friend Invite System. After using the Contact API, you can send messages to the retrieved contacts. This API requires setting permissions in your LoginRadius Dashboard.
GET & POST Message API work the same way except the API method is different
+ """Post Message API is used to post messages to the user's contacts.
Supported Providers: Twitter, LinkedIn
The Message API is used to post messages to the user?s contacts. This is one of the APIs that makes up the LoginRadius Friend Invite System. After using the Contact API, you can send messages to the retrieved contacts. This API requires setting permissions in your LoginRadius Dashboard.
GET & POST Message API work the same way except the API method is different
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -387,7 +562,7 @@ def post_message(self, access_token, message, subject,
return self._lr_object.execute("POST", resource_path, query_parameters, None)
def get_page(self, access_token, page_name):
- """The Page API is used to get the page data from the user’s social account.
Supported Providers: Facebook, LinkedIn
+ """The Page API is used to get the page data from the user's social account.
Supported Providers: Facebook, LinkedIn
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -412,7 +587,7 @@ def get_page(self, access_token, page_name):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_photos(self, access_token, album_id):
- """The Photo API is used to get photo data from the user’s social account.
Supported Providers: Facebook, Foursquare, Google, Live, Vkontakte
+ """The Photo API is used to get photo data from the user's social account.
Supported Providers: Facebook, Foursquare, Google, Live, Vkontakte
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -437,7 +612,7 @@ def get_photos(self, access_token, album_id):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_posts(self, access_token):
- """The Post API is used to get post message data from the user’s social account.
Supported Providers: Facebook
+ """The Post API is used to get post message data from the user's social account.
Supported Providers: Facebook
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -459,7 +634,7 @@ def get_posts(self, access_token):
def status_posting(self, access_token, caption, description,
imageurl, status, title, url,
shorturl='0'):
- """The Status API is used to update the status on the user’s wall.
Supported Providers: Facebook, Twitter, LinkedIn
+ """The Status API is used to update the status on the user's wall.
Supported Providers: Facebook, Twitter, LinkedIn
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -511,28 +686,8 @@ def status_posting(self, access_token, caption, description,
resource_path = "api/v2/status"
return self._lr_object.execute("POST", resource_path, query_parameters, None)
- def get_status(self, access_token):
- """The Status API is used to get the status messages from the user’s social account.
-
- Args:
- access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
-
- Returns:
- Response Containing List of Status Data
- 37.3
- """
-
- if(self._lr_object.is_null_or_whitespace(access_token)):
- raise Exception(self._lr_object.get_validation_message("access_token"))
-
- query_parameters = {}
- query_parameters["access_token"] = access_token
-
- resource_path = "api/v2/status"
- return self._lr_object.execute("GET", resource_path, query_parameters, None)
-
def trackable_status_posting(self, access_token, status_model):
- """The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user’s wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
POST Input Parameter Format: application/x-www-form-urlencoded
+ """The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user's wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
POST Input Parameter Format: application/x-www-form-urlencoded
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -556,7 +711,7 @@ def trackable_status_posting(self, access_token, status_model):
def get_trackable_status_stats(self, access_token, caption, description,
imageurl, status, title, url):
- """The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user’s wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
+ """The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user's wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -627,7 +782,7 @@ def trackable_status_fetching(self, post_id):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_social_user_profile(self, access_token, fields=''):
- """The User Profile API is used to get social profile data from the user’s social account after authentication.
Supported Providers: All
+ """The User Profile API is used to get social profile data from the user's social account after authentication.
Supported Providers: All
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -650,7 +805,7 @@ def get_social_user_profile(self, access_token, fields=''):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_refreshed_social_user_profile(self, access_token, fields=''):
- """The User Profile API is used to get the latest updated social profile data from the user’s social account after authentication. The social profile will be retrieved via oAuth and OpenID protocols. The data is normalized into LoginRadius’ standard data format. This API should be called using the access token retrieved from the refresh access token API.
+ """The User Profile API is used to get the latest updated social profile data from the user's social account after authentication. The social profile will be retrieved via oAuth and OpenID protocols. The data is normalized into LoginRadius' standard data format. This API should be called using the access token retrieved from the refresh access token API.
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
@@ -673,7 +828,7 @@ def get_refreshed_social_user_profile(self, access_token, fields=''):
return self._lr_object.execute("GET", resource_path, query_parameters, None)
def get_videos(self, access_token, next_cursor):
- """The Video API is used to get video files data from the user’s social account.
Supported Providers: Facebook, Google, Live, Vkontakte
+ """The Video API is used to get video files data from the user's social account.
Supported Providers: Facebook, Google, Live, Vkontakte
Args:
access_token: Uniquely generated identifier key by LoginRadius that is activated after successful authentication.
diff --git a/README.md b/README.md
index 0ea8e18..cfa865f 100755
--- a/README.md
+++ b/README.md
@@ -15,18 +15,13 @@ This will work with 2.0 API specifications.
LoginRadius is an Identity Management Platform that simplifies user registration while securing data. LoginRadius Platform simplifies and secures your user registration process, increases conversion with Social Login that combines 30 major social platforms, and offers a full solution with Traditional User Registration. You can gather a wealth of user profile data from Social Login or Traditional User Registration.
-Python Library
-=====
+## Documentation
-------
>Disclaimer:
This library is meant to help you with a quick implementation of the LoginRadius platform and also to serve as a reference point for the LoginRadius API. Keep in mind that it is an open source library, which means you are free to download and customize the library functions based on your specific application needs.
-## Installation
-
-SDK library and demo are available on [GitHub](https://github.com/LoginRadius/python-sdk).
-
### Prerequisites
You will need at least Python - 2.7 or greater. LoginRadius module utilizes the [namedtuple](https://docs.python.org/2/library/collections.html#collections.namedtuple) from the collections library and the [import_module](https://docs.python.org/2/library/importlib.html) from importlib.
@@ -34,13 +29,13 @@ You will need at least Python - 2.7 or greater. LoginRadius module utilizes the
Using pip
```
- pip install loginradius-v2==10.0.0-beta
+ pip install loginradius-v2==10.0.0
```
or with easy_install
```
- easy_install loginradius-v2==10.0.0-beta
+ easy_install loginradius-v2==10.0.0
```
### Install From Source
@@ -94,8 +89,6 @@ To enable API request signing, set the value of 'API_REQUEST_SIGNING' to True
LR.API_REQUEST_SIGNING = True
```
-APIs
-
### Authentication API
@@ -119,7 +112,6 @@ List of APIs in this Section:
* POST : [Auth Login by Username](#LoginByUserName-post-)
* POST : [Auth Forgot Password](#ForgotPassword-post-)
* POST : [Auth User Registration by Email](#UserRegistrationByEmail-post-)
-* POST : [Phone User Registration by SMS](#UserRegistrationByPhone-post-)
* POST : [Auth User Registration By Captcha](#UserRegistrationByCaptcha-post-)
* GET : [Get Security Questions By Email](#GetSecurityQuestionsByEmail-get-)
* GET : [Get Security Questions By UserName](#GetSecurityQuestionsByUserName-get-)
@@ -156,11 +148,11 @@ user_profile_update_model = {
} #Required
email_template = "" #Optional
fields = "" #Optional
-null_support = True #Optional
+null_support = "True" #Optional
sms_template = "" #Optional
verification_url = "" #Optional
-loginradius.authentication.update_profile_by_access_token(access_token, user_profile_update_model, email_template, fields, null_support, sms_template, verification_url)
+result = loginradius.authentication.update_profile_by_access_token(access_token, user_profile_update_model, email_template, fields, null_support, sms_template, verification_url)
```
@@ -176,7 +168,7 @@ unlock_profile_model = {
"g-recaptcha-response" : ""
} #Required
-loginradius.authentication.unlock_account_by_token(access_token, unlock_profile_model)
+result = loginradius.authentication.unlock_account_by_token(access_token, unlock_profile_model)
```
@@ -195,7 +187,7 @@ fields = "" #Optional
url = "" #Optional
welcome_email_template = "" #Optional
-loginradius.authentication.verify_email_by_otp(email_verification_by_otp_model, fields, url, welcome_email_template)
+result = loginradius.authentication.verify_email_by_otp(email_verification_by_otp_model, fields, url, welcome_email_template)
```
@@ -212,7 +204,7 @@ reset_password_by_security_answer_and_email_model = {
"securityAnswer" : {"QuestionID":"Answer"}
} #Required
-loginradius.authentication.reset_password_by_security_answer_and_email(reset_password_by_security_answer_and_email_model)
+result = loginradius.authentication.reset_password_by_security_answer_and_email(reset_password_by_security_answer_and_email_model)
```
@@ -229,7 +221,7 @@ reset_password_by_security_answer_and_phone_model = {
"securityAnswer" : {"QuestionID":"Answer"}
} #Required
-loginradius.authentication.reset_password_by_security_answer_and_phone(reset_password_by_security_answer_and_phone_model)
+result = loginradius.authentication.reset_password_by_security_answer_and_phone(reset_password_by_security_answer_and_phone_model)
```
@@ -246,7 +238,7 @@ reset_password_by_security_answer_and_user_name_model = {
"userName" : ""
} #Required
-loginradius.authentication.reset_password_by_security_answer_and_user_name(reset_password_by_security_answer_and_user_name_model)
+result = loginradius.authentication.reset_password_by_security_answer_and_user_name(reset_password_by_security_answer_and_user_name_model)
```
@@ -262,7 +254,7 @@ reset_password_by_reset_token_model = {
"resetToken" : ""
} #Required
-loginradius.authentication.reset_password_by_reset_token(reset_password_by_reset_token_model)
+result = loginradius.authentication.reset_password_by_reset_token(reset_password_by_reset_token_model)
```
@@ -279,7 +271,7 @@ reset_password_by_email_and_otp_model = {
"password" : ""
} #Required
-loginradius.authentication.reset_password_by_email_otp(reset_password_by_email_and_otp_model)
+result = loginradius.authentication.reset_password_by_email_otp(reset_password_by_email_and_otp_model)
```
@@ -296,7 +288,7 @@ reset_password_by_user_name_model = {
"userName" : ""
} #Required
-loginradius.authentication.reset_password_by_otp_and_user_name(reset_password_by_user_name_model)
+result = loginradius.authentication.reset_password_by_otp_and_user_name(reset_password_by_user_name_model)
```
@@ -311,7 +303,7 @@ access_token = "" #Required
new_password = "" #Required
old_password = "" #Required
-loginradius.authentication.change_password(access_token, new_password, old_password)
+result = loginradius.authentication.change_password(access_token, new_password, old_password)
```
@@ -325,7 +317,7 @@ loginradius.authentication.change_password(access_token, new_password, old_passw
access_token = "" #Required
candidate_token = "" #Required
-loginradius.authentication.link_social_identities(access_token, candidate_token)
+result = loginradius.authentication.link_social_identities(access_token, candidate_token)
```
@@ -339,7 +331,7 @@ loginradius.authentication.link_social_identities(access_token, candidate_token)
access_token = "" #Required
username = "" #Required
-loginradius.authentication.set_or_change_user_name(access_token, username)
+result = loginradius.authentication.set_or_change_user_name(access_token, username)
```
@@ -354,7 +346,7 @@ email = "" #Required
email_template = "" #Optional
verification_url = "" #Optional
-loginradius.authentication.auth_resend_email_verification(email, email_template, verification_url)
+result = loginradius.authentication.auth_resend_email_verification(email, email_template, verification_url)
```
@@ -371,7 +363,7 @@ type = "" #Required
email_template = "" #Optional
verification_url = "" #Optional
-loginradius.authentication.add_email(access_token, email, type, email_template, verification_url)
+result = loginradius.authentication.add_email(access_token, email, type, email_template, verification_url)
```
@@ -391,7 +383,7 @@ fields = "" #Optional
login_url = "" #Optional
verification_url = "" #Optional
-loginradius.authentication.login_by_email(email_authentication_model, email_template, fields, login_url, verification_url)
+result = loginradius.authentication.login_by_email(email_authentication_model, email_template, fields, login_url, verification_url)
```
@@ -411,7 +403,7 @@ fields = "" #Optional
login_url = "" #Optional
verification_url = "" #Optional
-loginradius.authentication.login_by_user_name(user_name_authentication_model, email_template, fields, login_url, verification_url)
+result = loginradius.authentication.login_by_user_name(user_name_authentication_model, email_template, fields, login_url, verification_url)
```
@@ -426,7 +418,7 @@ email = "" #Required
reset_password_url = "" #Required
email_template = "" #Optional
-loginradius.authentication.forgot_password(email, reset_password_url, email_template)
+result = loginradius.authentication.forgot_password(email, reset_password_url, email_template)
```
@@ -453,31 +445,7 @@ options = "" #Optional
verification_url = "" #Optional
welcome_email_template = "" #Optional
-loginradius.authentication.user_registration_by_email(auth_user_registration_model, sott, email_template, fields, options, verification_url, welcome_email_template)
- ```
-
-
-
-
- Phone User Registration by SMS (POST)
- This API registers the new users into your Cloud Storage and triggers the phone verification process. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/phone-authentication/phone-user-registration-by-sms)
-
- ```
-
-auth_user_registration_model = {
-"firstName" : "",
-"lastName" : "",
-"password" : "",
-"phoneId" : ""
-} #Required
-sott = "" #Required
-fields = "" #Optional
-options = "" #Optional
-sms_template = "" #Optional
-verification_url = "" #Optional
-welcome_email_template = "" #Optional
-
-loginradius.authentication.user_registration_by_phone(auth_user_registration_model, sott, fields, options, sms_template, verification_url, welcome_email_template)
+result = loginradius.authentication.user_registration_by_email(auth_user_registration_model, sott, email_template, fields, options, verification_url, welcome_email_template)
```
@@ -505,7 +473,7 @@ sms_template = "" #Optional
verification_url = "" #Optional
welcome_email_template = "" #Optional
-loginradius.authentication.user_registration_by_captcha(auth_user_registration_model_with_captcha, email_template, fields, options, sms_template, verification_url, welcome_email_template)
+result = loginradius.authentication.user_registration_by_captcha(auth_user_registration_model_with_captcha, email_template, fields, options, sms_template, verification_url, welcome_email_template)
```
@@ -518,7 +486,7 @@ loginradius.authentication.user_registration_by_captcha(auth_user_registration_m
email = "" #Required
-loginradius.authentication.get_security_questions_by_email(email)
+result = loginradius.authentication.get_security_questions_by_email(email)
```
@@ -531,7 +499,7 @@ loginradius.authentication.get_security_questions_by_email(email)
user_name = "" #Required
-loginradius.authentication.get_security_questions_by_user_name(user_name)
+result = loginradius.authentication.get_security_questions_by_user_name(user_name)
```
@@ -544,7 +512,7 @@ loginradius.authentication.get_security_questions_by_user_name(user_name)
phone = "" #Required
-loginradius.authentication.get_security_questions_by_phone(phone)
+result = loginradius.authentication.get_security_questions_by_phone(phone)
```
@@ -557,7 +525,7 @@ loginradius.authentication.get_security_questions_by_phone(phone)
access_token = "" #Required
-loginradius.authentication.get_security_questions_by_access_token(access_token)
+result = loginradius.authentication.get_security_questions_by_access_token(access_token)
```
@@ -570,7 +538,7 @@ loginradius.authentication.get_security_questions_by_access_token(access_token)
access_token = "" #Required
-loginradius.authentication.auth_validate_access_token(access_token)
+result = loginradius.authentication.auth_validate_access_token(access_token)
```
@@ -582,9 +550,9 @@ loginradius.authentication.auth_validate_access_token(access_token)
```
access_token = "" #Required
-prevent_refresh = True #Optional
+prevent_refresh = "True" #Optional
-loginradius.authentication.auth_in_validate_access_token(access_token, prevent_refresh)
+result = loginradius.authentication.auth_in_validate_access_token(access_token, prevent_refresh)
```
@@ -597,7 +565,7 @@ loginradius.authentication.auth_in_validate_access_token(access_token, prevent_r
access_token = "" #Required
-loginradius.authentication.get_access_token_info(access_token)
+result = loginradius.authentication.get_access_token_info(access_token)
```
@@ -611,7 +579,7 @@ loginradius.authentication.get_access_token_info(access_token)
access_token = "" #Required
fields = "" #Optional
-loginradius.authentication.get_profile_by_access_token(access_token, fields)
+result = loginradius.authentication.get_profile_by_access_token(access_token, fields)
```
@@ -625,7 +593,7 @@ loginradius.authentication.get_profile_by_access_token(access_token, fields)
access_token = "" #Required
welcome_email_template = "" #Optional
-loginradius.authentication.send_welcome_email(access_token, welcome_email_template)
+result = loginradius.authentication.send_welcome_email(access_token, welcome_email_template)
```
@@ -638,7 +606,7 @@ loginradius.authentication.send_welcome_email(access_token, welcome_email_templa
deletetoken = "" #Required
-loginradius.authentication.delete_account_by_delete_token(deletetoken)
+result = loginradius.authentication.delete_account_by_delete_token(deletetoken)
```
@@ -651,7 +619,7 @@ loginradius.authentication.delete_account_by_delete_token(deletetoken)
email = "" #Required
-loginradius.authentication.check_email_availability(email)
+result = loginradius.authentication.check_email_availability(email)
```
@@ -667,7 +635,7 @@ fields = "" #Optional
url = "" #Optional
welcome_email_template = "" #Optional
-loginradius.authentication.verify_email(verification_token, fields, url, welcome_email_template)
+result = loginradius.authentication.verify_email(verification_token, fields, url, welcome_email_template)
```
@@ -681,7 +649,7 @@ loginradius.authentication.verify_email(verification_token, fields, url, welcome
access_token = "" #Required
fields = "" #Optional
-loginradius.authentication.get_social_identity(access_token, fields)
+result = loginradius.authentication.get_social_identity(access_token, fields)
```
@@ -694,7 +662,7 @@ loginradius.authentication.get_social_identity(access_token, fields)
username = "" #Required
-loginradius.authentication.check_user_name_availability(username)
+result = loginradius.authentication.check_user_name_availability(username)
```
@@ -708,7 +676,7 @@ loginradius.authentication.check_user_name_availability(username)
access_token = "" #Required
fields = "" #Optional
-loginradius.authentication.accept_privacy_policy(access_token, fields)
+result = loginradius.authentication.accept_privacy_policy(access_token, fields)
```
@@ -721,7 +689,7 @@ loginradius.authentication.accept_privacy_policy(access_token, fields)
access_token = "" #Required
-loginradius.authentication.get_privacy_policy_history_by_access_token(access_token)
+result = loginradius.authentication.get_privacy_policy_history_by_access_token(access_token)
```
@@ -736,7 +704,7 @@ access_token = "" #Required
delete_url = "" #Optional
email_template = "" #Optional
-loginradius.authentication.delete_account_with_email_confirmation(access_token, delete_url, email_template)
+result = loginradius.authentication.delete_account_with_email_confirmation(access_token, delete_url, email_template)
```
@@ -750,7 +718,7 @@ loginradius.authentication.delete_account_with_email_confirmation(access_token,
access_token = "" #Required
email = "" #Required
-loginradius.authentication.remove_email(access_token, email)
+result = loginradius.authentication.remove_email(access_token, email)
```
@@ -765,7 +733,7 @@ access_token = "" #Required
provider = "" #Required
provider_id = "" #Required
-loginradius.authentication.unlink_social_identities(access_token, provider, provider_id)
+result = loginradius.authentication.unlink_social_identities(access_token, provider, provider_id)
```
@@ -784,6 +752,7 @@ List of APIs in this Section:
* PUT : [Account Invalidate Verification Email](#InvalidateAccountEmailVerification-put-)
* PUT : [Reset phone ID verification](#ResetPhoneIDVerificationByUid-put-)
* PUT : [Upsert Email](#UpsertEmail-put-)
+* PUT : [Update UID](#AccountUpdateUid-put-)
* POST : [Account Create](#CreateAccount-post-)
* POST : [Forgot Password token](#GetForgotPasswordToken-post-)
* POST : [Email Verification token](#GetEmailVerificationToken-post-)
@@ -799,12 +768,13 @@ List of APIs in this Section:
* GET : [Account Identities by Email](#GetAccountIdentitiesByEmail-get-)
* DELETE : [Account Delete](#DeleteAccountByUid-delete-)
* DELETE : [Account Remove Email](#RemoveEmail-delete-)
+* DELETE : [Delete User Profiles By Email](#AccountDeleteByEmail-delete-)
Account Update (PUT)
- This API is used to update the information of existing accounts in your Cloud Storage. See our Advanced API Usage section Here for more capabilities. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/account/account-update)
+ This API is used to update the information of existing accounts in your Cloud Storage. See our Advanced API Usage section Here for more capabilities. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/account/account-update)
```
@@ -814,9 +784,9 @@ account_user_profile_update_model = {
} #Required
uid = "" #Required
fields = "" #Optional
-null_support = True #Optional
+null_support = "True" #Optional
-loginradius.account.update_account_by_uid(account_user_profile_update_model, uid, fields, null_support)
+result = loginradius.account.update_account_by_uid(account_user_profile_update_model, uid, fields, null_support)
```
@@ -831,7 +801,7 @@ phone = "" #Required
uid = "" #Required
fields = "" #Optional
-loginradius.account.update_phone_id_by_uid(phone, uid, fields)
+result = loginradius.account.update_phone_id_by_uid(phone, uid, fields)
```
@@ -845,7 +815,7 @@ loginradius.account.update_phone_id_by_uid(phone, uid, fields)
password = "" #Required
uid = "" #Required
-loginradius.account.set_account_password_by_uid(password, uid)
+result = loginradius.account.set_account_password_by_uid(password, uid)
```
@@ -860,7 +830,7 @@ uid = "" #Required
email_template = "" #Optional
verification_url = "" #Optional
-loginradius.account.invalidate_account_email_verification(uid, email_template, verification_url)
+result = loginradius.account.invalidate_account_email_verification(uid, email_template, verification_url)
```
@@ -874,7 +844,7 @@ loginradius.account.invalidate_account_email_verification(uid, email_template, v
uid = "" #Required
sms_template = "" #Optional
-loginradius.account.reset_phone_id_verification_by_uid(uid, sms_template)
+result = loginradius.account.reset_phone_id_verification_by_uid(uid, sms_template)
```
@@ -894,7 +864,23 @@ upsert_email_model = {
uid = "" #Required
fields = "" #Optional
-loginradius.account.upsert_email(upsert_email_model, uid, fields)
+result = loginradius.account.upsert_email(upsert_email_model, uid, fields)
+ ```
+
+
+
+
+ Update UID (PUT)
+ This API is used to update a user's Uid. It will update all profiles, custom objects and consent management logs associated with the Uid. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/account/account-update/)
+
+ ```
+
+update_uid_model = {
+"newUid" : ""
+} #Required
+uid = "" #Required
+
+result = loginradius.account.account_update_uid(update_uid_model, uid)
```
@@ -916,7 +902,7 @@ account_create_model = {
} #Required
fields = "" #Optional
-loginradius.account.create_account(account_create_model, fields)
+result = loginradius.account.create_account(account_create_model, fields)
```
@@ -930,9 +916,9 @@ loginradius.account.create_account(account_create_model, fields)
email = "" #Required
email_template = "" #Optional
reset_password_url = "" #Optional
-send_email = True #Optional
+send_email = "True" #Optional
-loginradius.account.get_forgot_password_token(email, email_template, reset_password_url, send_email)
+result = loginradius.account.get_forgot_password_token(email, email_template, reset_password_url, send_email)
```
@@ -945,7 +931,7 @@ loginradius.account.get_forgot_password_token(email, email_template, reset_passw
email = "" #Required
-loginradius.account.get_email_verification_token(email)
+result = loginradius.account.get_email_verification_token(email)
```
@@ -958,7 +944,7 @@ loginradius.account.get_email_verification_token(email)
uid = "" #Required
-loginradius.account.get_privacy_policy_history_by_uid(uid)
+result = loginradius.account.get_privacy_policy_history_by_uid(uid)
```
@@ -972,7 +958,7 @@ loginradius.account.get_privacy_policy_history_by_uid(uid)
email = "" #Required
fields = "" #Optional
-loginradius.account.get_account_profile_by_email(email, fields)
+result = loginradius.account.get_account_profile_by_email(email, fields)
```
@@ -986,7 +972,7 @@ loginradius.account.get_account_profile_by_email(email, fields)
user_name = "" #Required
fields = "" #Optional
-loginradius.account.get_account_profile_by_user_name(user_name, fields)
+result = loginradius.account.get_account_profile_by_user_name(user_name, fields)
```
@@ -1000,7 +986,7 @@ loginradius.account.get_account_profile_by_user_name(user_name, fields)
phone = "" #Required
fields = "" #Optional
-loginradius.account.get_account_profile_by_phone(phone, fields)
+result = loginradius.account.get_account_profile_by_phone(phone, fields)
```
@@ -1014,7 +1000,7 @@ loginradius.account.get_account_profile_by_phone(phone, fields)
uid = "" #Required
fields = "" #Optional
-loginradius.account.get_account_profile_by_uid(uid, fields)
+result = loginradius.account.get_account_profile_by_uid(uid, fields)
```
@@ -1027,7 +1013,7 @@ loginradius.account.get_account_profile_by_uid(uid, fields)
uid = "" #Required
-loginradius.account.get_account_password_hash_by_uid(uid)
+result = loginradius.account.get_account_password_hash_by_uid(uid)
```
@@ -1040,7 +1026,7 @@ loginradius.account.get_account_password_hash_by_uid(uid)
uid = "" #Required
-loginradius.account.get_access_token_by_uid(uid)
+result = loginradius.account.get_access_token_by_uid(uid)
```
@@ -1053,7 +1039,7 @@ loginradius.account.get_access_token_by_uid(uid)
refresh_token = "" #Required
-loginradius.account.refresh_access_token_by_refresh_token(refresh_token)
+result = loginradius.account.refresh_access_token_by_refresh_token(refresh_token)
```
@@ -1066,7 +1052,7 @@ loginradius.account.refresh_access_token_by_refresh_token(refresh_token)
refresh_token = "" #Required
-loginradius.account.revoke_refresh_token(refresh_token)
+result = loginradius.account.revoke_refresh_token(refresh_token)
```
@@ -1080,7 +1066,7 @@ loginradius.account.revoke_refresh_token(refresh_token)
email = "" #Required
fields = "" #Optional
-loginradius.account.get_account_identities_by_email(email, fields)
+result = loginradius.account.get_account_identities_by_email(email, fields)
```
@@ -1093,7 +1079,7 @@ loginradius.account.get_account_identities_by_email(email, fields)
uid = "" #Required
-loginradius.account.delete_account_by_uid(uid)
+result = loginradius.account.delete_account_by_uid(uid)
```
@@ -1108,7 +1094,20 @@ email = "" #Required
uid = "" #Required
fields = "" #Optional
-loginradius.account.remove_email(email, uid, fields)
+result = loginradius.account.remove_email(email, uid, fields)
+ ```
+
+
+
+
+ Delete User Profiles By Email (DELETE)
+ This API is used to delete all user profiles associated with an Email. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/account/account-email-delete/)
+
+ ```
+
+email = "" #Required
+
+result = loginradius.account.account_delete_by_email(email)
```
@@ -1116,7 +1115,7 @@ loginradius.account.remove_email(email, uid, fields)
-### Social API
+### Social API
List of APIs in this Section:
@@ -1132,18 +1131,24 @@ List of APIs in this Section:
* GET : [Get Active Session By Account Id](#GetActiveSessionByAccountID-get-)
* GET : [Get Active Session By Profile Id](#GetActiveSessionByProfileID-get-)
* GET : [Album](#GetAlbums-get-)
+* GET : [Get Albums with cursor](#GetAlbumsWithCursor-get-)
* GET : [Audio](#GetAudios-get-)
+* GET : [Get Audio With Cursor](#GetAudiosWithCursor-get-)
* GET : [Check In](#GetCheckIns-get-)
+* GET : [Get CheckIns With Cursor](#GetCheckInsWithCursor-get-)
* GET : [Contact](#GetContacts-get-)
* GET : [Event](#GetEvents-get-)
+* GET : [Get Events With Cursor](#GetEventsWithCursor-get-)
* GET : [Following](#GetFollowings-get-)
+* GET : [Get Followings With Cursor](#GetFollowingsWithCursor-get-)
* GET : [Group](#GetGroups-get-)
+* GET : [Get Groups With Cursor](#GetGroupsWithCursor-get-)
* GET : [Like](#GetLikes-get-)
+* GET : [Get Likes With Cursor](#GetLikesWithCursor-get-)
* GET : [Mention](#GetMentions-get-)
* GET : [Page](#GetPage-get-)
* GET : [Photo](#GetPhotos-get-)
* GET : [Get Post](#GetPosts-get-)
-* GET : [Get Status](#GetStatus-get-)
* GET : [Get Trackable Status Stats](#GetTrackableStatusStats-get-)
* GET : [Trackable Status Fetching](#TrackableStatusFetching-get-)
* GET : [User Profile](#GetSocialUserProfile-get-)
@@ -1154,7 +1159,7 @@ List of APIs in this Section:
Post Message API (POST)
- Post Message API is used to post messages to the user’s contacts.
Supported Providers: Twitter, LinkedIn
The Message API is used to post messages to the user’s contacts. This is one of the APIs that makes up the LoginRadius Friend Invite System. After using the Contact API, you can send messages to the retrieved contacts. This API requires setting permissions in your LoginRadius Dashboard.
GET & POST Message API work the same way except the API method is different [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/post-message-api)
+ Post Message API is used to post messages to the user's contacts.
Supported Providers: Twitter, LinkedIn
The Message API is used to post messages to the user?s contacts. This is one of the APIs that makes up the LoginRadius Friend Invite System. After using the Contact API, you can send messages to the retrieved contacts. This API requires setting permissions in your LoginRadius Dashboard.
GET & POST Message API work the same way except the API method is different [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/post-message-api)
```
@@ -1163,14 +1168,14 @@ message = "" #Required
subject = "" #Required
to = "" #Required
-loginradius.social.post_message(access_token, message, subject, to)
+result = loginradius.social.post_message(access_token, message, subject, to)
```
Status Posting (POST)
- The Status API is used to update the status on the user’s wall.
Supported Providers: Facebook, Twitter, LinkedIn [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/status-posting/)
+ The Status API is used to update the status on the user's wall.
Supported Providers: Facebook, Twitter, LinkedIn [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/status-posting/)
```
@@ -1183,14 +1188,14 @@ title = "" #Required
url = "" #Required
shorturl = "" #Optional
-loginradius.social.status_posting(access_token, caption, description, imageurl, status, title, url, shorturl)
+result = loginradius.social.status_posting(access_token, caption, description, imageurl, status, title, url, shorturl)
```
Trackable Status Posting (POST)
- The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user’s wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
POST Input Parameter Format: application/x-www-form-urlencoded [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/trackable-status-posting/)
+ The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user's wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications.
POST Input Parameter Format: application/x-www-form-urlencoded [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/trackable-status-posting/)
```
@@ -1204,7 +1209,7 @@ status_model = {
"url" : ""
} #Required
-loginradius.social.trackable_status_posting(access_token, status_model)
+result = loginradius.social.trackable_status_posting(access_token, status_model)
```
@@ -1217,7 +1222,7 @@ loginradius.social.trackable_status_posting(access_token, status_model)
token = "" #Required
-loginradius.social.exchange_access_token(token)
+result = loginradius.social.exchange_access_token(token)
```
@@ -1231,7 +1236,7 @@ loginradius.social.exchange_access_token(token)
access_token = "" #Required
expires_in = 0 #Optional
-loginradius.social.refresh_access_token(access_token, expires_in)
+result = loginradius.social.refresh_access_token(access_token, expires_in)
```
@@ -1244,7 +1249,7 @@ loginradius.social.refresh_access_token(access_token, expires_in)
access_token = "" #Required
-loginradius.social.validate_access_token(access_token)
+result = loginradius.social.validate_access_token(access_token)
```
@@ -1257,7 +1262,7 @@ loginradius.social.validate_access_token(access_token)
access_token = "" #Required
-loginradius.social.in_validate_access_token(access_token)
+result = loginradius.social.in_validate_access_token(access_token)
```
@@ -1270,7 +1275,7 @@ loginradius.social.in_validate_access_token(access_token)
token = "" #Required
-loginradius.social.get_active_session(token)
+result = loginradius.social.get_active_session(token)
```
@@ -1283,7 +1288,7 @@ loginradius.social.get_active_session(token)
account_id = "" #Required
-loginradius.social.get_active_session_by_account_id(account_id)
+result = loginradius.social.get_active_session_by_account_id(account_id)
```
@@ -1296,7 +1301,7 @@ loginradius.social.get_active_session_by_account_id(account_id)
profile_id = "" #Required
-loginradius.social.get_active_session_by_profile_id(profile_id)
+result = loginradius.social.get_active_session_by_profile_id(profile_id)
```
@@ -1309,173 +1314,258 @@ loginradius.social.get_active_session_by_profile_id(profile_id)
access_token = "" #Required
-loginradius.social.get_albums(access_token)
+result = loginradius.social.get_albums(access_token)
+ ```
+
+
+
+
+ Get Albums with cursor (GET)
+ Supported Providers: Facebook, Google, Live, Vkontakte.
This API returns the photo albums associated with the passed in access tokens Social Profile. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/album/)
+
+ ```
+
+access_token = "" #Required
+next_cursor = "" #Required
+
+result = loginradius.social.get_albums_with_cursor(access_token, next_cursor)
```
Audio (GET)
- The Audio API is used to get audio files data from the user’s social account.
Supported Providers: Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/audio)
+ The Audio API is used to get audio files data from the user's social account.
Supported Providers: Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/audio)
```
access_token = "" #Required
-loginradius.social.get_audios(access_token)
+result = loginradius.social.get_audios(access_token)
+ ```
+
+
+
+
+ Get Audio With Cursor (GET)
+ The Audio API is used to get audio files data from the user's social account.
Supported Providers: Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/audio)
+
+ ```
+
+access_token = "" #Required
+next_cursor = "" #Required
+
+result = loginradius.social.get_audios_with_cursor(access_token, next_cursor)
```
Check In (GET)
- The Check In API is used to get check Ins data from the user’s social account.
Supported Providers: Facebook, Foursquare, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/check-in)
+ The Check In API is used to get check Ins data from the user's social account.
Supported Providers: Facebook, Foursquare, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/check-in)
```
access_token = "" #Required
-loginradius.social.get_check_ins(access_token)
+result = loginradius.social.get_check_ins(access_token)
+ ```
+
+
+
+
+ Get CheckIns With Cursor (GET)
+ The Check In API is used to get check Ins data from the user's social account.
Supported Providers: Facebook, Foursquare, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/check-in)
+
+ ```
+
+access_token = "" #Required
+next_cursor = "" #Required
+
+result = loginradius.social.get_check_ins_with_cursor(access_token, next_cursor)
```
- The Contact API is used to get contacts/friends/connections data from the user’s social account.This is one of the APIs that makes up the LoginRadius Friend Invite System. The data will normalized into LoginRadius’ standard data format. This API requires setting permissions in your LoginRadius Dashboard.
Note: Facebook restricts access to the list of friends that is returned. When using the Contacts API with Facebook you will only receive friends that have accepted some permissions with your app.
Supported Providers: Facebook, Foursquare, Google, LinkedIn, Live, Twitter, Vkontakte, Yahoo [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/contact)
+ The Contact API is used to get contacts/friends/connections data from the user's social account.This is one of the APIs that makes up the LoginRadius Friend Invite System. The data will normalized into LoginRadius' standard data format. This API requires setting permissions in your LoginRadius Dashboard.
Note: Facebook restricts access to the list of friends that is returned. When using the Contacts API with Facebook you will only receive friends that have accepted some permissions with your app.
Supported Providers: Facebook, Foursquare, Google, LinkedIn, Live, Twitter, Vkontakte, Yahoo [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/contact)
```
access_token = "" #Required
next_cursor = "" #Optional
-loginradius.social.get_contacts(access_token, next_cursor)
+result = loginradius.social.get_contacts(access_token, next_cursor)
```
Event (GET)
- The Event API is used to get the event data from the user’s social account.
Supported Providers: Facebook, Live [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/event)
+ The Event API is used to get the event data from the user's social account.
Supported Providers: Facebook, Live [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/event)
```
access_token = "" #Required
-loginradius.social.get_events(access_token)
+result = loginradius.social.get_events(access_token)
+ ```
+
+
+
+
+ Get Events With Cursor (GET)
+ The Event API is used to get the event data from the user's social account.
Supported Providers: Facebook, Live [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/event)
+
+ ```
+
+access_token = "" #Required
+next_cursor = "" #Required
+
+result = loginradius.social.get_events_with_cursor(access_token, next_cursor)
```
Following (GET)
- Get the following user list from the user’s social account.
Supported Providers: Twitter [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/following)
+ Get the following user list from the user's social account.
Supported Providers: Twitter [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/following)
```
access_token = "" #Required
-loginradius.social.get_followings(access_token)
+result = loginradius.social.get_followings(access_token)
+ ```
+
+
+
+
+ Get Followings With Cursor (GET)
+ Get the following user list from the user's social account.
Supported Providers: Twitter [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/following)
+
+ ```
+
+access_token = "" #Required
+next_cursor = "" #Required
+
+result = loginradius.social.get_followings_with_cursor(access_token, next_cursor)
```
Group (GET)
- The Group API is used to get group data from the user’s social account.
Supported Providers: Facebook, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/group)
+ The Group API is used to get group data from the user's social account.
Supported Providers: Facebook, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/group)
```
access_token = "" #Required
-loginradius.social.get_groups(access_token)
+result = loginradius.social.get_groups(access_token)
```
- Like (GET)
- The Like API is used to get likes data from the user’s social account.
Supported Providers: Facebook [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/like)
+ Get Groups With Cursor (GET)
+ The Group API is used to get group data from the user's social account.
Supported Providers: Facebook, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/group)
```
-access_token = "" #Required
+access_token = "" #Required
+next_cursor = "" #Required
-loginradius.social.get_likes(access_token)
+result = loginradius.social.get_groups_with_cursor(access_token, next_cursor)
```
- Mention (GET)
- The Mention API is used to get mentions data from the user’s social account.
Supported Providers: Twitter [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/mention)
+ Like (GET)
+ The Like API is used to get likes data from the user's social account.
Supported Providers: Facebook [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/like)
```
access_token = "" #Required
-loginradius.social.get_mentions(access_token)
+result = loginradius.social.get_likes(access_token)
```
- Page (GET)
- The Page API is used to get the page data from the user’s social account.
Supported Providers: Facebook, LinkedIn [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/page)
+ Get Likes With Cursor (GET)
+ The Like API is used to get likes data from the user's social account.
Supported Providers: Facebook [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/like)
```
access_token = "" #Required
-page_name = "" #Required
+next_cursor = "" #Required
-loginradius.social.get_page(access_token, page_name)
+result = loginradius.social.get_likes_with_cursor(access_token, next_cursor)
```
- Photo (GET)
- The Photo API is used to get photo data from the user’s social account.
Supported Providers: Facebook, Foursquare, Google, Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/photo)
+ Mention (GET)
+ The Mention API is used to get mentions data from the user's social account.
Supported Providers: Twitter [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/mention)
+
+ ```
+
+access_token = "" #Required
+
+result = loginradius.social.get_mentions(access_token)
+ ```
+
+
+
+
+ Page (GET)
+ The Page API is used to get the page data from the user's social account.
Supported Providers: Facebook, LinkedIn [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/page)
```
access_token = "" #Required
-album_id = "" #Required
+page_name = "" #Required
-loginradius.social.get_photos(access_token, album_id)
+result = loginradius.social.get_page(access_token, page_name)
```
- Get Post (GET)
- The Post API is used to get post message data from the user’s social account.
Supported Providers: Facebook [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/post)
+ Photo (GET)
+ The Photo API is used to get photo data from the user's social account.
Supported Providers: Facebook, Foursquare, Google, Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/photo)
```
-access_token = "" #Required
+access_token = "" #Required
+album_id = "" #Required
-loginradius.social.get_posts(access_token)
+result = loginradius.social.get_photos(access_token, album_id)
```
- Get Status (GET)
- The Status API is used to get the status messages from the user’s social account. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/status-fetching)
+ Get Post (GET)
+ The Post API is used to get post message data from the user's social account.
Supported Providers: Facebook [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/post)
```
access_token = "" #Required
-loginradius.social.get_status(access_token)
+result = loginradius.social.get_posts(access_token)
```
Get Trackable Status Stats (GET)
- The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user’s wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/get-trackable-status-stats/)
+ The Trackable status API works very similar to the Status API but it returns a Post id that you can use to track the stats(shares, likes, comments) for a specific share/post/status update. This API requires setting permissions in your LoginRadius Dashboard.
The Trackable Status API is used to update the status on the user's wall and return an Post ID value. It is commonly referred to as Permission based sharing or Push notifications. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/get-trackable-status-stats/)
```
@@ -1487,7 +1577,7 @@ status = "" #Required
title = "" #Required
url = "" #Required
-loginradius.social.get_trackable_status_stats(access_token, caption, description, imageurl, status, title, url)
+result = loginradius.social.get_trackable_status_stats(access_token, caption, description, imageurl, status, title, url)
```
@@ -1500,49 +1590,49 @@ loginradius.social.get_trackable_status_stats(access_token, caption, description
post_id = "" #Required
-loginradius.social.trackable_status_fetching(post_id)
+result = loginradius.social.trackable_status_fetching(post_id)
```
User Profile (GET)
- The User Profile API is used to get social profile data from the user’s social account after authentication.
Supported Providers: All [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/user-profile)
+ The User Profile API is used to get social profile data from the user's social account after authentication.
Supported Providers: All [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/user-profile)
```
access_token = "" #Required
fields = "" #Optional
-loginradius.social.get_social_user_profile(access_token, fields)
+result = loginradius.social.get_social_user_profile(access_token, fields)
```
Refresh User Profile (GET)
- The User Profile API is used to get the latest updated social profile data from the user’s social account after authentication. The social profile will be retrieved via oAuth and OpenID protocols. The data is normalized into LoginRadius’ standard data format. This API should be called using the access token retrieved from the refresh access token API. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/refresh-token/refresh-user-profile)
+ The User Profile API is used to get the latest updated social profile data from the user's social account after authentication. The social profile will be retrieved via oAuth and OpenID protocols. The data is normalized into LoginRadius' standard data format. This API should be called using the access token retrieved from the refresh access token API. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/refresh-token/refresh-user-profile)
```
access_token = "" #Required
fields = "" #Optional
-loginradius.social.get_refreshed_social_user_profile(access_token, fields)
+result = loginradius.social.get_refreshed_social_user_profile(access_token, fields)
```
Video (GET)
- The Video API is used to get video files data from the user’s social account.
Supported Providers: Facebook, Google, Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/video)
+ The Video API is used to get video files data from the user's social account.
Supported Providers: Facebook, Google, Live, Vkontakte [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/social-login/advanced-social-api/video)
```
access_token = "" #Required
next_cursor = "" #Required
-loginradius.social.get_videos(access_token, next_cursor)
+result = loginradius.social.get_videos(access_token, next_cursor)
```
@@ -1550,7 +1640,7 @@ loginradius.social.get_videos(access_token, next_cursor)
-### Custom Object API
+### CustomObject API
List of APIs in this Section:
@@ -1580,7 +1670,7 @@ object_record_id = "" #Required
object = { "customdata1": "Store my customdata1 value"} #Required
update_type = "" #Optional
-loginradius.custom_object.update_custom_object_by_token(access_token, object_name, object_record_id, object, update_type)
+result = loginradius.custom_object.update_custom_object_by_token(access_token, object_name, object_record_id, object, update_type)
```
@@ -1597,7 +1687,7 @@ object = { "customdata1": "Store my customdata1 value"} #Required
uid = "" #Required
update_type = "" #Optional
-loginradius.custom_object.update_custom_object_by_uid(object_name, object_record_id, object, uid, update_type)
+result = loginradius.custom_object.update_custom_object_by_uid(object_name, object_record_id, object, uid, update_type)
```
@@ -1612,7 +1702,7 @@ access_token = "" #Required
object_name = "" #Required
object = { "customdata1": "Store my customdata1 value"} #Required
-loginradius.custom_object.create_custom_object_by_token(access_token, object_name, object)
+result = loginradius.custom_object.create_custom_object_by_token(access_token, object_name, object)
```
@@ -1627,7 +1717,7 @@ object_name = "" #Required
object = { "customdata1": "Store my customdata1 value"} #Required
uid = "" #Required
-loginradius.custom_object.create_custom_object_by_uid(object_name, object, uid)
+result = loginradius.custom_object.create_custom_object_by_uid(object_name, object, uid)
```
@@ -1641,7 +1731,7 @@ loginradius.custom_object.create_custom_object_by_uid(object_name, object, uid)
access_token = "" #Required
object_name = "" #Required
-loginradius.custom_object.get_custom_object_by_token(access_token, object_name)
+result = loginradius.custom_object.get_custom_object_by_token(access_token, object_name)
```
@@ -1656,7 +1746,7 @@ access_token = "" #Required
object_name = "" #Required
object_record_id = "" #Required
-loginradius.custom_object.get_custom_object_by_record_id_and_token(access_token, object_name, object_record_id)
+result = loginradius.custom_object.get_custom_object_by_record_id_and_token(access_token, object_name, object_record_id)
```
@@ -1670,7 +1760,7 @@ loginradius.custom_object.get_custom_object_by_record_id_and_token(access_token,
object_name = "" #Required
uid = "" #Required
-loginradius.custom_object.get_custom_object_by_uid(object_name, uid)
+result = loginradius.custom_object.get_custom_object_by_uid(object_name, uid)
```
@@ -1685,7 +1775,7 @@ object_name = "" #Required
object_record_id = "" #Required
uid = "" #Required
-loginradius.custom_object.get_custom_object_by_record_id(object_name, object_record_id, uid)
+result = loginradius.custom_object.get_custom_object_by_record_id(object_name, object_record_id, uid)
```
@@ -1700,7 +1790,7 @@ access_token = "" #Required
object_name = "" #Required
object_record_id = "" #Required
-loginradius.custom_object.delete_custom_object_by_token(access_token, object_name, object_record_id)
+result = loginradius.custom_object.delete_custom_object_by_token(access_token, object_name, object_record_id)
```
@@ -1715,7 +1805,7 @@ object_name = "" #Required
object_record_id = "" #Required
uid = "" #Required
-loginradius.custom_object.delete_custom_object_by_record_id(object_name, object_record_id, uid)
+result = loginradius.custom_object.delete_custom_object_by_record_id(object_name, object_record_id, uid)
```
@@ -1723,7 +1813,7 @@ loginradius.custom_object.delete_custom_object_by_record_id(object_name, object_
-### Phone Authentication API
+### PhoneAuthentication API
List of APIs in this Section:
@@ -1736,6 +1826,7 @@ List of APIs in this Section:
* POST : [Phone Forgot Password by OTP](#ForgotPasswordByPhoneOTP-post-)
* POST : [Phone Resend Verification OTP](#PhoneResendVerificationOTP-post-)
* POST : [Phone Resend Verification OTP By Token](#PhoneResendVerificationOTPByToken-post-)
+* POST : [Phone User Registration by SMS](#UserRegistrationByPhone-post-)
* GET : [Phone Number Availability](#CheckPhoneNumberAvailability-get-)
* DELETE : [Remove Phone ID by Access Token](#RemovePhoneIDByAccessToken-delete-)
@@ -1753,7 +1844,7 @@ reset_password_by_otp_model = {
"phone" : ""
} #Required
-loginradius.phone_authentication.reset_password_by_phone_otp(reset_password_by_otp_model)
+result = loginradius.phone_authentication.reset_password_by_phone_otp(reset_password_by_otp_model)
```
@@ -1769,7 +1860,7 @@ phone = "" #Required
fields = "" #Optional
sms_template = "" #Optional
-loginradius.phone_authentication.phone_verification_by_otp(otp, phone, fields, sms_template)
+result = loginradius.phone_authentication.phone_verification_by_otp(otp, phone, fields, sms_template)
```
@@ -1784,7 +1875,7 @@ access_token = "" #Required
otp = "" #Required
sms_template = "" #Optional
-loginradius.phone_authentication.phone_verification_otp_by_access_token(access_token, otp, sms_template)
+result = loginradius.phone_authentication.phone_verification_otp_by_access_token(access_token, otp, sms_template)
```
@@ -1799,7 +1890,7 @@ access_token = "" #Required
phone = "" #Required
sms_template = "" #Optional
-loginradius.phone_authentication.update_phone_number(access_token, phone, sms_template)
+result = loginradius.phone_authentication.update_phone_number(access_token, phone, sms_template)
```
@@ -1818,7 +1909,7 @@ fields = "" #Optional
login_url = "" #Optional
sms_template = "" #Optional
-loginradius.phone_authentication.login_by_phone(phone_authentication_model, fields, login_url, sms_template)
+result = loginradius.phone_authentication.login_by_phone(phone_authentication_model, fields, login_url, sms_template)
```
@@ -1832,7 +1923,7 @@ loginradius.phone_authentication.login_by_phone(phone_authentication_model, fiel
phone = "" #Required
sms_template = "" #Optional
-loginradius.phone_authentication.forgot_password_by_phone_otp(phone, sms_template)
+result = loginradius.phone_authentication.forgot_password_by_phone_otp(phone, sms_template)
```
@@ -1846,7 +1937,7 @@ loginradius.phone_authentication.forgot_password_by_phone_otp(phone, sms_templat
phone = "" #Required
sms_template = "" #Optional
-loginradius.phone_authentication.phone_resend_verification_otp(phone, sms_template)
+result = loginradius.phone_authentication.phone_resend_verification_otp(phone, sms_template)
```
@@ -1861,7 +1952,31 @@ access_token = "" #Required
phone = "" #Required
sms_template = "" #Optional
-loginradius.phone_authentication.phone_resend_verification_otp_by_token(access_token, phone, sms_template)
+result = loginradius.phone_authentication.phone_resend_verification_otp_by_token(access_token, phone, sms_template)
+ ```
+
+
+
+
+ Phone User Registration by SMS (POST)
+ This API registers the new users into your Cloud Storage and triggers the phone verification process. [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/phone-authentication/phone-user-registration-by-sms)
+
+ ```
+
+auth_user_registration_model = {
+"firstName" : "",
+"lastName" : "",
+"password" : "",
+"phoneId" : ""
+} #Required
+sott = "" #Required
+fields = "" #Optional
+options = "" #Optional
+sms_template = "" #Optional
+verification_url = "" #Optional
+welcome_email_template = "" #Optional
+
+result = loginradius.phone_authentication.user_registration_by_phone(auth_user_registration_model, sott, fields, options, sms_template, verification_url, welcome_email_template)
```
@@ -1874,7 +1989,7 @@ loginradius.phone_authentication.phone_resend_verification_otp_by_token(access_t
phone = "" #Required
-loginradius.phone_authentication.check_phone_number_availability(phone)
+result = loginradius.phone_authentication.check_phone_number_availability(phone)
```
@@ -1887,7 +2002,7 @@ loginradius.phone_authentication.check_phone_number_availability(phone)
access_token = "" #Required
-loginradius.phone_authentication.remove_phone_id_by_access_token(access_token)
+result = loginradius.phone_authentication.remove_phone_id_by_access_token(access_token)
```
@@ -1895,7 +2010,7 @@ loginradius.phone_authentication.remove_phone_id_by_access_token(access_token)
-### Multi Factor Authentication API
+### MultiFactorAuthentication API
List of APIs in this Section:
@@ -1907,10 +2022,6 @@ List of APIs in this Section:
* PUT : [MFA Validate Google Auth Code](#MFAValidateGoogleAuthCode-put-)
* PUT : [MFA Validate Backup code](#MFAValidateBackupCode-put-)
* PUT : [MFA Update Phone Number](#MFAUpdatePhoneNumber-put-)
-* PUT : [Validate MFA by OTP](#MFAReAuthenticateByOTP-put-)
-* PUT : [Validate MFA by Backup Code](#MFAReAuthenticateByBackupCode-put-)
-* PUT : [Validate MFA by Google Authenticator Code](#MFAReAuthenticateByGoogleAuth-put-)
-* PUT : [Validate MFA by Password](#MFAReAuthenticateByPassword-put-)
* POST : [MFA Email Login](#MFALoginByEmail-post-)
* POST : [MFA UserName Login](#MFALoginByUserName-post-)
* POST : [MFA Phone Login](#MFALoginByPhone-post-)
@@ -1918,7 +2029,6 @@ List of APIs in this Section:
* GET : [MFA Backup Code by Access Token](#MFABackupCodeByAccessToken-get-)
* GET : [Reset Backup Code by Access Token](#MFAResetBackupCodeByAccessToken-get-)
* GET : [MFA Resend Otp](#MFAResendOTP-get-)
-* GET : [Multi Factor Re-Authenticate](#MFAReAuthenticate-get-)
* GET : [MFA Backup Code by UID](#MFABackupCodeByUid-get-)
* GET : [MFA Reset Backup Code by UID](#MFAResetBackupCodeByUid-get-)
* DELETE : [MFA Reset Google Authenticator by Token](#MFAResetGoogleAuthByToken-delete-)
@@ -1940,7 +2050,7 @@ multi_factor_auth_model_with_lockout = {
} #Required
fields = "" #Optional
-loginradius.mfa.mfa_update_setting(access_token, multi_factor_auth_model_with_lockout, fields)
+result = loginradius.mfa.mfa_update_setting(access_token, multi_factor_auth_model_with_lockout, fields)
```
@@ -1958,7 +2068,7 @@ multi_factor_auth_model_by_google_authenticator_code = {
fields = "" #Optional
sms_template = "" #Optional
-loginradius.mfa.mfa_update_by_access_token(access_token, multi_factor_auth_model_by_google_authenticator_code, fields, sms_template)
+result = loginradius.mfa.mfa_update_by_access_token(access_token, multi_factor_auth_model_by_google_authenticator_code, fields, sms_template)
```
@@ -1973,7 +2083,7 @@ access_token = "" #Required
phone_no2_f_a = "" #Required
sms_template2_f_a = "" #Optional
-loginradius.mfa.mfa_update_phone_number_by_token(access_token, phone_no2_f_a, sms_template2_f_a)
+result = loginradius.mfa.mfa_update_phone_number_by_token(access_token, phone_no2_f_a, sms_template2_f_a)
```
@@ -1991,7 +2101,7 @@ second_factor_authentication_token = "" #Req
fields = "" #Optional
sms_template2_f_a = "" #Optional
-loginradius.mfa.mfa_validate_otp_by_phone(multi_factor_auth_model_with_lockout, second_factor_authentication_token, fields, sms_template2_f_a)
+result = loginradius.mfa.mfa_validate_otp_by_phone(multi_factor_auth_model_with_lockout, second_factor_authentication_token, fields, sms_template2_f_a)
```
@@ -2007,7 +2117,7 @@ second_factor_authentication_token = "" #Req
fields = "" #Optional
sms_template2_f_a = "" #Optional
-loginradius.mfa.mfa_validate_google_auth_code(google_authenticator_code, second_factor_authentication_token, fields, sms_template2_f_a)
+result = loginradius.mfa.mfa_validate_google_auth_code(google_authenticator_code, second_factor_authentication_token, fields, sms_template2_f_a)
```
@@ -2024,7 +2134,7 @@ multi_factor_auth_model_by_backup_code = {
second_factor_authentication_token = "" #Required
fields = "" #Optional
-loginradius.mfa.mfa_validate_backup_code(multi_factor_auth_model_by_backup_code, second_factor_authentication_token, fields)
+result = loginradius.mfa.mfa_validate_backup_code(multi_factor_auth_model_by_backup_code, second_factor_authentication_token, fields)
```
@@ -2039,72 +2149,7 @@ phone_no2_f_a = "" #Required
second_factor_authentication_token = "" #Required
sms_template2_f_a = "" #Optional
-loginradius.mfa.mfa_update_phone_number(phone_no2_f_a, second_factor_authentication_token, sms_template2_f_a)
- ```
-
-
-
-
- Validate MFA by OTP (PUT)
- This API is used to re-authenticate via Multi-factor authentication by passing the One Time Password received via SMS [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/multi-factor-authentication/re-authentication/re-auth-by-otp)
-
- ```
-
-access_token = "" #Required
-reauth_by_otp_model = {
-"otp" : ""
-} #Required
-
-loginradius.mfa.mfa_re_authenticate_by_otp(access_token, reauth_by_otp_model)
- ```
-
-
-
-
- Validate MFA by Backup Code (PUT)
- This API is used to re-authenticate by set of backup codes via access_token on the site that has Multi-factor authentication enabled in re-authentication for the user that does not have the device [More Info](https://www.loginradius.com/docs/api/v2/customer-identity-api/multi-factor-authentication/re-authentication/re-auth-by-backup-code)
-
- ```
-
-access_token = "" #Required
-reauth_by_backup_code_model = {
-"backupCode" : "