Later edit :
The native NEAR token isn't an NEP-141 or NEP-21 token. The transfer of NEAR tokens is a base layer functionality of the NEAR Protocol and isn't tied to the NEP-141 or NEP-21 standards. Therefore, a transfer of NEAR tokens doesn't trigger an ft_transfer event from NEP-141.
If you want to listen for transfers of the native NEAR token, you may need to use a different method, such as querying the NEAR blockchain directly, or finding a service that provides events for NEAR token transfers.
Just tested this using this code :
const WebSocket = require('ws');
const ws = new WebSocket('wss://events.near.stream/ws');
ws.on('open', function open() {
ws.send(
JSON.stringify({
secret: 'secret',
filter: [
{
event: {
standard: 'nep141',
event: 'ft_transfer',
},
},
],
}),
);
});
ws.on('message', function incoming(data) {
console.log('Received: %s', data);
});
ws.on('error', function error(err) {
console.error('WebSocket encountered an error: ', err);
});
It's working. I am getting events.