We are trying to add our GCM API key to the azure notification hub and we are receiving the following error:
SubCode=40000. Failed to validate credentials with GCM. Error is The remote server returned an error: (401) Unauthorized...TrackingId:410c0e33-0c38-1823-8a62-2519627c76a2_M1_G19,TimeStamp:9/19/2014 10:08:32 AM
We have setup our GCM API key to allow any IP address and we have also tried registering from code like below but with the same error:
NamespaceManager mgr = NamespaceManager.CreateFromConnectionString(conn);
var hub = mgr.GetNotificationHub("<hubname>");
hub.GcmCredential = new GcmCredential("<apikey>");
mgr.UpdateNotificationHub(hub);
Are we missing something quite obvious here?