
Security News
Socket Security Analysis Is Now One Click Away on npm
npm now links to Socket's security analysis on every package page. Here's what you'll find when you click through.
A Node.js module for sending heartbeats to OpsGenie.
When operating a Node.js app, you need to be notified of downtime. Services like Pingdom allow you to monitor the availability of your app by pinging it periodically and alerting you if it cannot be reached. But this requires your app to be available online.
If your app is running behind a firewall (intranet) or it's a background job not inteded to be publically available, Pingdom and similar services have no way of pinging it. The solution of cause is to reverse the roles and let your app ping the monitoring service. OpsGenie provide such an API.
npm install opsgenie
You can either configure OpsGenie using environment variables, or configure it using the .heartbeat() function.
OpsGenie environment variables:
OPSGENIE_API_KEY - Your personal OpsGenie API keyOPSGENIE_SOURCE - The hostname that the OpsGenie heartbeat agent should register as (optional)If no source is provided, either by OPSGENIE_SOURCE or by setting it via the .heartbeat() function, the hostname of the server will be used.
Example 1 - Using OpsGenie with environment variables:
require('opsgenie');
Example 2 - Configure OpsGenie using the .heartbeat() function:
require('opsgenie').heartbeat({
apiKey: 'eb243592-faa2-4ba2-a551q-1afdf565c889',
source: 'host-name'
});
The OpsGenie module can emit the following events:
var opsgenie = require('opsgenie');
opsgenie.on('error', function (err) {
console.log('Something went wrong while communicating with OpsGenie: ' + err.message);
});
opsgenie.on('heartbeat', function (res) {
console.log('OpsGenie heartbeat result:', res);
});
MIT
FAQs
A module for sending heartbeats to OpsGenie
We found that opsgenie demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
npm now links to Socket's security analysis on every package page. Here's what you'll find when you click through.

Security News
A compromised npm publish token was used to push a malicious postinstall script in cline@2.3.0, affecting the popular AI coding agent CLI with 90k weekly downloads.

Product
Socket is now scanning AI agent skills across multiple languages and ecosystems, detecting malicious behavior before developers install, starting with skills.sh's 60,000+ skills.