Login | Sign Up
  • FA
  • EN

API Docs

POST /api/v1/users/fcm/register-token

Register an FCM token for the authenticated user to receive push notifications.


Authentication

This endpoint requires authentication via Sanctum token.


Request Body Parameters

NameTypeRequiredDescription
tokenstringYesFCM registration token
device_typestringNoDevice type (ios, android, web)
device_idstringNoUnique device identifier

Response

200 OK

{
  "message": "FCM token registered successfully"
}

Error Responses

StatusDescriptionReference
422Validation errorValidation error
401UnauthorizedAuthentication error

Notes

  • If the token already exists for the user, it will be updated with the new device information
  • Multiple devices per user are supported
  • Tokens are used for sending push notifications via Firebase Cloud Messaging
footer wave
logo

Dambel, the smart world of fitness and nutrition

LinkedinInstagramXYoutubeTelegramGitHub