Set it up
1
Create a heartbeat monitor in Sentivel
Sign in to Sentivel (it’s free to start), open Monitors, click Add a monitor, and choose Heartbeat.
2
Set the timing, and choose Show it as idle
Keep the defaults of Every 5 minutes for Expected interval and 1 minute for Grace period, since Rayfield pings every five minutes. Under When pings stop, choose Show it as idle. See When nobody is playing for why.
3
Copy the ping URL
Sentivel gives the monitor a ping URL of the form
https://www.sentivel.com/api/heartbeat/<token>. Copy the whole URL. Rayfield needs this link, not the monitor’s ID.4
Add it to your window
Pass the URL as
Heartbeat in CreateWindow.When nobody is playing
Rayfield only pings while someone has your script open, so when nobody is playing, the pings stop just as they would if the script broke. Show it as idle tells Sentivel what that silence means: the monitor reads Idle rather than down, opens no incident, records no downtime, and goes back to operational as soon as someone opens the script again. On your status page the script shows as Idle. Choose Mark it down instead only if someone almost always has the script open and you want to be alerted the moment that stops.What to expect
- Pings last as long as Rayfield. You get one ping when the window opens, after the key system if you use one, then one every five minutes. They stop when you call
Rayfield:Destroy()or the script is run again. - Studio is skipped. Playtests aren’t real runs, so no ping is sent there. The link is still checked, so a typo shows up while you are building.
- A bad link warns. If the link isn’t a Sentivel ping URL, Rayfield prints a warning saying what to paste instead and sends nothing. The full URL and the bare token both work, and stray spaces from a paste are fine.
- An unknown heartbeat stops. If Sentivel keeps saying the heartbeat doesn’t exist, for example because you deleted the monitor or regenerated its URL, Rayfield prints a warning and stops pinging.
- Only Sentivel.
Heartbeatrefuses any other host, so it can’t be used to make other requests.
Secure mode silences Rayfield’s console output, including these warnings. Before you ship, run the script once without secure mode and check that the monitor’s page says First ping received.
Can someone fake my pings?
Can someone fake my pings?
The ping URL ships inside your script, so anyone who reads the script can use it. Treat the monitor as a signal that people are running your script, not as proof. If the URL is being misused, click Regenerate next to it on the monitor’s page and ship the new one.
Reference
string
A
CreateWindow setting. The monitor’s ping URL, or just its token. Optional.Sentivel monitors
Monitor types, thresholds, and maintenance.