Host calls

Host calls

On this page

Everything a plugin can ask the server, grouped as the server's code is. Generated by tools/gen_api_docs.py from crates/rustmc-plugin/src/host.rs (the Host trait) and crates/rustmc-plugin-wasm/src/call.rs (what a Wasm guest sends). Do not edit by hand.

264 calls in the Host trait; 264 of them can be made by a Wasm guest.

How a call is made

  • A native Rust plugin calls the Host method on the &dyn Host it is handed.
  • A Wasm guest sends {"call": "<name>", ...fields} through the rustmc.call import and reads back {"ok": <value>} or {"error": "<why>"} (the ABI). An unknown call is an error, never a trap. With the guest SDK, rustmc_guest::host::call(name, fields) makes any call, and rustmc_guest::host has a typed function for most of them (the SDK index).
  • A parameter named plugin in a Rust signature is the calling plugin's own name. A Wasm guest never sends it: the server fills it in from the manifest, so a guest can act only as itself.

How values are encoded

RustWasm JSON
PlayerId, EntityIdinteger. A player's entity id is their player id
Worldstring: minecraft:overworld, minecraft:the_nether, minecraft:the_end, or a plugin world's name
BlockPos[x, y, z], whole numbers
Vec3[x, y, z], numbers (blocks)
u128 account id32 lower-case hex digits, no dashes (a request may use dashes)
Option<T>T, or null
Result<T, String>{"ok": T}, or {"error": "..."}
bool that says whether something happenedtrue / false; false usually means the player, entity or world has gone
()null
bytesas the field's notes say: a list of byte values, hex, or base64
text component (&str holding JSON)the component itself, as a JSON value, not a string
GameModesurvival, creative, adventure, spectator

Units: positions are blocks, times are ticks (20 a second) unless a field ends in _ms or _seconds, angles are degrees (yaw 0 faces south, +z), and health is half-hearts as the game counts it.

Item, block, entity, sound and particle ids that a Wasm request names are passed through the game's rename table, so a plugin built against an older name still works after the game renames it.

What needs the owner's grant

No host call is gated by the manifest. A few reach outside the server and do nothing unless the server owner granted them in rustmc.yml, or need something else set up:

CallNeeds
http_senda plugin-outbound.<plugin>.<grant> section in rustmc.yml
net_listena plugin-ports.<plugin>.<grant> section in rustmc.yml
net_unlistena plugin-ports grant (see net_listen)
net_polla plugin-ports grant (see net_listen)
net_senda plugin-ports grant (see net_listen)
net_responda plugin-ports grant (see net_listen)
net_closea plugin-ports grant (see net_listen)
network_publishnetwork.enabled in rustmc.yml; a channel outside the plugin's own namespace needs network.channels.<plugin>
network_subscribeas network_publish
network_sendnetwork.enabled, and a network.peers.<peer>.join address in rustmc.yml; the peer needs accepts-transfers=true
sql_submitone of the plugin's own secret settings holding the database URL; a setting that is not secret is refused
sql_resultsee sql_submit
storage_migratean operator (level 3) or the console running one of the plugin's own commands at that moment (see the doc comment)

Many calls act only on what the calling plugin made itself: its creatures, menus, boss bars, reserved blocks, guard zones, per-viewer tab entries, schematics, storage and grants. Each call's doc comment says so where it applies.

Constants

Limits and markers the calls' doc comments name, from crates/rustmc-plugin/src/value.rs and tab.rs:

ConstantValueWhat
KEEP_CELLu16::MAXA cell of Host::write_blocks that is left as it is.
MAX_BATCH1000The most entries one batched call takes.
MAX_BOX_COLUMNS16The most columns one box of Host::read_blocks reaches: each one read costs the calling thread, and an edit's slices are inside one.
MAX_BOX_ENTITY_BYTES512 * 1024The most SNBT one box of Host::read_blocks answers: what a guest can read inside a call's fuel.
MAX_BULK4096The most positions one bulk block call -- set_blocks, blocks_are -- takes at once.
MAX_FAKE_ENTRIES80The most fake rows one plugin shows one viewer: TAB's layout, four columns of twenty.
MAX_NEAR_RADIUS128.0The largest radius entities_in searches, in blocks.
MAX_NETWORK_PAYLOAD(1 << 20) - 1024The most bytes one network_publish payload may carry: what a link frame holds, less room for the channel and the frame's own header.
MAX_PUT_MANY16_384The most rows one storage_put_many carries, across its tables.
MAX_RECIPE_PAGE500The most recipes one recipes page holds.
STORAGE_BUSY"storage busy"What a refused storage_put_many starts with when the backend has fallen behind: nothing was kept, and the same rows may be offered again in a moment.

Groups

