title: FCM message not delivered to device when sent from php
body: <p>I am trying to implement FCM in my app. Right now, I am able to receive messages when i send them from firebase app console. But when i try to send messages from my php code on the server, the message does not get delivered to the phone. However, I get the message_id with numbers whenever the call to FCM is completed and no indication of any errors. Any help would be appreciated.</p>
  
  <p>PHP code:</p>
  
  <pre><code>public function send_fcm() {
      $API_ACCESS_KEY = '*****************************';
      $msg = array ('message'   =&gt; 'here is a message. message',
                      'title'     =&gt; 'This is a title. title',
                      'subtitle'  =&gt; 'This is a subtitle. subtitle',
                      'tickerText'    =&gt; 'Ticker text here...',
                      'vibrate'   =&gt; 1,
                      'sound'     =&gt; 1
                      );
  
      $fields = array('to' =&gt; '/topics/mytopic', 
                      'priority' =&gt; 'high', 
                      'data' =&gt; $msg);
      $headers = array('Authorization: key=' . $API_ACCESS_KEY,
                          'Content-Type: application/json');
  
      $ch = curl_init();
      curl_setopt($ch, CURLOPT_URL, 'https://fcm.googleapis.com/fcm/send');
      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));
      $pushResult = curl_exec($ch);
      curl_close($ch);
  
  }
  </code></pre>