Create an account and start a session.
POST
/api/auth/register
const url = 'https://api.tradr.cloud/api/auth/register';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"email":"hello@example.com","password":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.tradr.cloud/api/auth/register \ --header 'Content-Type: application/json' \ --data '{ "email": "hello@example.com", "password": "example" }'Public. Creates a user and sets the session cookie, so a successful register leaves the caller signed in. Rate limited to 5 requests per 15 minutes per client, tightening to 3 while the shared rate-limit store is unavailable. emailVerified is false until the address is confirmed; when transactional email is not configured there is nothing to confirm and the flag stays false without blocking use.
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
email
required
string format: email
password
required
string
Examplegenerated
{ "email": "hello@example.com", "password": "example"}Responses
Section titled “Responses”The new user. The session cookie is set.
Media typeapplication/json
object
user
object
email
string format: email
emailVerified
boolean
id
string format: uuid
isAdmin
boolean
Examplegenerated
{ "user": { "email": "hello@example.com", "emailVerified": true, "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "isAdmin": true }}Validation error.
That email is already registered.
Rate limit exceeded.