GroupCallsWhat
Players: who is here, visibility and moderation19Finding players, their identity and client, hiding them, bans, kicks and permission checks.
Player state: health, food, experience, mode and movement17What a player has and is doing, and changing it.
Inventory, items and components23Giving, taking, reading and editing stacks, cooldowns, dropped items and containers.
Entities and display entities46Reading and changing any entity, spawning entities (including per-viewer display entities), riding, and damage.
Plugin creatures6Creatures a plugin spawns, owns and gives orders to.
Blocks21Reading and writing blocks, block entities and whole boxes of blocks, and reserving and guarding blocks.
Worlds, time, border, game rules, sound and particles18Facts about a world as a whole, and effects played in it.
Chat and text8Plain and formatted messages, titles, chat completions and capturing a player's next chat line.
Tab list, nametags, sidebar, boss bars and scores27What each player sees in the tab list, over heads, in the sidebar and in boss bars.
Menus (GUI)3Chest-like screens of buttons that a plugin opens for one player.
Packets and plugin channels5Sending raw packets and plugin-channel messages, and decoding and encoding packet bodies.
Resource packs3Hosting a pack on the server's own pack host, and sending packs to players.
Storage16A plugin's own key-value bytes, its storage tables, and SQL on an external database.
Settings and disabled systems3The plugin's own settings, as the web portal edits them, and which vanilla systems it switched off.
The plugin bus3Calling another plugin, publishing news, and asking whether a plugin is running.
Outbound HTTP and plugin ports9Fetching from the web, sending to an owner-granted URL, and listening on an owner-granted port.
The server network: cross-server messages, presence and hopping7Publishing to the other servers network in rustmc.yml links, hearing them, who is on each, and sending players across.
Web map and chunk pre-generation6Drawing the web map, its markers, and queueing chunks to be generated ahead of players.
Schematics10Loading and saving schematic files in the plugin's own folder.
Recipes2The recipes the server has loaded, datapack ones included, as vanilla recipe JSON.
The server: time, logging, health, restarts and cryptography12The server clock, the log, health and profiling, restarts and world resets, and random numbers and RSA.

There is no host call for scheduling: a plugin counts tick events (one per server tick, 20 a second). Commands are declared in the manifest and arrive as command_run events.

Every call

