Social Signup #
How to signup a user using Social Login #
This function allows a client application to authenticate and create an account with AppKey using a social account, either Apple or Google. The user can log in via a passkey or a social account. Social signup is supported because major providers are adopting passkeys as their authentication strategy. Additionally, it simplifies access by letting users delegate authentication to a social provider rather than creating a separate account.
URL #
/api/appuser/socialSignup
Method #
POST
Headers #
app-token: "<App Token>"
Data Parameter #
{
token: <apple or google token>
provider: <'apple' or 'google'>
handle: <user handle>,
displayName: <user display name>,
locale: <"locale for user">
}
Response: #
Success: #
StatusCode: #
200 (OK)
Contents: #
{
appId: <uuid>,
appUserId: <uuid>,
handle: <user handle>,
displayName: <display name>,
status: <'active', 'suspended'>,
loginProvider: <'apple', 'google'>,
jwt: <jwt token>,
access-token: <access token>
}
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