Comments (4)
I don't have any ideas about the 200 response. It should be 410 according to APNS documentation. Maybe try with another device or try to wait for a few minutes after uninstalling the App.
from pushok.
Still, its getting 200 response even after waited for a day. I will continue to use the legacy feedback service for invalidating the uninstalled App token.
from pushok.
any update on this issue? @basiljohntme how did you connected to feedback server with .p8 file?
from pushok.
@fattalgazi For connecting to the feedback service, I am not using this library. I am using below legacy way,
// Create stream context.
$stream_context = stream_context_create();
// Set the certificate to be used.
stream_context_set_option($stream_context, 'ssl', 'local_cert', 'phn_application/cert/' . $this->apple_cert_to_use);
stream_context_set_option($stream_context, 'ssl', 'passphrase', $this->apple_push_phrase);
$apns = stream_socket_client($this->apple_feedback_url, $errr_code, $err_message, 60, STREAM_CLIENT_CONNECT, $stream_context);
if (!$apns)
{
log_message("error", "APN failed to connect to apple feedback service " . $error_message);
}
else
{
echo "Connected to Apple feedback service, reading data...\n";
$feedback_tokens = array();
// And read the data on the connection:
while(!feof($apns))
{
$data = fread($apns, 38);
if (strlen($data))
{
$feedback_tokens[] = unpack("N1timestamp/n1length/H*devtoken", $data);
}
}
// Close the connection to the feedback server.
fclose($apns);
echo "Closed feedback connection\n";
// So if have some tokens then we need to get the info in to a format which is useful to send back to loyalty.
if ($feedback_tokens)
{
echo "-Invalidate\n";
}
else
{
echo "- No devices have unregistered\n";
}
}
from pushok.
Related Issues (20)
- Target [Pushok\AuthProviderInterface] is not instantiable while building [Pushok\Client]
- BadDeviceTokenThe specified device token was bad. Verify that the request contains a valid token and that the token matches the environment HOT 3
- Support PHP 8
- Uncaught Exception HOT 3
- Package spomky-labs/jose is abandoned, you should avoid using it. Use web-token/jwt-framework instead. HOT 1
- Deprecation notices with PHP 8.1 HOT 4
- Question: Push Notifications for PkPass Updates HOT 8
- send a notification on a chosen date HOT 1
- Updating a badge HOT 1
- Support for creating WeatherKit JWT tokens
- The `Alert` option is set in the code but there is no Alert on the phone
- Package fgrosse/phpasn1 is abandoned HOT 2
- Started getting InvalidArgumentException "Unable to load the key." HOT 4
- Live Activities Supported? HOT 3
- Laravel Vapor - HTTP/2 stream 15 was not closed cleanly before end of the underlying stream HOT 3
- 0.15.x is no longer compatible with PHP 8.0 HOT 4
- HTTP/2 stream was not closed cleanly: REFUSED STREAM HOT 9
- Sending `Alert` as `Background` due to `content-available` set HOT 1
- php 8.0 via command package not installed
- Random "Send failure: Broken pipe" error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pushok.