Registration as a Service
Registration as a Service (RaaS) provides customer identity and account management features native to Synerise without any need for third party systems. To use RaaS, implement a set of methods listed below in your application.
Additionally, in the Synerise platform (app.synerise.com
) you can define the following settings:
- Registration mode
- Assignment of loyalty card
- JWT longevity
- Custom ID overwriting
- External ID overwriting
- Enabling email address change through a link in the email
- Templates of email notifications such as account confirmation, email change request, PIN confirmation, and so on.
- Password policy
Registration methods
Register new customers
This method lets you pass all customer information along with any agreements and attributes at once.
The primary unique identifier used by Synerise is the email address. However, you may also define a customId
as a unique identifier. You can read more here.
Depending on backend configuration at Synerise, the registration may or may not require email confirmations/ The following registration behaviors are supported:
Name | Description |
---|---|
Automatic | The account is ready to use right after registration, no confirmations are required. Customer has the attribute snrs_email_confirmed set to false . |
Email Confirmation Required | The account is ready to use right after registration, but the email confirmation is required. The confirmation sets snrs_email_confirmed to true . |
Email Activation Required | An activation email is sent and the account cannot be used until the address is confirmed. Activation also means that snrs_email_confirmed is set to true . |
PIN Activation Required | An activation email is sent and the account cannot be used until the PIN sent in the email is provided (Android, iOS, React Native). |
Request customer account by email
This method requests sending an email with a URL that confirms the registration and activates the account.
OS | Method |
---|---|
Android | Client.activateAccount(email) |
iOS | Client.activateAccount(email:success:failure:) |
React Native | Synerise.Client.activateAccount(email, onSuccess, onError) |
Flutter | Synerise.client.activateAccount(email) |
Confirm customer account
This method confirms a customer account with the confirmation token.
OS | Method |
---|---|
Android | Client.confirmAccount(token) |
iOS | Client.confirmAccount(token:success:failure:) |
React Native | Synerise.Client.confirmAccount(token, onSuccess, onError) |
Flutter | Synerise.client.confirmAccount(token) |
Request customer account by pin
This method requests sending an email to a customer with the PIN code needed during account registration process.
OS | Method |
---|---|
Android | Client.requestAccountActivationByPin(email) |
iOS | Client.requestAccountActivationByPin(email:success:failure:) |
React Native | Synerise.Client.requestAccountActivationByPin(email, onSuccess, onError) |
Flutter | n/a |
Confirm customer account activation by pin
This method requires a customer to enter a PIN code during account registration process sent through an email.
OS | Method |
---|---|
Android | Client.confirmAccountActivationByPin(pinCode, email) |
iOS | Client.confirmAccountActivationByPin(pinCode:success:failure:) |
React Native | Synerise.Client.confirmAccountActivationByPin(pinCode, onSuccess, onError) |
Flutter | n/a |
Authentication methods
Once a customer is registered, you can let users log in by implementing this method. After a successful log-in, the application receives a JWT token which is valid for 1 hour (default setting). The SDK refreshes that token while a customer is using the application and events are being sent (auto-refresh occurs only when the token is still valid).
Other methods
Check if a customer is signed in
This method checks if a customer is signed in through oAuth, Facebook, Sign in with Apple, or RaaS.
OS | Method |
---|---|
Android | Client.isSignedIn() |
iOS | Client.isSignedIn() |
React Native | Synerise.Client.isSignedIn() |
Flutter | Synerise.client.isSignedIn() |
Customer sign out
This method signs out the customer. The method terminates the JWT token and ends the customer session.
What’s next
When the customer’s account is registered and/or they are signed in, you can implement profile management methods and session management methods.