/api/fcm/token/list
[GET]
Response:
{
"clientTokens": [
{
"uuid": "<string>",
"token": "<string>"
}
]
}
/api/fcm/token/save
[POST]
Body:
{
"token": "required string",
"uuid": "<empty for new | required for subscribed user>"
}
For the first time of token saving, you can ignore uuid
, server will generate and return uuid
and token
as response.
uuid
must be set for next saving token after uuid was generated
Response for new token
{
"message": "token is saved",
"data": {
"uuid": "",
"token": ""
}
}
Response for subscribed token
{
"message": "token is updated",
"data": {
"uuid": "",
"token": ""
}
}
/api/fcm/token/delete/{uuid}
[DELETE]
Param: uuid
/api/fcm/topic/subscribe
[POST]
Body:
{
"topic": "",
"uuid": ""
}
/api/fcm/topic/unsubscribe
[DELETE]
Body:
{
"topic": "",
"uuid": ""
}
/api/fcm/send/message
[POST]
Body:
{
"type":"data | default",
"uuid": "",
"title": "" ,
"body": ""
}
type
's value accepts two string ['data', 'default']
See: 'message types'
/api/fcm/send/message/topic
[POST]
Body:
{
"type": "",
"topic": "",
"title": "",
"body": ""
}