title: Firebase Data messages not delivered to iOS when using new HTTP v1 API
body: <p>Firebase supports <em>Notification messages</em> and <em>Data messages</em>.</p>
  
  <p><em>Data messages</em> don't trigger visual notification and are handled by the client (iOS App) when the app is in foreground.
  Communication is then done using direct channel between Firebase and iOS App - without use of Apple Push Notification Service (APNS).</p>
  
  <p>Everything works fine when we use <a href="https://firebase.google.com/docs/cloud-messaging/http-server-ref" rel="noreferrer">Legacy FCM HTTP Protocol</a> but when using new <a href="https://firebase.google.com/docs/cloud-messaging/migrate-v1" rel="noreferrer">HTTP v1 API</a>, Data messages are not delivered to iOS client.</p>
  
  <p>Notification messages (even including data) are delivered fine using via APNS.</p>
  
  <p>We have tried interfacing to Firebase Cloud Messaging using:</p>
  
  <ul>
  <li>Admin FCM API (Java and Node.JS SDKs)</li>
  <li>Direct HTTP request to HTTP v1 API using OAuth2 tokens</li>
  </ul>
  
  <p>None of the above would result in Data message to be delivered to the iOS client. Such messages are only delivered when being sent using legacy HTTP Protocol.</p>
  
  <p>To make things more interesting Data messages send using HTTP v1 API (new) are successfully delivered to web JavaScript client, so it means that they are supported. They are also used in <a href="https://firebase.google.com/docs/cloud-messaging/admin/send-messages" rel="noreferrer">samples</a>. We haven't tried the Android client.</p>