gray-beach-42495
10/13/2024, 1:00 PM{customerId:number, username: string}
, email and password. And treat user_info as unique identifier
• Google SSO
However I'm facing an issue where if a user has an email already registered with oidc(google) it gives this error`{\"error\":{\"code\":409,\"status\":\"Conflict\",\"request\":\"29b67d3e-a694-9095-ae6c-5941fe981825\",\"reason\":\"This identity conflicts with another identity that already exists.\",\"message\":\"The resource could not be created due to a conflict\"}}`
when i try creating a user with password and user_info.
In short, is there a way to treat user_info as unique identifier and not the email (which seems to be the case right now)
Identity schema:
{
"$id": "test-identity",
"title": "Person",
"type": "object",
"properties": {
"traits": {
"type": "object",
"properties": {
"user_info": {
"type": "object",
"title": "User Information",
"properties": {
"username": {
"type": "string",
"title": "Username",
"maxLength": 100
},
"customer_id": {
"type": "number",
"title": "Customer Id"
}
},
"ory.sh/kratos": {
"credentials": {
"password": {
"identifier": true
},
"webauthn": {
"identifier": true
},
"totp": {
"account_name": true
}
}
}
},
"email": {
"type": "string",
"format": "email",
"title": "E-Mail",
"ory.sh/kratos": {
"recovery": {
"via": "email"
},
"verification": {
"via": "email"
}
},
"maxLength": 320
}
},
"required": [
"user_info",
"email"
],
"additionalProperties": false
}
},
"$schema": "<http://json-schema.org/draft-07/schema#>"
}