CallGroupWasmWhat it does
add_effectentitiesyesGives a creature or a player an effect (minecraft:regeneration) for ticks, at amplifier (nought is level I), as /effect give does: an instant one is spent at once, a longer one replaces a weaker or shorter one.
add_effect_shownentitiesyesadd_effect, drawn as shown says: without particles (a plugin's own slow-down, which nobody else should see), without the icon, or ambient as a beacon's is.
airentitiesyesHow many ticks of breath somebody has left, or None if they have gone.
allowsplayersyesWhether somebody may run something needing this permission level.
attach_entityentitiesyesMakes entity follow leader, offset from it ([right, up, forward] in blocks, with the leader facing forward): whenever the leader is moved (move_entity), the follower is put at its offset from it, turned with its facing, and sent there in the same call.
attributeentitiesyesAn attribute's current value on somebody -- base, /attribute modifiers, effects and the modifiers their worn enchantments put there -- or None for an attribute this entity does not have, or an entity that has gone.
banplayersyesPuts name on the server's own ban list, with pardon and the login's refusal to go with it.
bannedplayersyesWhether name stands banned on the server's list now.
biome_atblocksyesThe biome at a position, as the player standing there is in it (minecraft:plains): the game's computed biome, through the same zoom the client is told of.
block_atblocksyesThe block at a position, by name, or None if that chunk is not readable.
block_datablocksyesThe block entity there as SNBT, as /data get block reads it: its id and what its type saves, with no position.
block_isblocksyesWhether the block there has one of the game's own per-state facts.
block_propertyblocksyesThe value of one of a block state's properties, as the game spells it.
block_state_atblocksyesThe whole state at a position, with its properties (minecraft:oak_stairs[facing=east,...]), or None if that chunk is not readable: what a plugin needs to put a block back exactly, through set_block.
blocks_areblocksyesblock_is for many positions in one call: one answer per position, in order, each None where block_is would answer None (a chunk that is not readable).
boss_bar_hidetab-and-scoreboardyesTakes one of this plugin's boss bars off a player's screen; false if they did not have it.
boss_bar_showtab-and-scoreboardyesShows one person a boss bar, or changes it if they have it: id is the plugin's own name for it, and the server keeps the wire's for each plugin and id, so the game's own bars -- raids, the wither, the dragon, /bossbar -- are never touched.
broadcasttextyesSends everybody one.
broadcast_texttextyesSends everybody a line of formatted chat; how many it went to.
can_seeplayersyesWhether viewer may see subject, for a plugin that lists players to a player.
can_spawn_atcreaturesyesWhether a creature of kind could be put with its feet in the block at, by the game's spawn placement for the kind (SpawnPlacements): standing on something solid with room for its body and no fluid at its feet, in water for a fish, in lava for a strider.
cancel_world_resetserveryesTakes back a reset asked for and not yet done.
capture_chattextyesTakes player's next chat line for this plugin: it arrives as a bus call from rustmc:chat ({"op": "chat.captured", "player", "text"}) and goes nowhere else -- no player_chat hook or event, no log line, no broadcast -- so an answer typed in chat (a password, a name) is seen by the plugin that asked and by nobody else.
chat_completionstextyesChanges the words a player's chat box offers to finish as they type (Paper's addCustomChatCompletions): an emoji's :shortcode:, a channel's name.
check_blocksblocksyesWhether every name is a block state this build knows: an error naming the first that is not.
chunk_on_diskworldsyesWhether a chunk has been written to disk (may read a region file's header from disk when it is not cached; refused past 1,875,000 chunks from the origin).
chunks_generatedmap-and-generationyesWhat became of the chunks this plugin queued in that world since it last asked.
clear_respawnplayer-stateyesForgets a player's respawn point, so they respawn at the world spawn; whether anybody was there.
client_brandplayersyesWhat a client calls itself, from minecraft:brand, if it ever said.
container_addinventoryyesPuts up to count of item into the block container at a position -- topping up its stacks first, then empty slots -- and answers how many went in.
container_removeinventoryyesTakes up to count of item out of the block container at a position, answering how many came out: what a rollback of items put in needs.
creature_ordercreaturesyesTells one of this plugin's plugin-driven creatures what to do from its next tick until it is told something else (Order); an order it was carrying out ends replaced.
creature_statecreaturesyesHow a creature is: where it is, its health, its mind, its owner, the order it is carrying out and whom at, and how its walk is going.
damageentitiesyesHurts somebody, by a named cause.
damage_byentitiesyesHurts an entity -- a player or a creature -- by a named damage type, struck by attacker: the blow is theirs as a sword's is, so a kill is credited to them (the death message names them, a creature's loot and experience are a player kill's) and the victim remembers who hit it last.
damage_sayingentitiesyesdamage, saying what to put in chat if it kills a player: the death message is their name, a space, and died (left the world gives Steve left the world).
destroy_blockblocksyesLevel.destroyBlock(pos, false): the block breaks -- its break particles and sound, the fluid it held left behind, BLOCK_DESTROY heard -- and drops nothing.
disabled_systemssettingsyesThe vanilla systems switched off at plugin's request: its manifest's disables narrowed to the names the server checks, hunger, mob_spawning and natural_regen (VANILLA_SYSTEMS).
dismountentitiesyesTakes rider off whatever it is riding, as a player crouching does: entity_dismounted goes first and a plugin may cancel it.
drop_iteminventoryyesDrops a stack into the world as an item entity at at: item with count and data components (as give_item takes them), moving at velocity blocks a tick or with the little scatter a dropped item has.
edit_cursorinventoryyesedit_slot for the stack on the cursor: its components set and removed, and with count its count set too (nought empties the cursor; otherwise 1 to what the stack, as edited, stacks to), only if it is still the stack stamp describes.
edit_slotinventoryyesChanges the components of the stack in one slot of a player's own inventory, in place and only if it is still the stack stamp (from inventory_slot) describes: the count may have moved, nothing else.
enchantment_levelentitiesyesWhat level of an enchantment somebody is wearing in one equipment slot.
entities_inentitiesyesThe creatures and players in world whose box comes within radius of centre (the nearest point of the box, so a tall creature beside a blast is reached by its legs), with where each stands and the box that was tested: for a blast hurting what is near it.
entity_unitentitiesyesOne draw from a creature's own stream, in 0.0..1.0.
entity_velocityentitiesyesHow fast an entity is going, in blocks a tick: a creature's or a boat's own velocity, a player's as player_motion has it, and for a vehicle its driver's client moves (a ridden boat, horse or happy ghast), the distance between the last two positions the client reported, over the ticks between them.
entity_viewersentitiesyesThe online players who see an entity spawn_entity_for made; None for one that is not such an entity.
exhaust_forentitiesyesCharges somebody the hunger this damage source costs.
experience_pointsplayer-stateyesThe experience somebody could spend, in points: every level they have, and the bar's progress towards the next (Player.calculateTotalExperiencePoints, not the lifetime score).
fire_ticksentitiesyesHow long somebody stays alight, in ticks, or None if they have gone.
fluid_atblocksyesWhat fluid is at a position: "minecraft:water", "minecraft:lava", or None.
game_modeplayer-stateyesThe game mode a player is in; None for a player who is not here.
game_rule_flagworldsyesA boolean game rule, by the short name /gamerule uses.
game_rule_numberworldsyesA numeric game rule, by the short name /gamerule uses.
giveinventoryyesPuts something in somebody's inventory, returning how many did not fit.
give_experienceplayer-stateyesGives experience points, as /xp add <player> <points>, or takes them when points is negative.
give_iteminventoryyesgive, with data components: a name, lore, a glint, enchantments, a player's head -- anything /give can put on an item, spelt as /give spells it (each component's id and its SNBT, such as ("minecraft:custom_name", "{text:'Key',color:'gold'}")).
give_stackinventoryyesGives count of exactly the stack snbt (text from take_slot) describes, spread over slots as give_item spreads it, answering how many did not fit -- or, with spill, dropping what did not fit at the player's feet as that same stack and answering nought.
guard_holdblocksyesHolds every block as protected, or lets go: what a plugin sets while it loads its zones.
guard_world_defaultsblocksyesSets what the guard allows of forces nobody controls in one world's blocks that no zone covers, as a zone's flags bits (1 blasts, 2 creatures, 4 fire): with Some(0) none of them in the wild.
guard_zonesblocksyesAdds or replaces put and removes remove in the guard's table for one world, what the game's own forces ask natively: fluids, pistons, hoppers, dispensers, fire, growth, blasts and creatures.
has_effectentitiesyesWhether a status effect is on somebody at this moment.
healplayer-stateyesHeals a player by amount, up to their maximum: what a regeneration tick does, without the effect.
held_iteminventoryyesWhat somebody is holding.
hiddenplayersyesThe permission level a player is hidden below, or None when everybody can see them.
hide_sidebartab-and-scoreboardyesTakes away the sidebar show_sidebar gave a player; false if they had none.
host_packpacksyesHosts a resource pack on the server's own pack host and answers its URL and SHA-1, for push_pack.
http_fetchnetworkyesStarts fetching url (https only, a GET), answering at once with a number to ask http_result about.
http_resultnetworkyesA finished fetch: its status and up to length bytes (at most 1 MiB) of the body from byte offset on, or why it failed.
http_sendnetworkyesSends request to one of this plugin's outbound grants: the plugin-outbound.<plugin>.<grant> section of rustmc.yml, whose URL the path is appended to.
inspect_closeinventoryyesCloses a view inspect_open opened: for when viewer has lost the right to it.
inspect_openinventoryyesOpens another player's inventory (view is inventory) or ender chest (ender), kept up to date while it is open, for viewer: the account's file if they are offline.
inventory_cursorinventoryyesThe stack a player holds on the cursor in an open screen -- picked up and not yet put down -- as inventory_slot reports a slot's, with its stamp.
inventory_slotinventoryyesWhat is in one slot of a player's own inventory, numbered as the game's Inventory numbers them: 0-8 the hotbar, 9-35 the rest, 36-39 the armour (feet, legs, chest, head), 40 the off hand.
is_bedrockplayersyesWhether a player is connected through Bedrock rather than a Java client.
is_in_rainentitiesyesWhether rain is falling on somebody where they stand.
is_on_groundentitiesyesWhether somebody is standing on something.
is_sneakingentitiesyesWhether somebody is crouching.
item_cooldowninventoryyesThe ticks left of a group's cooldown (set_item_cooldown), nought when it is not cooling: the server's own pearls and wind charges included.
item_countinventoryyesHow many of item somebody carries: their main inventory, hotbar, armour and offhand (not the crafting grid).
item_count_whereinventoryyesitem_count by what the stacks carry: of item (any item when None), only the stacks whose minecraft:custom_data holds every (key, snbt) of custom_data -- a plugin's own items, counted in one call whatever they are made of, such as [("myplugin:id", "\"timber\"")].
item_sum_whereinventoryyesitem_count_where, summing a number the stacks carry rather than counting them: for each matching stack, its count times the whole number its minecraft:custom_data holds at sum_key -- or times one where the key is missing or not a whole number.
kickplayersyesThrows somebody off the server, as /kick does: their client is shown reason (plain text, as message takes it; empty is the game's "Kicked by an operator") and closes the connection.
latencyplayersyesA player's latency in milliseconds, as their keep-alive answers measure it: the number the tab list's bars are drawn from (connection.latency(), a running average).
list_fake_entriestab-and-scoreboardyesShows one viewer plugin's fake tab-list rows -- TAB's layout -- in place of the ones it showed them before: up to MAX_FAKE_ENTRIES profiles that are nobody, each with its own text, latency, game mode, skin and order.
list_fake_entries_batchtab-and-scoreboardyeslist_fake_entries for many viewers at once, up to MAX_BATCH rows in all; how many viewers were there.
list_score_rendertab-and-scoreboardyesWhether the plugin tab-list objective draws its numbers as numbers or as hearts, for every viewer.
loadstorageyesReads one back, or None if it was never stored.
local_difficultyworldsyesThe local difficulty at a place, which is not the world's difficulty setting.
logserveryesWrites a line to the server's own log, tagged with the plugin's name.
may_interactentitiesyesEntity.mayInteract(level, pos): whether this body may change the block there.
menu_closemenusyesShuts a menu this plugin opened; answers whether it was still open.
menu_openmenusyesOpens a menu for a player: a chest-like screen of rows (1 to 6) rows of nine, titled title, with these slots filled.
menu_setmenusyesChanges slots of a menu this plugin opened, while the player still has it open; answers whether it was still open.
messagetextyesSends one person a line of chat.
message_texttextyesSends one person a line of formatted chat: a text component as JSON (the game's own form: {"text": "Hi", "color": "gold", "extra": [...]}, or a bare string, or a list).
mountentitiesyesPuts rider on vehicle, as /ride <rider> mount <vehicle> does: a player, a creature or a display on a creature, a display, a boat or a minecart -- however many are already on it, so a display rig and extra seats stack onto one mount.
move_entitiesentitiesyesMoves several entities at once, each as move_entity does: a plugin's vehicle moving its root, its rig and every seat each tick in one call.
move_entityentitiesyesPuts an entity somewhere else in its world, facing yaw and pitch.
net_closenetworkyesCloses a connection once what is waiting to go has gone.
net_listennetworkyesOpens one of this plugin's grants: the plugin-ports.<plugin>.<grant> section of rustmc.yml.
net_pollnetworkyesWhat happened on this plugin's ports, oldest first.
net_respondnetworkyesAnswers an http request, once.
net_sendnetworkyesSends bytes on a connection, after an http one's net_respond said more.
net_unlistennetworkyesCloses a grant and every connection on it.
network_nameserver-networkyesThis server's name on the network, network.name in rustmc.yml: None while the network is off, which is how a plugin that works alone or across servers tells which.
network_playersserver-networkyesEveryone online anywhere on the network, this server's players first, each with the server they are on and whether that server hides them.
network_publishserver-networkyesSends payload on channel to every peer whose link is up, and to this server's own subscribers -- the publisher among them, if it subscribed -- unless local is false.
network_sendserver-networkyesSends player to the peer named server, by the transfer packet to its join address in rustmc.yml.
network_serversserver-networkyesEvery server on the network, this one first and then each peer rustmc.yml names: whether this server's link to it is up (a publish now reaches it), how many players it has online, hidden ones not counted, and its max-players (nought until a peer has said).
network_subscribeserver-networkyesHears channel as the network_message event, from every server, this one included.
network_unsubscribeserver-networkyesStops hearing what network_subscribe named, spelt as it was.
nowserveryesThe wall clock: milliseconds since 1970 (UTC).
nudge_viewplayer-stateyesTurns a player's view by dyaw and dpitch degrees from wherever it is on their screen: ClientboundPlayerRotationPacket with both relative flags, so a recoil kick adds to the player's own aim rather than snapping it back to where the server last heard it was.
objective_titletab-and-scoreboardyesThe title of the plugin objective in slot (below_name or list), a text component, for every viewer: what below-name draws after each number.
packet_decodepacketsyesA packet's body as its named fields (a map), for a packet this server has a schema for: ProtocolLib's PacketContainer.
packet_encodepacketsyesThe other way: named fields, every one given, as the packet's bytes.
packet_schemaspacketsyesEvery packet packet_decode and packet_encode know, each with its fields and their kinds: {"play.clientbound.set_health": [["health", "float"], ...]}.
pardonplayersyespardon: lifts name's ban, whoever made it, and answers whether there was one.
particleworldsyesShows count of a particle at a place, scattered over spread (each axis's standard deviation) and moving at speed, to everybody near enough to see.
passengersentitiesyesWho is on an entity, in order: the first is the one who steers.
play_soundworldsyesPlays one of the game's sounds to one player, where they stand: sound by name (minecraft:entity.experience_orb.pickup), category the client's volume slider it obeys (players, blocks, hostile, neutral, ambient, weather, records).
player_motionplayer-stateyesHow a player is moving: their velocity, and whether they are sprinting, sneaking and on the ground.
player_nameplayersyesA player's name, or None if they have gone.
player_namedplayersyesFinds somebody by name, case-insensitively, as a command would.
player_uuidplayersyesA player's uuid, as the sixteen bytes it is.
playersplayersyesEverybody currently connected.
players_inentitiesyesThe players in world whose box meets the box between the corners min and max (in either order), with where each stands.
plugin_callbusyesThe plugin bus: a request from plugin to the plugin named target, answered at once.
plugin_emitbusyesThe plugin bus: news from plugin on topic, to every other plugin listening.
plugin_statebusyesWhat became of the plugin called name: running; stopped, when it was unloaded or its file is in the plugin folder and it is not loaded; none, when there is no such plugin.
pop_packpacksyesTakes a pack back off.
positionentitiesyesWhere somebody is.
profilerserveryesThe server's sampling profiler: op is start (sampling every interval_ms), stop (answers the report: each system's share of the samples and its time, as JSON) or status.
push_packpacksyesOffers a resource pack to one player, on top of any they already hold.
queue_chunksmap-and-generationyesQueues chunks to be generated and written off the tick: at most 4096 outstanding per plugin and world, none past 1,875,000 chunks from the origin, None when read-only or stopping.
raycastentitiesyesCasts a ray, run by the server so it costs the plugin no fuel: from a point or a player's eyes, up to max_distance blocks (at most 512), against blocks' collision shapes (a slab stops it at its top, an open trapdoor not at all; fluids never) and entities' boxes, as RayFilter allows; the first thing met, or None.
read_blocksblocksyesEvery cell of the box between two corners, in one call: what an edit reads before it writes.
recipesrecipesyesOne page of the recipes the server has loaded, as vanilla recipe JSON keyed by id: the game's own and every one the world's enabled datapacks add, a datapack's replacing the game's of the same id.
recipes_revisionrecipesyesThe revision of the recipe set recipes pages through: 16 hex digits that change when a reload changes any recipe, and only then.
refresh_commandsplayersyesSends a player their command list again, decided afresh, at the next tick: for a permissions plugin, after a change that adds or removes a command they may run.
release_blocksblocksyesGives back states reserve_blocks took, by the same patterns; all of the plugin's in that world for none.
release_chattextyesEnds this plugin's capture of a player's next line; whether one was open.
remove_attribute_modifierentitiesyesTakes a modifier off by its id.
remove_effectentitiesyesTakes one effect off a creature or a player, as /effect clear <target> <effect> does: its attribute modifiers go with it and the client is told.
remove_entityentitiesyesTakes an entity out of the world without a death: any creature, display, boat or cart, or item lying on the ground, not only the plugin's own.
render_web_mapmap-and-generationyesDraws a world's web map now, once: Ok(true) when drawing starts, Ok(false) when it is drawn or being drawn already (or web-map.render is on-create), Err when the web map is off or does not draw that world.
request_restartserveryesStops the server as /stop does -- every plugin told server_stopping and stopped, the world and everybody in it saved -- and then ends the process with RESTART_EXIT_CODE rather than nought, so the script or service that started it starts it again (see docs/restarting.md).
reserve_blocksblocksyesReserves block states in one world for this plugin's own blocks: each of states is a state or a pattern (minecraft:note_block[instrument=banjo,note=3] is every state with those, whatever else; a bare name is every state of the block).
rotationentitiesyesWhich way somebody faces: yaw (degrees clockwise from +Z, as the game counts it) and pitch.
rsa_decryptserveryesTakes the PKCS#1 v1.5 padding off an RSA block, with a PKCS#8 DER key.
rsa_generateserveryesA new RSA-2048 key pair.
save_playerplayer-stateyesWrites an online player's data file now, rather than at the next save.
schedule_world_resetserveryesAsks for the world to be reset the next time the server starts: before it opens, the world directory is renamed aside with the time in its name (nothing is deleted) and a fresh one is made, with reset.seed or a random seed and the generator the server is configured with, its sidecars written anew.
schematic_cellsschematicsyesCells start onwards of a loaded schematic, at most 65,536, each an index into its names, x fastest, then z, then y.
schematic_closeschematicsyesLets go of a ticket, whatever it was doing.
schematic_entitiesschematicsyesBlock entities start onwards of a loaded schematic, at most count, 64 a call and 1 MiB: where, from the box's lowest corner, and SNBT set_block_data takes.
schematic_finishschematicsyesWrites a saved schematic out on a thread of its own, whole or not at all, as Sponge version 3.
schematic_listschematicsyesWhat is in this plugin's schematic folder, plugins/<plugin>/schematics, at most 1,024 names.
schematic_loadschematicsyesStarts reading <name>.schem from this plugin's folder, a Sponge schematic of version 1 to 3, on a thread of its own, answering at once with a ticket for schematic_result.
schematic_namesschematicsyesNames start onwards of a loaded schematic, at most 256: None for a block this server does not know.
schematic_putschematicsyesThe next piece of a schematic being saved.
schematic_resultschematicsyesHow a load or save went: None while it runs and for a ticket this plugin does not hold.
schematic_saveschematicsyesStarts saving <name>.schem to this plugin's folder: a ticket for schematic_put, and then schematic_finish.
secure_randomserveryeslength bytes from the operating system's cryptographic source, at most 4096: for keys, tokens and challenges.
selected_slotplayer-stateyesThe hotbar slot a player has selected, 0-8, numbered as inventory_slot numbers it; None for one not online.
send_packetpacketsyesSends one player a packet, as the game would have: packet names it as its hook point does (play.clientbound.set_title_text, packet. optional) and body is its bytes -- from packet_encode, or written by hand.
send_payloadpacketsyesSends a message on a plugin channel.
server_healthserveryesHow the server is doing, as JSON: TPS, MSPT (average and longest) and CPU over 5 s, 10 s, 1 min, 5 min and 15 min, memory, and the players, creatures and worlds.
set_airentitiesyesSets it.
set_attribute_modifierentitiesyesPuts a modifier on one of somebody's attributes, as /attribute <target> <attribute> modifier add does but replacing one of the same id rather than refusing: id is a namespaced name the plugin owns (myplugin:aiming), operation is add_value, add_multiplied_base or add_multiplied_total.
set_below_nametab-and-scoreboardyesThe number one viewer sees under target's name, with its own number format; None takes it away.
set_below_name_batchtab-and-scoreboardyesset_below_name for up to MAX_BATCH entries; how many applied.
set_blockblocksyesPuts a block there.
set_block_datablocksyesMerges snbt, a compound, into the block entity there, as /data merge block does: a compound field merged into the one held, any other field replacing it.
set_blocksblocksyesset_block for many blocks in one call: each position set to its state (properties and all, as set_block takes one), in the order given, each as set_block sets it.
set_blocks_datablocksyesset_block_data for many positions in one call, in the order given, each as set_block_data writes it: a landmark's signs at once.
set_creature_aicreaturesyesChanges whose decisions one of this plugin's creatures acts on.
set_creature_dropscreaturesyesDecides what one of this plugin's creatures leaves when it dies, instead of its loot table and its equipment, and what experience it is worth; None gives it back its own.
set_displayentitiesyesChanges a display's fields (SNBT: {text:"Hi",billboard:"center"}), as /data merge entity would, and shows everybody watching.
set_entity_velocityentitiesyesPushes an entity: sets its velocity, in blocks a tick, and sends it to everybody watching -- ClientboundSetEntityMotionPacket, what an explosion or a wind charge sends.
set_entity_viewersentitiesyesReplaces who sees an entity spawn_entity_for made: those taken off are sent its removal, those added are sent it whole.
set_fire_ticksentitiesyesSets it.
set_foodplayer-stateyesSets a player's food bar: food 0 to 20, saturation 0 to food, as the game keeps them.
set_game_modeplayer-stateyesPuts a player in a game mode, as /gamemode does.
set_healthplayer-stateyesSets a player's health, as /data cannot: above nought and at most their maximum (which Health Boost raises), clamped to it.
set_hiddenplayersyesHides a player from everybody who may not run something needing permission level or, given viewers, from everybody but those players (an unlisted operator too, and an empty list hides them from all): gone from their tab list and their world, as if they had left.
set_hidden_accountplayersyesset_hidden for an account, online or not: a player arriving on it is hidden before anything is sent about them.
set_item_cooldowninventoryyesStarts an item cooldown, as an ender pearl's: for ticks the client draws the sweep across every stack in the group, and it replaces any cooldown of the group running; nought ends one.
set_list_game_mode_shown_fortab-and-scoreboardyesThe game mode one viewer's tab list shows for target, over their real one -- a spectator shown as survival, so they are not greyed out at the bottom -- or None for the real one.
set_list_game_mode_shown_for_batchtab-and-scoreboardyesset_list_game_mode_shown_for for up to MAX_BATCH entries; how many applied.
set_list_latencytab-and-scoreboardyesThe latency everybody's tab list shows for target, in milliseconds, over the measured one (a ping spoof); None shows the measured one again.
set_list_nametab-and-scoreboardyesShows a player in everybody's tab list under name (a text component), or as themselves again for None; kept for players who join later.
set_list_name_fortab-and-scoreboardyesShows target in one viewer's tab list under name (a text component), over the name set_list_name gives everybody; None shows that viewer what everybody sees again.
set_list_name_for_batchtab-and-scoreboardyesset_list_name_for for up to MAX_BATCH entries at once, each viewer's sent as one packet.
set_list_ordertab-and-scoreboardyesWhere a player sorts in everybody's tab list: higher first.
set_list_scoretab-and-scoreboardyesThe number one viewer's tab list shows beside target, as set_below_name does under their name: the tab-list objective, drawn as a number or as hearts (list_score_render).
set_list_score_batchtab-and-scoreboardyesset_list_score for up to MAX_BATCH entries; how many applied.
set_listed_fortab-and-scoreboardyesWhether target is in one viewer's tab list at all: what a per-world player list hides people with.
set_listed_for_batchtab-and-scoreboardyesset_listed_for for up to MAX_BATCH entries; how many applied.
set_nametagtab-and-scoreboardyesGives a player a nametag: a prefix and suffix (text components) around their name, over their head and in the tab list, its colour, who sees it and who pushes them.
set_nametag_batchtab-and-scoreboardyesset_nametag for up to MAX_BATCH players at once; how many applied (the player there).
set_nametag_fortab-and-scoreboardyesGives target a nametag as one viewer sees it, over the one set_nametag gives everybody: a relational prefix or suffix, or the tag hidden from that viewer alone (visibility: never).
set_nametag_for_batchtab-and-scoreboardyesset_nametag_for for up to MAX_BATCH entries; how many applied.
set_passengersentitiesyesPuts exactly riders on vehicle, in that order, as /ride would one by one but with the order kept as given: the first steers, and the client seats each at its place in the list (a happy ghast's four, a camel's two; past the last, at the last).
set_respawnplayer-stateyesSets where a player respawns after dying, as /spawnpoint does: the block they stand in at at in world, facing yaw, needing no bed (two free blocks, or the world spawn).
set_slotinventoryyesPuts a stack in one slot of a player's own inventory, numbered as inventory_slot numbers them, in place of whatever was there: count 0 empties it.
set_tab_headertab-and-scoreboardyesThe lines above and below one player's tab list, as text components ("" for none).
set_ticks_frozenentitiesyesSets it.
set_time_of_dayworldsyesSets a world's clock, as /time set does.
set_world_borderworldsyesMoves it.
setting_setsettingsyesChanges one of plugin's own settings, as the web portal does: checked against what it declared, kept in plugins/<plugin>/settings.json, and settings_changed told to every other plugin that hears it (the one that changed it knows).
settingssettingsyesplugin's settings, every declared one, as a JSON object of key to value: what the server keeps, or the default where nobody has changed it.
show_sidebartab-and-scoreboardyesShows one person a sidebar of their own: a title and up to 15 lines, top to bottom, each a text component as message_text takes them, drawn without numbers.
show_sidebar_linestab-and-scoreboardyesShows one person a sidebar whose lines each have their own right-hand side: a text component where the number would be, or a number, or nothing (TAB's text||format||score).
show_titletextyesShows one person a title across the middle of their screen, and a subtitle under it: text components as message_text takes them.
sound_atworldsyesPlays a sound at a place, to everybody near enough to hear it, as play_sound names one.
spawn_creaturecreaturesyesMakes one of the game's creatures for this plugin, dressed and tuned as options says (CreatureOptions): a name, equipment with data components, attribute bases, persistent, silent and invulnerable, and its mind -- its own vanilla one, none, or the plugin's (creature_order).
spawn_entityentitiesyesMakes an entity, as /summon would with the same tag (nbt, SNBT; empty for none), and answers its id: a creature, an armour stand, a mannequin, an interaction box, or a display (minecraft:item_display, block_display, text_display, whose fields -- item, block_state, text, transformation, billboard and the rest -- are the game's own).
spawn_entity_forentitiesyesspawn_entity for some players only: a display (item_display, block_display, text_display), an interaction or a mannequin, whose spawn, movement and data go to viewers and to nobody else -- a building preview, a marker meant for one player.
sql_resultstorageyesA finished batch's outcome, taken: each statement's affected rows as a JSON list, or why it failed (the database's own message, the URL and password taken out).
sql_submitstorageyesQueues SQL for an external MySQL database -- one a website reads, whose schema the plugin owns; not the plugin's own storage.
statisticplayer-stateyesOne of a player's statistics, as the statistics screen counts it: stat is its type (minecraft:custom, minecraft:mined, minecraft:killed, ...) and key what it counts (minecraft:play_time, minecraft:stone, minecraft:zombie).
storage_backendstorageyesWhich backend this plugin's tables are in: json, sqlite or mysql.
storage_countstorageyesHow many rows of the table have a key starting with prefix.
storage_deletestorageyesDeletes one row, answering whether there was one.
storage_dropstorageyesDrops one of this plugin's own tables: every row in it, at once, in whichever backend it is in.
storage_getstorageyesOne row of this plugin's table, as JSON text, or None when there is no such row.
storage_landstorageyesWaits, for a bounded time, for this plugin's bulk writes to land: for a plugin's stop.
storage_migratestorageyesStarts moving this plugin's rows from backend from (which must be the one it is on) to to, and answers at once; storage_migration follows it.
storage_migrationstorageyesThis plugin's latest migration since the server started, or None.
storage_outcomestorageyesWhat became of a storage_put_many.
storage_putstorageyesInserts or replaces one row.
storage_put_manystorageyesKeeps many rows in one call: each table's in one write of the backend, in the order given.
storage_scanstorageyesRows whose key starts with prefix, in byte order of the key, after after when given, at most limit (which is at most 1000) of them.
storestorageyesStores a value for this plugin, under a key of its choosing.
swing_armplayer-stateyesSwings a player's arm, as a hit or a use swings it, for them and everybody who can see them: the main hand, or the off hand with off_hand.
take_heldinventoryyesTakes up to count of item from the stack in a player's main hand, if that stack is item, and tells their client; how many were taken.
take_iteminventoryyesTakes up to count of item out of somebody's inventory, in /clear's order: the hotbar, the main inventory, then armour and the offhand (never the crafting grid).
take_item_whereinventoryyestake_item by what the stacks carry, as item_count_where matches them: up to count of the stacks whose custom data holds every (key, snbt), of item or of any item.
take_slotinventoryyesTakes the whole stack out of one slot of a player's own inventory (numbered as inventory_slot numbers them) -- with a stamp (from inventory_slot), only if it is still the stack the stamp describes; with none, whatever is there -- and answers it as lossless text with its item and count.
teleportplayer-stateyesMoves somebody.
tickserveryesHow many ticks since the server started.
tick_healthserveryesHow long ticks are taking.
ticks_frozenentitiesyesHow frozen somebody is, in ticks, or None if they have gone.
time_of_dayworldsyesThe time of day, in ticks, out of twenty-four thousand.
unqueue_chunksmap-and-generationyesDrops this plugin's chunks still waiting in that world; one being built finishes and is reported.
vehicle_ofentitiesyesWhat an entity is riding; None for nothing, or an entity not there.
vitalsplayer-stateyesHealth, food and saturation.
watch_inputplayersyesStarts or stops telling this plugin which movement keys a player holds: with it on, a player_input event each time the keys their client reports change -- forward, backward, left, right, jump, sneak, sprint -- and never while they hold the same ones.
watch_lookplayersyesStarts or stops telling this plugin where a player looks: with it on, a player_look event each tick the player's yaw or pitch has changed since they were last told -- at most one a tick per player, carrying where they look by then.
web_map_markermap-and-generationyesPuts a labelled marker on a world's web map, or moves or renames the plugin's marker of the same id: Ok(true) when the map changed, Ok(false) when it was so already, Err when the web map is off, does not draw that world, or the marker is refused.
web_map_remove_markermap-and-generationyesTakes the plugin's marker of that id off a world's web map: Ok(true) when there was one, Ok(false) when there was none, Err when the web map is off or does not draw that world.
world_borderworldsyesWhere the world stops: the centre, and the full width rather than the half-width.
world_border_damageworldsyesWhat being outside costs: the damage per block past the safe zone, and the safe zone.
world_ceilingworldsyesOne past the highest y a block may exist at in this world.
world_floorworldsyesThe lowest y a block may exist at in this world.
world_idworldsyesWhat tells this world from any other that has stood in its place: None for a dimension this server does not serve, or a folder it cannot write to.
world_ofentitiesyesWhich world somebody is in.
world_sidecarworldsyesA file the world's generator left beside it (Generator::sidecars), by its plain file name, or None where there is none.
world_spawnworldsyesWhere a new player appears in this world: what a /spawn command sends somebody to.
worldsworldsyesEvery world this server serves, by name: minecraft:overworld and whichever of the Nether and the End are enabled.
wornentitiesyesWhat somebody is wearing in one equipment slot, as an item id.
write_blocksblocksyesWrites the box between two corners in one call: each cell an index into palette, x fastest, then z, then y, and KEEP_CELL for a cell left as it is.

From docs/api/reference/host-calls.md in the RustMC repository at bbd81209ad.