Signup #
How to signup a user #
This function initiates the process of verifying a user’s handle through the AppKey service. A six-digit verification code is sent to the handle associated with the user account for verification.
If the app signup flow is set to open, any user can sign up. If the flow is set to invite, only users with a handle that matches an existing invite can proceed with the signup.
An optional locale parameter can be passed to specify the user’s locale during the signup process. The signup involves three REST calls:
- signup
- confirmSignup
- signupComplete
The signup function sends a six-digit code to the user’s handle for ownership verification. The confirmSignup function verifies this code with the AppKey server. Finally, the signupComplete function matches the user’s biometric data and creates a passkey for the application.
URL #
/api/appuser/signup
Method #
POST
Headers #
app-token: "<App Token>"
Data Parameter #
{
handle: <user handle>,
displayName: <user display name>,
locale: <"locale for user">
}
Response: #
Success: #
StatusCode: #
200 (OK)
Contents: #
{
challenge: "<FIDO2 challenge>",
user: {
id: "<user id>",
name: "<handle>(<app id>)",
displayName: "<user display name>",
handle: "<user handle>”
}
}
Error: #
StatusCode: #
400 (BAD REQUEST)
500 (INTERNAL SERVER ERROR)
Content: #
{
code: "<internal error code>",
message: "<readable error description>"
}
The internal codes are integers:
- 400 - invalid app token
- 401 - app no longer exists
- 402 - app is suspended
- 403 - missing parameter
- 404 - user account is suspended
- 407 - app does not support signup
- 413 - app is migrated
- 500 - internal server error
- 601 - handle already registered
- 609 - invalid locale