Register Device
POST /api/v1/notifications/register-device
POST
/api/v1/notifications/register-device
Register a device token for push notifications.
Requires authentication. The tenant_id and user_id are extracted from the JWT token. Performs an upsert: if the token already exists, updates last_refreshed_at.
Args: body: The registration request with token and platform. user: The authenticated user context.
Returns: Confirmation that the token was registered.
Authorizations
Request Body required
Request body for device token registration.
Attributes: token: The FCM device token string. platform: Device platform (web, android, ios).
object
platform
required
Device platform
string
token
required
FCM device token
string
Responses
200
Successful Response
Response body for device token registration.
Attributes: registered: Whether the token was successfully registered.
object
registered
required
boolean
422
Validation Error
object
detail
Array<object>
object
ctx
object
input
loc
required
Array
msg
required
string
type
required
string