region_restart
Fires when the bot receives a region restart notification.
Bot.on("region_restart", function(event) { ... });Reference
This event comes with the following event object:
Variable | Description |
|---|---|
name | The name of the event — in this case |
message | The message of the region restart |
bot_uuid | The UUID of the bot which receives the notification |
region_name | The name of the region going to restart |
time_units | Unit of time in which the region is going to restart ( |
time_left | Amount of time until region restart based on |
seconds_left | Amount of time until region restart in seconds |
Comments
Not available for self-hosted QubicBot app yet.
time_leftcontains the time until restart intime_units.time_unitsareSecondsorMinutes—Unknownis sent if any other unit is received.seconds_leftis always the time until restart in seconds.
Example
console.log(`${process.name} started`);
Bot.on("region_restart", (event) => {
console.log(`Region restart event:`, event);
});