-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how can I unsubscribeFromTopic #30
Comments
By having the token you would like to unsubscribe from the topic you could do this: use sngrl\PhpFirebaseCloudMessaging\Client;
$server_key = '_YOUR_SERVER_KEY_';
$client = new Client();
$client->setApiKey($server_key);
$client->injectGuzzleHttpClient(new \GuzzleHttp\Client());
$response = $client->removeTopicSubscription('_YOUR_TOPIC_ID_', ['_YOUR_TOKEN_']); |
I try this give me error INVALID_ARGUMENT , |
Can you post here a sample of the code you use? |
I used the code on yr documentation here use sngrl\PhpFirebaseCloudMessaging\Client; $server_key = 'YOUR_SERVER_KEY'; and when I sent push notification from firebase console to this unwanted_token , I get the notification , and When I send push to TopicName , I get push notification , so I don't know what's error on the package |
Does this happen with a single Token or also with other tokens on that Topic? |
I tried it with single token ,what's the difference |
I'm trying to understand if this issue is with that particular token or with all tokens Firebase generates. |
I tried the token on firebase console , it works , so I don't know what the wrong with it , I will try again and feedback |
No description provided.
The text was updated successfully, but these errors were encountered: