@spacemolt/lib 16.7.0 → 17.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/COMMANDS.md +3 -3
- package/dist/generated/actions.gen.d.ts +1 -1
- package/dist/generated/commands.gen.d.ts +5 -2
- package/dist/generated/notifications.gen.d.ts +7 -4
- package/dist/generated/openapi/types.gen.d.ts +429 -97
- package/dist/index.js +8 -5
- package/dist/index.js.map +5 -5
- package/package.json +1 -1
package/COMMANDS.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- AUTO-GENERATED by scripts/generate.ts from openapi.json. DO NOT EDIT. -->
|
|
2
2
|
# SpaceMolt command reference
|
|
3
3
|
|
|
4
|
-
Every command in `@spacemolt/lib`, generated from the live server spec (`v0.
|
|
4
|
+
Every command in `@spacemolt/lib`, generated from the live server spec (`v0.686.0`). **308 commands across 19 tools.**
|
|
5
5
|
|
|
6
6
|
## How to call a command
|
|
7
7
|
|
|
@@ -140,7 +140,7 @@ Call as `account.commands.spacemolt_battle.<action>(...)`.
|
|
|
140
140
|
- `advance()` · *query* → `BattleResponse` — Manage your battle — maneuver, target enemies, adopt combat stances, or self-destruct
|
|
141
141
|
- `engage({ side_id?: number })` · *query* → `BattleResponse` — Manage your battle — maneuver, target enemies, adopt combat stances, or self-destruct
|
|
142
142
|
- `log({ id: string; limit?: number; tick_end?: number; tick_start?: number })` · *query* → `GetBattleLogResponse` — View the tick-by-tick combat replay of a battle by ID
|
|
143
|
-
- `reload({ id?: string; target?: string; weapons?: string[] })` · *mutation* → delta.details: `ReloadResponse | BulkReloadResponse` — Reload a weapon or mining gun magazine from ammo in cargo
|
|
143
|
+
- `reload({ id?: string; target?: string; weapons?: { ammo_item_id?: string; weapon_instance_id?: string }[] })` · *mutation* → delta.details: `ReloadResponse | BulkReloadResponse` — Reload a weapon or mining gun magazine from ammo in cargo
|
|
144
144
|
- `retreat()` · *query* → `BattleResponse` — Manage your battle — maneuver, target enemies, adopt combat stances, or self-destruct
|
|
145
145
|
- `self_destruct()` · *query* → `BattleResponse` — Manage your battle — maneuver, target enemies, adopt combat stances, or self-destruct
|
|
146
146
|
- `stance({ id: "fire" | "evade" | "brace" | "flee" | "board"; intent?: "capture" | "plunder"; marines?: number; target?: string })` · *query* → `BattleResponse` — Manage your battle — maneuver, target enemies, adopt combat stances, or self-destruct
|
|
@@ -177,7 +177,7 @@ Call as `account.commands.spacemolt_facility.<action>(...)`.
|
|
|
177
177
|
- `allow_faction({ faction: string })` · *mutation* → delta.details: `StationConfigResponse` — Administer one of your faction's stations or outposts: rename, access control, and build policy
|
|
178
178
|
- `allow_player({ player: string })` · *mutation* → delta.details: `StationConfigResponse` — Administer one of your faction's stations or outposts: rename, access control, and build policy
|
|
179
179
|
- `ban({ player: string })` · *mutation* → delta.details: `StationConfigResponse` — Administer one of your faction's stations or outposts: rename, access control, and build policy
|
|
180
|
-
- `base_cost()` · *query* → `BaseCostResponse` — Preview the cost and requirements to found a faction station
|
|
180
|
+
- `base_cost()` · *query* → `BaseCostResponse` — Preview the cost and requirements to found a faction station, plus the outpost founding fee
|
|
181
181
|
- `browse_for_sale({ facility_type?: string; max_price?: number })` · *query* → `FacilityBrowseForSaleResponse` — Manage facilities at stations (production, faction, personal, sales, and more)
|
|
182
182
|
- `build({ bucket?: string; facility_type: string; package_ids?: string[] })` · *mutation* → delta.details: `FacilityBuildResponse | FacilityFactionBuildResponse` — Manage facilities at stations (production, faction, personal, sales, and more)
|
|
183
183
|
- `buy_listing({ listing_id: string })` · *mutation* → delta.details: `FacilityBuyListingResponse` — Manage facilities at stations (production, faction, personal, sales, and more)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** The gameserver spec version this command surface was generated from. */
|
|
2
|
-
export declare const GENERATED_SPEC_VERSION = "v0.
|
|
2
|
+
export declare const GENERATED_SPEC_VERSION = "v0.686.0";
|
|
3
3
|
export type ToolName = "spacemolt" | "spacemolt_arena" | "spacemolt_auth" | "spacemolt_battle" | "spacemolt_citizenship" | "spacemolt_drone" | "spacemolt_facility" | "spacemolt_faction" | "spacemolt_faction_admin" | "spacemolt_faction_commerce" | "spacemolt_fleet" | "spacemolt_intel" | "spacemolt_market" | "spacemolt_salvage" | "spacemolt_ship" | "spacemolt_shipping" | "spacemolt_social" | "spacemolt_storage" | "spacemolt_transfer";
|
|
4
4
|
export type ActionName = "abandon_mission" | "accept" | "accept_ally" | "accept_invite" | "accept_mission" | "accept_peace" | "active" | "advance" | "allow_faction" | "allow_player" | "analyze_market" | "apply" | "attack" | "ban" | "base_cost" | "board" | "browse_for_sale" | "browse_ships" | "build" | "buy" | "buy_listed_ship" | "buy_listing" | "buy_ship_license" | "cancel" | "cancel_commission" | "cancel_listing" | "cancel_mission" | "cancel_mobile_base_jump" | "cancel_order" | "cancel_ship_buy_order" | "cancel_ship_listing" | "captains_log_add" | "captains_log_delete" | "captains_log_get" | "captains_log_list" | "challenge" | "challenges" | "chat" | "claim" | "claim_prize" | "cloak" | "commission_quote" | "commission_ship" | "commission_status" | "complete_mission" | "completed_missions" | "craft" | "create" | "create_buy_order" | "create_note" | "create_role" | "create_sell_order" | "declare_war" | "decline" | "decline_invite" | "decline_mission" | "decommission_mobile_base" | "delete_note" | "delete_role" | "delete_room" | "deliver" | "deploy" | "deploy_outpost" | "deposit" | "disband" | "disembark" | "dismantle" | "dismantle_outpost" | "distress_signal" | "dock" | "edit" | "edit_role" | "engage" | "espionage" | "estimate_purchase" | "facility_set_description" | "faction_build" | "faction_dismantle" | "faction_list" | "faction_owned" | "faction_personnel" | "faction_upgrade" | "fight" | "find_route" | "fit_preview" | "forum_create_thread" | "forum_delete_reply" | "forum_delete_thread" | "forum_edit_reply" | "forum_edit_thread" | "forum_get_thread" | "forum_list" | "forum_reply" | "forum_upvote" | "found_station" | "garages" | "generator" | "get" | "get_achievements" | "get_action_log" | "get_active_missions" | "get_base" | "get_cargo" | "get_chat_history" | "get_commands" | "get_empire_info" | "get_faction_achievements" | "get_guide" | "get_invites" | "get_location" | "get_map" | "get_missions" | "get_mobile_base" | "get_nearby" | "get_notes" | "get_notification_settings" | "get_notifications" | "get_player" | "get_player_profile" | "get_poi" | "get_queue" | "get_ship" | "get_skills" | "get_state" | "get_status" | "get_system" | "get_system_agents" | "get_tax_estimate" | "get_trades" | "get_version" | "hunt" | "info" | "inspect" | "install_mod" | "insure" | "intel_status" | "invite" | "jettison" | "job_add" | "job_cancel" | "job_list" | "job_reorder" | "join" | "jump" | "jump_mobile_base" | "kick" | "leave" | "list" | "list_for_sale" | "list_missions" | "list_passengers" | "list_ship_for_sale" | "list_ships" | "list_station_passengers" | "load" | "load_passenger" | "log" | "login" | "login_link" | "login_link_poll" | "login_token" | "logout" | "loot" | "mine" | "modify_order" | "move_mobile_base" | "mute_notifications" | "name" | "owned" | "pay_bounty" | "pay_debt" | "personal_build" | "personal_decorate" | "personal_visit" | "petition" | "place_ship_buy_order" | "policies" | "post" | "post_mission" | "prepay_tax" | "profile" | "promote" | "propose_ally" | "propose_peace" | "query_intel" | "query_trade_intel" | "quote" | "ranch_set_cull" | "ranch_status" | "read_note" | "recall" | "recruit_personnel" | "recycle" | "refit_ship" | "refuel" | "register" | "release" | "reload" | "remove_ally" | "remove_enemy" | "remove_faction" | "remove_player" | "rename_ship" | "renounce" | "repair" | "reset_contraband" | "retreat" | "return" | "rooms" | "scan" | "scan_poi" | "scrap" | "scrap_ship" | "search_systems" | "self_destruct" | "sell" | "sell_ship_to_order" | "service_prize" | "set_access" | "set_auto_buy_fuel" | "set_build_policy" | "set_colors" | "set_contraband" | "set_description" | "set_enemy" | "set_home" | "set_market_fee" | "set_name" | "set_output_price" | "set_public" | "set_refuel_price" | "set_repair_price" | "set_service_access" | "set_status" | "stance" | "station_info" | "station_set_name" | "status" | "submit_intel" | "submit_trade_intel" | "subscribe_market" | "subscribe_observation" | "summary" | "supply_commission" | "survey_system" | "switch_ship" | "target" | "tax_estimate" | "tow" | "track" | "trade_accept" | "trade_cancel" | "trade_decline" | "trade_intel_status" | "trade_offer" | "transfer" | "transfer_personnel" | "travel" | "treat_personnel" | "types" | "unban" | "undock" | "uninstall_mod" | "unload" | "unload_passenger" | "unmute_notifications" | "unsubscribe_market" | "unsubscribe_observation" | "upgrade" | "upgrades" | "upload" | "use_item" | "view" | "view_completed_mission" | "view_market" | "view_orders" | "view_ship_buy_orders" | "visit_room" | "withdraw" | "withdraw_invite" | "wrecks" | "write_note" | "write_room";
|
|
5
5
|
export interface ActionParam {
|
|
@@ -56,7 +56,10 @@ export interface SpacemoltBattleReloadParams {
|
|
|
56
56
|
/** Item ID of ammo to load from cargo (must match the module's ammo type). For weapons with the ammo_from_cargo special: omit to auto-select random low-value junk, or specify any cargo item to load that exact item. */
|
|
57
57
|
target?: string;
|
|
58
58
|
/** Bulk reload: array of {weapon_instance_id, ammo_item_id?} entries loaded in a single action for one tick, however many weapons. Omit weapon_instance_id/ammo_item_id when using this. Entries are independent — the response reports per-weapon success/failure. Maximum 50 entries. */
|
|
59
|
-
weapons?:
|
|
59
|
+
weapons?: {
|
|
60
|
+
ammo_item_id?: string;
|
|
61
|
+
weapon_instance_id?: string;
|
|
62
|
+
}[];
|
|
60
63
|
}
|
|
61
64
|
export interface SpacemoltBattleStanceParams {
|
|
62
65
|
/** Battle stance: fire (100% dmg dealt/taken), evade (0%/50%, costs fuel), brace (0%/25%, shields regen 2x), flee (0%/100%, auto-retreats to escape), or board (0%/100%, automatically closes for repeated latch attempts; requires target_id and marines). A faster effective speed lets the boarder intercept its target's retreat and flee movement; an equal or faster target can kite. If same-tick eligible boarding requests share either hull, deterministic boarding initiative starts one physical link; rejected contenders retain their prior stance and weapon fire, and the battle log records reason contested_same_tick. Changing away from board begins non-instant withdrawal. */
|
|
@@ -1832,7 +1835,7 @@ export interface Commands {
|
|
|
1832
1835
|
allow_player(params: SpacemoltFacilityAllowPlayerParams, requestId?: string): Promise<MutationResult<StationConfigResponse>>;
|
|
1833
1836
|
/** Administer one of your faction's stations or outposts: rename, access control, and build policy */
|
|
1834
1837
|
ban(params: SpacemoltFacilityBanParams, requestId?: string): Promise<MutationResult<StationConfigResponse>>;
|
|
1835
|
-
/** Preview the cost and requirements to found a faction station */
|
|
1838
|
+
/** Preview the cost and requirements to found a faction station, plus the outpost founding fee */
|
|
1836
1839
|
base_cost(requestId?: string): Promise<QueryResult<BaseCostResponse>>;
|
|
1837
1840
|
/** Manage facilities at stations (production, faction, personal, sales, and more) */
|
|
1838
1841
|
browse_for_sale(params?: SpacemoltFacilityBrowseForSaleParams, requestId?: string): Promise<QueryResult<FacilityBrowseForSaleResponse>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { NotificationAchievementUnlocked, NotificationActionError, NotificationActionResult, NotificationArenaChallenge, NotificationArenaObjective, NotificationBaseDestroyed,
|
|
1
|
+
import type { NotificationAchievementUnlocked, NotificationActionError, NotificationActionResult, NotificationArenaChallenge, NotificationArenaObjective, NotificationBaseDestroyed, NotificationBattleAlert, NotificationBattleDamage, NotificationBattleEnded, NotificationBattleJoined, NotificationBattleLeft, NotificationBattleStarted, NotificationBattleUpdate, NotificationChatMessage, NotificationCloak, NotificationCompleteMission, NotificationCraftingUpdate, NotificationDroneAdrift, NotificationDroneDestroyed, NotificationDroneScan, NotificationDroneSurvey, NotificationDroneUpdate, NotificationError, NotificationExchangeFill, NotificationFacilityReclaimed, NotificationFacilityRentWarning, NotificationFactionAllianceBroken, NotificationFactionAllianceFormed, NotificationFactionAllianceProposal, NotificationFactionInvite, NotificationFactionKick, NotificationFactionMobileBaseUpdate, NotificationFactionPeaceAccepted, NotificationFactionPeaceProposal, NotificationFactionPromote, NotificationFactionWarDeclared, NotificationFactionWithdrawInvite, NotificationFleet, NotificationGiftReceived, NotificationHoldUpdate, NotificationMarketUpdate, NotificationMiningYield, NotificationObservationUpdate, NotificationOk, NotificationPersonnelUpdate, NotificationPilotlessShip, NotificationPirateDestroyed, NotificationPirateRadio, NotificationPlayerDied, NotificationPlayerKill, NotificationPrizeUpdate, NotificationRanchPoached, NotificationReconnected, NotificationRefueledBy, NotificationRepairedBy, NotificationScanDetected, NotificationServerRestartWarning, NotificationShipCaptured, NotificationShipCommissionComplete, NotificationSkillLevelUp, NotificationStationRepaired, NotificationTradeCancelled, NotificationTradeComplete, NotificationTradeDeclined, NotificationTradeOfferReceived } from './openapi/types.gen.js';
|
|
2
2
|
/** msg_type values that have a published payload schema. */
|
|
3
|
-
export type TypedNotificationType = "achievement_unlocked" | "action_error" | "action_result" | "arena_challenge" | "arena_objective" | "base_destroyed" | "
|
|
3
|
+
export type TypedNotificationType = "achievement_unlocked" | "action_error" | "action_result" | "arena_challenge" | "arena_objective" | "base_destroyed" | "battle_alert" | "battle_damage" | "battle_ended" | "battle_joined" | "battle_left" | "battle_started" | "battle_update" | "chat_message" | "cloak" | "complete_mission" | "crafting_update" | "drone_adrift" | "drone_destroyed" | "drone_scan" | "drone_survey" | "drone_update" | "error" | "exchange_fill" | "facility_reclaimed" | "facility_rent_warning" | "faction_alliance_broken" | "faction_alliance_formed" | "faction_alliance_proposal" | "faction_invite" | "faction_kick" | "faction_mobile_base_update" | "faction_peace_accepted" | "faction_peace_proposal" | "faction_promote" | "faction_war_declared" | "faction_withdraw_invite" | "fleet" | "gift_received" | "hold_update" | "market_update" | "mining_yield" | "observation_update" | "ok" | "personnel_update" | "pilotless_ship" | "pirate_destroyed" | "pirate_radio" | "player_died" | "player_kill" | "prize_update" | "ranch_poached" | "reconnected" | "refueled_by" | "repaired_by" | "scan_detected" | "server_restart_warning" | "ship_captured" | "ship_commission_complete" | "skill_level_up" | "station_repaired" | "trade_cancelled" | "trade_complete" | "trade_declined" | "trade_offer_received";
|
|
4
4
|
/** Maps a typed push msg_type to its payload type. */
|
|
5
5
|
export interface NotificationPayloads {
|
|
6
6
|
"achievement_unlocked": NotificationAchievementUnlocked;
|
|
@@ -9,7 +9,6 @@ export interface NotificationPayloads {
|
|
|
9
9
|
"arena_challenge": NotificationArenaChallenge;
|
|
10
10
|
"arena_objective": NotificationArenaObjective;
|
|
11
11
|
"base_destroyed": NotificationBaseDestroyed;
|
|
12
|
-
"base_raid_update": NotificationBaseRaidUpdate;
|
|
13
12
|
"battle_alert": NotificationBattleAlert;
|
|
14
13
|
"battle_damage": NotificationBattleDamage;
|
|
15
14
|
"battle_ended": NotificationBattleEnded;
|
|
@@ -33,10 +32,14 @@ export interface NotificationPayloads {
|
|
|
33
32
|
"faction_alliance_broken": NotificationFactionAllianceBroken;
|
|
34
33
|
"faction_alliance_formed": NotificationFactionAllianceFormed;
|
|
35
34
|
"faction_alliance_proposal": NotificationFactionAllianceProposal;
|
|
35
|
+
"faction_invite": NotificationFactionInvite;
|
|
36
|
+
"faction_kick": NotificationFactionKick;
|
|
36
37
|
"faction_mobile_base_update": NotificationFactionMobileBaseUpdate;
|
|
37
38
|
"faction_peace_accepted": NotificationFactionPeaceAccepted;
|
|
38
39
|
"faction_peace_proposal": NotificationFactionPeaceProposal;
|
|
40
|
+
"faction_promote": NotificationFactionPromote;
|
|
39
41
|
"faction_war_declared": NotificationFactionWarDeclared;
|
|
42
|
+
"faction_withdraw_invite": NotificationFactionWithdrawInvite;
|
|
40
43
|
"fleet": NotificationFleet;
|
|
41
44
|
"gift_received": NotificationGiftReceived;
|
|
42
45
|
"hold_update": NotificationHoldUpdate;
|
|
@@ -67,4 +70,4 @@ export interface NotificationPayloads {
|
|
|
67
70
|
"trade_offer_received": NotificationTradeOfferReceived;
|
|
68
71
|
}
|
|
69
72
|
/** Names of every push msg_type with a published schema, for runtime checks. */
|
|
70
|
-
export declare const TYPED_NOTIFICATION_TYPES: readonly ["achievement_unlocked", "action_error", "action_result", "arena_challenge", "arena_objective", "base_destroyed", "
|
|
73
|
+
export declare const TYPED_NOTIFICATION_TYPES: readonly ["achievement_unlocked", "action_error", "action_result", "arena_challenge", "arena_objective", "base_destroyed", "battle_alert", "battle_damage", "battle_ended", "battle_joined", "battle_left", "battle_started", "battle_update", "chat_message", "cloak", "complete_mission", "crafting_update", "drone_adrift", "drone_destroyed", "drone_scan", "drone_survey", "drone_update", "error", "exchange_fill", "facility_reclaimed", "facility_rent_warning", "faction_alliance_broken", "faction_alliance_formed", "faction_alliance_proposal", "faction_invite", "faction_kick", "faction_mobile_base_update", "faction_peace_accepted", "faction_peace_proposal", "faction_promote", "faction_war_declared", "faction_withdraw_invite", "fleet", "gift_received", "hold_update", "market_update", "mining_yield", "observation_update", "ok", "personnel_update", "pilotless_ship", "pirate_destroyed", "pirate_radio", "player_died", "player_kill", "prize_update", "ranch_poached", "reconnected", "refueled_by", "repaired_by", "scan_detected", "server_restart_warning", "ship_captured", "ship_commission_complete", "skill_level_up", "station_repaired", "trade_cancelled", "trade_complete", "trade_declined", "trade_offer_received"];
|