Pre-generate a user with embedded accounts.
Changed onPre-generate a user with one or more embedded accounts before they authenticate. Creates a user record and an embedded account per entry in accounts, each with its own SSS key shares. When the user later authenticates (via email, OAuth, third-party auth, etc.) with the same identifier, they will be linked to these pre-generated accounts.
Use the accounts array to pregenerate accounts on different chain types (e.g. one EVM account and one SVM account) in a single call.
You can pregenerate using either:
- email: User will be linked when they authenticate with the same email
- thirdPartyUserId + thirdPartyProvider: User will be linked when they authenticate via the same third-party provider
Request
- Base URL: https://api.openfort.io
- URL: https://api.openfort.io/v2/users/pregenerate
- Auth: HTTP bearer
Request body
Example request
{
"email": "user@example.com",
"thirdPartyUserId": "firebase_uid_abc123",
"accounts": [
{
"accountType": "Externally Owned Account",
"chainType": "EVM",
"chainId": 137,
"implementationType": "Calibur"
}
]
}Response
User and accounts pre-generated successfully.
Example response
{
"accounts": [
{
"custody": "Developer"
}
]
}Changes
- info
added the required property
//to the response with the status
- info
- breaking
added the new required request property
- breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - breaking
removed the required property
from the response with the status - warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - info
the security scope
users:writewas added to the endpoint's security schemesk - info
added the required property
to the response with the status
- breaking