0

I'm debugging firebase notifications with my colleagues and I want to try a new approach knowing that all previous subscriptions have been removed.

We subscribe by POSTing to https://iid.googleapis.com/iid/v1/<token>/rel/topics/<topic>

Is there a UI I can use to remove all existing subscriptions so that I know I am testing the new code?

If not, is there some other to remove a bunch of subscriptions the details of which I do not have?

Simon H
  • 20,332
  • 14
  • 71
  • 128

1 Answers1

1

There is no UI built into the Firebase console to remove the mappings from topics to tokens. The API you found is the only way to do so.

I typically write a small (Node.js) script to loop over the tokens/topic in my database and remove them.

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
  • ah, can you explain where the database is that has that info? – Simon H Jul 30 '20 at 14:11
  • 1
    That's in your own database. There is no API to get all tokens for a topic built into FCM. See https://stackoverflow.com/questions/54533735/how-to-get-client-fcm-tokens-from-a-fcm-topic – Frank van Puffelen Jul 30 '20 at 14:24