Services for Account management
Description | URI | Request Method | Request Params | Request Body | Response Body | Error Conditions | Authority |
---|---|---|---|---|---|---|---|
Request email validation for new user. No information is saved server-side, but a URL is sent to the specified email address in which the request information is embedded. The URL is a link in the Synapse Portal where user registration is completed. | /emailValidation | POST | domain (Synapse or Bridge) | fname lname | 400 Status if email is invalid or already used. | Anonymous (unauthenticated request) | |
Request email validation for existing account. No information is saved server-side but a URL is sent to the specified email address in which the request information is embedded. The URL is a link in the Synapse Portal where adding the email is completed. | /emailValidation | POST | domain (Synapse or Bridge) | 400 Status if email is invalid or already used. | self (authenticated request) | ||
Create new account, completing email validation. The username and email given previously are bound to the account. A session token is returned, i.e. the user is logged in. The client must then set the account password. | /account | POST | -- | user-validation-token* username | session token | 400 Status if user name or email is invalid or already used, or if the time limit has passed. | Anonymous (unauthenticated request) |
Complete the email validation to add a new email address to an existing account. User making this request must match the one who initiated the email addition request (above). | POST | -- | email-validation-token** | self | |||
Remove an email address associated with an account. | DELETE | 400 if email is notification email | |||||
Choose which email associated with the account is the notification email. | /notificationEmail | PUT | 400 if email is not one of the emails |
*Account creation validation token contains the following, encrypted:
- first name
- last name
- domain
- time stamp
** Email validation token contains the following, encrypted:
- principalId
- domain
- time stamp
Client Usage
Create new account
Step 1: POST /emailValidation
Step 2: POST /account, including the token generated due to Step 1.
Step 3: POST /user/password to set the account password.
Add new email address
Step 1: POST /session to log in
Step 2: POST /emailValidation
Step 3: POST /email, including the token from Step 2.