Skip to main content

Public API

Other plugins reach DistrictWarden through its API provider:

DistrictWardenAPI api = DistrictWardenAPIProvider.get();

The entry point exposes two groups: properties() and shops().

Working methods​

MethodNotes
properties().getPropertyStatus(id)Reads the stored status of a property
properties().getPropertyAt(location)Asks the land provider; empty if none is installed
properties().reconcileProperty(id)Re-reads one property and updates the store
shops().getShops(propertyId)Reads the stored shops for a property

reconcileProperty​

reconcileProperty runs on the calling thread and returns an already-completed future. Land-provider APIs are only safe to touch on the server main thread, so call it from there.

If the provider no longer reports the property, the stored row is deleted — that is the stale data the call exists to correct. A provider failure propagates instead of deleting, so a transient error is never mistaken for a removed claim.

Not available yet​

These return a failed future with UnsupportedOperationException. Do not build against them yet:

  • pauseProperty()
  • exemptProperty()
  • resetWarnings()
caution

The API surface will grow as the warning and removal lifecycle is finished. Treat anything not listed under Working methods above as unstable.