cloudApi.event() and use the event’s stable resource ID in your callback:
Subscription and close it when your plugin stops. The event handling guide shows the complete plugin lifecycle and how to safely interact with your server platform from a callback.
Choose an event category
Server events describe individual server instances. Persistent server events describe changes to the persistent server itself, such as it being updated or starting a server instance.
Keep state accurate
Events notify you that something changed; query APIs provide the current state. Subscriptions only receive live events, so query the resource when your plugin starts or when missing an event would make its state incorrect. Close each subscription when you no longer need it. Bothclose() and unsubscribe() stop future delivery and can be called more than once.
Read callback data
Every callback providesgetNetworkId() and an ISO 8601 timestamp through getTimestamp(). The remaining getters depend on the event type.
Prefer the stable ID getter when identifying a resource. Query the matching resource API when you need its current data; model getters such as getServer(), getGroup(), and getBlueprint() can be unavailable for an event.
Server callback getters
Server callback getters
Group callback getters
Group callback getters
Persistent server callback getters
Persistent server callback getters
Blueprint callback getters
Blueprint callback getters