Updated server side code to accept gcm keys