I'm in big trouble that I have no idea what it can be.
I send PUSH notifications some APPS, functional normally but a specific APP that has many users is giving the following error.
The call in GCM is as follows:
$url = 'https://android.googleapis.com/gcm/send';
$fields = array(
'data' => array(
"mensagem" => $message
),
'registration_ids' => $registatoin_ids
);
if (is_array($data)) {
foreach ($data as $key => $value) {
$fields['data'][$key] = $value;
}
}
$headers = array(
'Authorization: key=' . apiKey,
'Content-Type: application/json'
);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($fields));
$result = curl_exec($ch);
if ($result === FALSE) {
die('Curl failed: ' . curl_error($ch));
}
curl_close($ch);
404 Not Found Nginx / 1.12.0