Meteor-Community-Packages / raix-push

DEPRECATED: Push notifications for cordova (ios, android) browser (Chrome, Safari, Firefox)
https://atmospherejs.com/raix/push
MIT License
514 stars 197 forks source link

Android "_raix_push_notifications/insert" not found on push.send() #306

Open shashanksmf opened 7 years ago

shashanksmf commented 7 years ago

I am using Meter 1.4.2.1 Trying for Android on device I have added the following three packages $ meteor add raix:push $ meteor add cordova:cordova-plugin-device@1.1.5 $ meteor add cordova:phonegap-plugin-push@1.5.2 Client firing

Push.send({
        from: 'push',
        title: 'Hello',
        text: 'world',
        query: {} 
    });

After running push.send() from the client i get the following error in the console insert failed: Method '/_raix_push_notifications/insert' not found

My client


componentDidMount() {

Push.addListener('token', function(token) {
console.log('Token: ' + JSON.stringify(token));
});

Push.addListener('notification', function(notification) {
console.log('notification: ' + JSON.stringify(notification))
});

Push.addListener('startup', function(notification) {
console.log('Routing Push: ' + JSON.stringify(notification));
//Router.go('warbleShow', {_id: notification.payload.warbleId});
});

  Push.Configure({
  android: {
    senderID:  "12 digit number",
    alert: true,
    badge: true,
    sound: true,
    vibrate: true,
    clearNotifications: true
  }
});

    Push.debug = true;
    Push.id(); // Unified application id 
 }

And my server has


Meteor.startup(function () {

Push.Configure({
  "gcm": {
    "apiKey": " FCM prject credentials server key 152 length",
    "projectNumber": 12 digit length key
  }
});
Push.allow({
  send: (userId, notification) => {
    // allow all users to send notifications
    return true;
  }
});
Meteor.methods({
  'serverNotification'(title, text) {
    Push.send({
      title:"title",
      text:"text",
      from: 'server',
      badge: 1,
      query: {}
    });
  }
});
});

I can see in the console the token is successfully generated but my push.send() throws and error insert failed: Method '/_raix_push_notifications/insert' not found

Please hellpppp...!!!!

raix commented 6 years ago

please try upgrading the push package