@valoranchi/riot-client 0.3.0 → 0.4.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.
Files changed (184) hide show
  1. package/README.md +6 -1
  2. package/dist/RiotClient.d.ts +4 -0
  3. package/dist/RiotClient.d.ts.map +1 -1
  4. package/dist/RiotClient.js +12 -3
  5. package/dist/RiotClient.js.map +1 -1
  6. package/dist/analysis/collectionValue.d.ts +4 -0
  7. package/dist/analysis/collectionValue.d.ts.map +1 -0
  8. package/dist/analysis/collectionValue.js +119 -0
  9. package/dist/analysis/collectionValue.js.map +1 -0
  10. package/dist/analysis/loadoutDiff.d.ts +6 -0
  11. package/dist/analysis/loadoutDiff.d.ts.map +1 -0
  12. package/dist/analysis/loadoutDiff.js +258 -0
  13. package/dist/analysis/loadoutDiff.js.map +1 -0
  14. package/dist/analysis/matchSync.d.ts +8 -0
  15. package/dist/analysis/matchSync.d.ts.map +1 -0
  16. package/dist/analysis/matchSync.js +66 -0
  17. package/dist/analysis/matchSync.js.map +1 -0
  18. package/dist/analysis/performanceSummary.d.ts +4 -0
  19. package/dist/analysis/performanceSummary.d.ts.map +1 -0
  20. package/dist/analysis/performanceSummary.js +184 -0
  21. package/dist/analysis/performanceSummary.js.map +1 -0
  22. package/dist/analysis/playerAssessment.d.ts +10 -0
  23. package/dist/analysis/playerAssessment.d.ts.map +1 -0
  24. package/dist/analysis/playerAssessment.js +47 -0
  25. package/dist/analysis/playerAssessment.js.map +1 -0
  26. package/dist/analysis/ratingTrend.d.ts +5 -0
  27. package/dist/analysis/ratingTrend.d.ts.map +1 -0
  28. package/dist/analysis/ratingTrend.js +70 -0
  29. package/dist/analysis/ratingTrend.js.map +1 -0
  30. package/dist/analysis/storeHistory.d.ts +6 -0
  31. package/dist/analysis/storeHistory.d.ts.map +1 -0
  32. package/dist/analysis/storeHistory.js +74 -0
  33. package/dist/analysis/storeHistory.js.map +1 -0
  34. package/dist/bin.js +3 -1
  35. package/dist/bin.js.map +1 -1
  36. package/dist/catalogue/Catalogue.d.ts.map +1 -1
  37. package/dist/catalogue/Catalogue.js.map +1 -1
  38. package/dist/catalogue/ValorantApi.d.ts.map +1 -1
  39. package/dist/catalogue/ValorantApi.js +1 -1
  40. package/dist/catalogue/ValorantApi.js.map +1 -1
  41. package/dist/cli.d.ts +8 -1
  42. package/dist/cli.d.ts.map +1 -1
  43. package/dist/cli.js +192 -19
  44. package/dist/cli.js.map +1 -1
  45. package/dist/client/AccountService.d.ts +6 -1
  46. package/dist/client/AccountService.d.ts.map +1 -1
  47. package/dist/client/AccountService.js +39 -4
  48. package/dist/client/AccountService.js.map +1 -1
  49. package/dist/client/AccountValidator.d.ts.map +1 -1
  50. package/dist/client/AccountValidator.js +9 -3
  51. package/dist/client/AccountValidator.js.map +1 -1
  52. package/dist/client/ChatValidator.d.ts.map +1 -1
  53. package/dist/client/ChatValidator.js +2 -4
  54. package/dist/client/ChatValidator.js.map +1 -1
  55. package/dist/client/ClientContext.d.ts +1 -0
  56. package/dist/client/ClientContext.d.ts.map +1 -1
  57. package/dist/client/ClientContext.js.map +1 -1
  58. package/dist/client/LiveMatchService.d.ts +1 -1
  59. package/dist/client/LiveMatchService.d.ts.map +1 -1
  60. package/dist/client/LiveMatchService.js +30 -20
  61. package/dist/client/LiveMatchService.js.map +1 -1
  62. package/dist/client/LoadoutValidator.d.ts.map +1 -1
  63. package/dist/client/LoadoutValidator.js +1 -3
  64. package/dist/client/LoadoutValidator.js.map +1 -1
  65. package/dist/client/MatchService.d.ts +17 -1
  66. package/dist/client/MatchService.d.ts.map +1 -1
  67. package/dist/client/MatchService.js +123 -2
  68. package/dist/client/MatchService.js.map +1 -1
  69. package/dist/client/MatchValidator.d.ts.map +1 -1
  70. package/dist/client/MatchValidator.js.map +1 -1
  71. package/dist/client/PartyService.d.ts.map +1 -1
  72. package/dist/client/PartyService.js +3 -1
  73. package/dist/client/PartyService.js.map +1 -1
  74. package/dist/client/PartyValidator.d.ts.map +1 -1
  75. package/dist/client/PartyValidator.js +1 -2
  76. package/dist/client/PartyValidator.js.map +1 -1
  77. package/dist/client/SocialService.d.ts.map +1 -1
  78. package/dist/client/SocialService.js +4 -5
  79. package/dist/client/SocialService.js.map +1 -1
  80. package/dist/client/StoreService.d.ts +5 -1
  81. package/dist/client/StoreService.d.ts.map +1 -1
  82. package/dist/client/StoreService.js +36 -2
  83. package/dist/client/StoreService.js.map +1 -1
  84. package/dist/client/StoreValidator.d.ts.map +1 -1
  85. package/dist/client/StoreValidator.js +4 -2
  86. package/dist/client/StoreValidator.js.map +1 -1
  87. package/dist/client/api.d.ts +25 -1
  88. package/dist/client/api.d.ts.map +1 -1
  89. package/dist/collection/CustomGameConfigsBuilder.d.ts.map +1 -1
  90. package/dist/collection/CustomGameConfigsBuilder.js.map +1 -1
  91. package/dist/collection/LiveMatchBuilder.d.ts +2 -2
  92. package/dist/collection/LiveMatchBuilder.d.ts.map +1 -1
  93. package/dist/collection/LiveMatchBuilder.js +10 -8
  94. package/dist/collection/LiveMatchBuilder.js.map +1 -1
  95. package/dist/collection/LoadoutBuilder.d.ts.map +1 -1
  96. package/dist/collection/LoadoutBuilder.js +1 -1
  97. package/dist/collection/LoadoutBuilder.js.map +1 -1
  98. package/dist/collection/LoadoutWriter.d.ts.map +1 -1
  99. package/dist/collection/LoadoutWriter.js +0 -1
  100. package/dist/collection/LoadoutWriter.js.map +1 -1
  101. package/dist/collection/MmrBuilder.d.ts +1 -1
  102. package/dist/collection/MmrBuilder.d.ts.map +1 -1
  103. package/dist/collection/MmrBuilder.js +5 -2
  104. package/dist/collection/MmrBuilder.js.map +1 -1
  105. package/dist/collection/PlayerSettingsBuilder.d.ts.map +1 -1
  106. package/dist/collection/PlayerSettingsBuilder.js +1 -3
  107. package/dist/collection/PlayerSettingsBuilder.js.map +1 -1
  108. package/dist/collection/RankFit.d.ts +11 -0
  109. package/dist/collection/RankFit.d.ts.map +1 -0
  110. package/dist/collection/RankFit.js +56 -0
  111. package/dist/collection/RankFit.js.map +1 -0
  112. package/dist/index.d.ts +11 -2
  113. package/dist/index.d.ts.map +1 -1
  114. package/dist/index.js +10 -1
  115. package/dist/index.js.map +1 -1
  116. package/dist/local/ChatApi.d.ts.map +1 -1
  117. package/dist/local/ChatApi.js +3 -1
  118. package/dist/local/ChatApi.js.map +1 -1
  119. package/dist/model/index.d.ts +163 -0
  120. package/dist/model/index.d.ts.map +1 -1
  121. package/dist/riot/ResponseCache.d.ts.map +1 -1
  122. package/dist/riot/ResponseCache.js +1 -3
  123. package/dist/riot/ResponseCache.js.map +1 -1
  124. package/dist/riot/RiotApi.d.ts.map +1 -1
  125. package/dist/riot/RiotApi.js.map +1 -1
  126. package/dist/riot/types.d.ts.map +1 -1
  127. package/dist/serve/index.d.ts +7 -0
  128. package/dist/serve/index.d.ts.map +1 -0
  129. package/dist/serve/index.js +6 -0
  130. package/dist/serve/index.js.map +1 -0
  131. package/dist/serve/indexHtml.d.ts +2 -0
  132. package/dist/serve/indexHtml.d.ts.map +1 -0
  133. package/dist/serve/indexHtml.js +36 -0
  134. package/dist/serve/indexHtml.js.map +1 -0
  135. package/dist/serve/openapi.d.ts +2 -0
  136. package/dist/serve/openapi.d.ts.map +1 -0
  137. package/dist/serve/openapi.js +114 -0
  138. package/dist/serve/openapi.js.map +1 -0
  139. package/dist/serve/routes.d.ts +7 -0
  140. package/dist/serve/routes.d.ts.map +1 -0
  141. package/dist/serve/routes.js +1207 -0
  142. package/dist/serve/routes.js.map +1 -0
  143. package/dist/serve/server.d.ts +6 -0
  144. package/dist/serve/server.d.ts.map +1 -0
  145. package/dist/serve/server.js +149 -0
  146. package/dist/serve/server.js.map +1 -0
  147. package/dist/serve/sse.d.ts +4 -0
  148. package/dist/serve/sse.d.ts.map +1 -0
  149. package/dist/serve/sse.js +89 -0
  150. package/dist/serve/sse.js.map +1 -0
  151. package/dist/serve/types.d.ts +24 -0
  152. package/dist/serve/types.d.ts.map +1 -0
  153. package/dist/serve/types.js +2 -0
  154. package/dist/serve/types.js.map +1 -0
  155. package/dist/watch/AsyncQueue.d.ts +13 -0
  156. package/dist/watch/AsyncQueue.d.ts.map +1 -0
  157. package/dist/watch/AsyncQueue.js +50 -0
  158. package/dist/watch/AsyncQueue.js.map +1 -0
  159. package/dist/watch/FriendsWatcher.d.ts +26 -0
  160. package/dist/watch/FriendsWatcher.d.ts.map +1 -0
  161. package/dist/watch/FriendsWatcher.js +152 -0
  162. package/dist/watch/FriendsWatcher.js.map +1 -0
  163. package/dist/watch/MatchWatcher.d.ts +44 -0
  164. package/dist/watch/MatchWatcher.d.ts.map +1 -0
  165. package/dist/watch/MatchWatcher.js +272 -0
  166. package/dist/watch/MatchWatcher.js.map +1 -0
  167. package/dist/watch/index.d.ts +20 -0
  168. package/dist/watch/index.d.ts.map +1 -0
  169. package/dist/watch/index.js +20 -0
  170. package/dist/watch/index.js.map +1 -0
  171. package/dist/watch/types.d.ts +98 -0
  172. package/dist/watch/types.d.ts.map +1 -0
  173. package/dist/watch/types.js +2 -0
  174. package/dist/watch/types.js.map +1 -0
  175. package/package.json +17 -5
  176. package/schema/CollectionValue.json +153 -0
  177. package/schema/LiveMatch.json +8 -1
  178. package/schema/LoadoutDiff.json +73 -0
  179. package/schema/MatchSyncResult.json +54 -0
  180. package/schema/Mmr.json +38 -1
  181. package/schema/PerformanceSummary.json +284 -0
  182. package/schema/PlayerAssessment.json +48 -0
  183. package/schema/RatingTrend.json +107 -0
  184. package/schema/StoreHistory.json +61 -0
@@ -1 +1 @@
1
- {"version":3,"file":"ValorantApi.js","sourceRoot":"","sources":["../../src/catalogue/ValorantApi.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAmC3C,MAAM,OAAO,oBAAoB;IACvB,aAAa,GAAkB,IAAI,CAAC;IAC3B,UAAU,GAAG,IAAI,GAAG,EAAqB,CAAC;IAE3D,UAAU;QACR,OAAO,IAAI,CAAC,aAAa,CAAC;IAC5B,CAAC;IAED,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,CAAwB,WAAW,EAAE,QAAQ,CAAC;YAChE,IAAI,CAAC,aAAa,CAAuB,UAAU,EAAE,QAAQ,CAAC;SAC/D,CAAC,CAAC;QACH,MAAM,UAAU,GAAG,YAAY,CAAC,IAAI,IAAI,EAAE,CAAC;QAC3C,MAAM,SAAS,GAAG,UAAU,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;QACpD,OAAO;YACL,KAAK,EAAE,SAAS,EAAE,KAAK,IAAI,EAAE;YAC7B,OAAO,EAAE,UAAU,CAAC,IAAI;YACxB,YAAY,EAAE,UAAU,CAAC,IAAI;YAC7B,SAAS,EAAE,YAAY,CAAC,IAAI;YAC5B,QAAQ,EAAE,WAAW,CAAC,IAAI;SAC3B,CAAC;IACJ,CAAC;IAEO,KAAK,CAAC,aAAa,CAAI,QAAgB,EAAE,QAAgB;QAC/D,MAAM,GAAG,GAAG,+BAA+B,QAAQ,aAAa,kBAAkB,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC/F,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAiB,GAAG,CAAC,CAAC;IAC/C,CAAC;CACF"}
package/dist/cli.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { RiotClient } from "./RiotClient.js";
2
- export declare const USAGE = "Usage: riotclient <command> [options]\n\nAccount:\n whoami Print signed-in player profile and region\n owned-items Print owned inventory items\n loadout Print currently equipped loadout\n wallet Print VP, Radianite, and Kingdom Credits balances\n xp Print account level, XP progression and recent match XP history\n contracts Print progression across agent, battlepass and event contracts\n missions Print active daily and weekly missions and objectives\n penalties Print active penalties and restrictions\n favourites Print favorited weapon skins\n session Print current client session loop state and playtime\n config Print shared client configuration mapping\n client Print client identity, locale, region, and Valorant running state\n settings Print cloud player settings (--raw for unprocessed dump)\n settings-save Save player settings from JSON file (<file.json>, requires --yes --confirm)\n equip Equip skins, buddies, sprays, card, title, border, flex (dry-run, --yes to apply)\n equip-collection Equip a collection of skins (<skinUuid,...>) (dry-run, --yes to apply)\n contract-activate Activate an agent contract (<uuid>) (dry-run, --yes to apply)\n favourite-add Add skin to favourites (<skin>) (dry-run, --yes to apply)\n favourite-remove Remove skin from favourites (<skin>) (dry-run, --yes to apply)\n privacy Update account privacy toggles (--badge on|off, --leaderboard on|off)\n\nSocial:\n friends Print friends roster and presence\n friend-requests Print incoming and outgoing friend requests\n blocked Print blocked players\n conversations Print whisper and match chat conversations\n messages Print chat messages (filter with --cid <id>)\n participants Print chat participants (filter with --cid <id>)\n send Send chat message (--to <puuid|name#tag|cid> --text <msg>)\n friend-request Send friend request (<name#tag>)\n friend-accept Accept friend request (<puuid>)\n friend-decline Decline friend request (<puuid>)\n friend-cancel Cancel friend request (<puuid>)\n friend-remove Remove friend (<puuid>)\n block Block player (<puuid|name#tag>)\n unblock Unblock player (<puuid>)\n\nStore:\n store Print storefront (daily, night market, bundles, accessories)\n offers Print full item offers catalog and pricing\n order <id> Print store order details\n night-market-reveal Reveal night market offers (dry-run, --yes to apply)\n buy Purchase offer or bundle (--offer <id> | --bundle <id>, requires --yes --confirm)\n\nMatches:\n matches Print recent match history summaries\n match <id> Print full match details by ID\n mmr Print current rank, rating, and MMR breakdown\n rank-history Print competitive rating adjustments and tier changes\n live Print live pregame or in-game lobby status and loadouts\n matches-for <puuid> Print recent match history summaries for player\n mmr-for <puuid> Print rank, rating, and MMR for player\n rank-history-for <puuid> Print competitive updates for player\n leaderboard Print competitive leaderboard [--season] [--start] [--size] [--query]\n content Print active act, episode and live events\n premier Print premier eligibility, roster, and season info\n agent-select Select an agent in pregame (<uuid|name>) (dry-run, --yes to apply)\n agent-lock Lock in an agent in pregame (<uuid|name>) (dry-run, --yes to apply)\n dodge Dodge pregame agent select (requires --yes --confirm)\n leave-match Leave active in-game match (requires --yes --confirm)\n\nParty:\n party Print current party details and members\n queues Print matchmaking queue configurations\n custom-game-configs Print custom game configuration options\n party-invite Invite player to party (<name#tag>)\n party-kick Kick member from party (<puuid>)\n party-promote Promote member to party owner (<puuid>)\n party-code Generate or revoke party invite code [--revoke]\n party-join Join party by invite code or party ID (<partyId|code>)\n party-invites Print incoming party invites\n party-requests Print incoming party join requests\n party-decline-invite Decline party invite (<id>) (dry-run, --yes to apply)\n party-request Request to join party (<partyId>) (dry-run, --yes to apply)\n party-decline-request Decline party join request (<id>) (dry-run, --yes to apply)\n custom-game Convert party into a custom game (dry-run, --yes to apply)\n custom-game-settings Configure custom game (--map <name> --mode <name> [--server <id>] [--rule k=v...])\n custom-game-team Set member custom game team (<puuid> <team>) (dry-run, --yes to apply)\n custom-game-start Start custom game match (dry-run, --yes to apply)\n custom-game-balance Balance custom game teams (dry-run, --yes to apply)\n party-default Set party default queue (<queue>) (dry-run, --yes to apply)\n party-servers Set preferred game servers (<id,...>) (dry-run, --yes to apply)\n party-moderator Set member moderator status (<puuid> on|off) (dry-run, --yes to apply)\n party-refresh Refresh party member pings and identity (dry-run, --yes to apply)\n party-ready Set party ready state (on|off)\n party-queue Change party queue (<queue>)\n party-access Set party accessibility (open|closed)\n party-start Start party matchmaking\n party-stop Stop party matchmaking\n party-leave Leave current party\n\nRaw (unsupported):\n local Send raw request to local Riot client API (<get|post|put|delete> <path> [--body json])\n riot Send raw request to remote Riot game servers (<get|post|put|delete> <url> [--body json])\n\nEvents:\n watch Stream real-time events as JSON lines until interrupted\n\nOptions:\n --yes Execute write command (default is dry-run)\n --confirm Confirm write action (required with buy, dodge, leave-match, settings-save)\n --offer <id> Store offer ID to purchase\n --bundle <id> Store bundle ID to purchase\n --badge <on|off> Hide or show act rank badge\n --leaderboard <on|off> Anonymize or reveal leaderboard presence\n --season <uuid> Season ID for leaderboard\n --start <n> Leaderboard starting index\n --size <n> Leaderboard page size (max 510)\n --query <text> Leaderboard player search query\n --revoke Revoke party invite code (used with party-code)\n --to <target> Message recipient (puuid, name#tag, or cid)\n --text <msg> Message text\n --gun <spec> Gun to equip: <weapon>=<skin>[:level[:chroma]] (repeatable)\n --buddy <spec> Buddy to equip: <weapon>=<buddy|none> (repeatable)\n --spray <spec> Spray to equip: <slot>=<uuid|none> (repeatable)\n --card <uuid> Player card UUID\n --title <uuid> Player title UUID\n --flex <uuid|none> Flex item UUID or none\n --border <uuid> Level border UUID\n --incognito <on|off> Enable or disable incognito\n --hide-level <on|off> Hide or show account level\n --count <n> Number of matches or rank history entries to fetch\n --queue <queue> Queue filter (e.g. competitive, unrated)\n --ranks Fetch MMR and rank for each player in live match\n --no-loadouts Skip fetching player loadouts in live match\n --map <name> Map name or path for custom game\n --mode <name> Game mode name or path for custom game\n --server <id> Server pod ID for custom game\n --rule <spec> Game rule override: <name>=<value> (repeatable)\n --body <json> JSON request body for local and riot raw commands\n --only <events> Comma-separated list of event names to print\n --raw Include raw client event frames or unformatted settings\n --cid <id> Conversation ID for filtering messages or participants\n --language <lang> Catalogue language (default: en-US)\n --cache <seconds> Reuse Riot responses younger than this many seconds\n --pretty Pretty-print JSON output\n --help Show usage instructions\n --version Show version number\n";
2
+ export declare const USAGE = "Usage: riotclient <command> [options]\n\nAccount:\n whoami Print signed-in player profile and region\n owned-items Print owned inventory items\n collection-value Calculate estimated VP and Radianite value of owned collection\n loadout Print currently equipped loadout\n wallet Print VP, Radianite, and Kingdom Credits balances\n xp Print account level, XP progression and recent match XP history\n contracts Print progression across agent, battlepass and event contracts\n missions Print active daily and weekly missions and objectives\n penalties Print active penalties and restrictions\n favourites Print favorited weapon skins\n session Print current client session loop state and playtime\n config Print shared client configuration mapping\n client Print client identity, locale, region, and Valorant running state\n settings Print cloud player settings (--raw for unprocessed dump)\n settings-save Save player settings from JSON file (<file.json>, requires --yes --confirm)\n equip Equip skins, buddies, sprays, card, title, border, flex (dry-run, --yes to apply)\n equip-collection Equip a collection of skins (<skinUuid,...>) (dry-run, --yes to apply)\n loadout-export Export current loadout as a preset JSON\n loadout-diff Compare current loadout against preset JSON file (<preset.json>)\n loadout-apply Apply loadout preset from JSON file (<preset.json>, dry-run, --yes to apply)\n contract-activate Activate an agent contract (<uuid>) (dry-run, --yes to apply)\n favourite-add Add skin to favourites (<skin>) (dry-run, --yes to apply)\n favourite-remove Remove skin from favourites (<skin>) (dry-run, --yes to apply)\n privacy Update account privacy toggles (--badge on|off, --leaderboard on|off)\n\nSocial:\n friends Print friends roster and presence\n friend-requests Print incoming and outgoing friend requests\n blocked Print blocked players\n conversations Print whisper and match chat conversations\n messages Print chat messages (filter with --cid <id>)\n participants Print chat participants (filter with --cid <id>)\n send Send chat message (--to <puuid|name#tag|cid> --text <msg>)\n friend-request Send friend request (<name#tag>)\n friend-accept Accept friend request (<puuid>)\n friend-decline Decline friend request (<puuid>)\n friend-cancel Cancel friend request (<puuid>)\n friend-remove Remove friend (<puuid>)\n block Block player (<puuid|name#tag>)\n unblock Unblock player (<puuid>)\n\nStore:\n store Print storefront (daily, night market, bundles, accessories)\n store-history Print recorded daily store rotations [--days <n>]\n store-seen Print when a skin was last seen in daily store (<skin>)\n offers Print full item offers catalog and pricing\n order <id> Print store order details\n night-market-reveal Reveal night market offers (dry-run, --yes to apply)\n buy Purchase offer or bundle (--offer <id> | --bundle <id>, requires --yes --confirm)\n\nMatches:\n matches Print recent match history summaries\n matches-sync Synchronize match history to local cache [--pages <n>]\n match <id> Print full match details by ID\n mmr Print current rank, rating, and MMR breakdown\n rank-history Print competitive rating adjustments and tier changes\n live Print live pregame or in-game lobby status and loadouts\n matches-for <puuid> Print recent match history summaries for player\n mmr-for <puuid> Print rank, rating, and MMR for player\n rank-history-for <puuid> Print competitive updates for player\n leaderboard Print competitive leaderboard [--season] [--start] [--size] [--query]\n content Print active act, episode and live events\n premier Print premier eligibility, roster, and season info\n trend Print competitive rating streak, net RR gains, and climbing pace\n summary Print player performance summary across recent matches [--count n] [--queue q]\n assess [puuid] Assess player rank anomalies, streaks, and warning flags\n agent-select Select an agent in pregame (<uuid|name>) (dry-run, --yes to apply)\n agent-lock Lock in an agent in pregame (<uuid|name>) (dry-run, --yes to apply)\n dodge Dodge pregame agent select (requires --yes --confirm)\n leave-match Leave active in-game match (requires --yes --confirm)\n\nParty:\n party Print current party details and members\n queues Print matchmaking queue configurations\n custom-game-configs Print custom game configuration options\n party-invite Invite player to party (<name#tag>)\n party-kick Kick member from party (<puuid>)\n party-promote Promote member to party owner (<puuid>)\n party-code Generate or revoke party invite code [--revoke]\n party-join Join party by invite code or party ID (<partyId|code>)\n party-invites Print incoming party invites\n party-requests Print incoming party join requests\n party-decline-invite Decline party invite (<id>) (dry-run, --yes to apply)\n party-request Request to join party (<partyId>) (dry-run, --yes to apply)\n party-decline-request Decline party join request (<id>) (dry-run, --yes to apply)\n custom-game Convert party into a custom game (dry-run, --yes to apply)\n custom-game-settings Configure custom game (--map <name> --mode <name> [--server <id>] [--rule k=v...])\n custom-game-team Set member custom game team (<puuid> <team>) (dry-run, --yes to apply)\n custom-game-start Start custom game match (dry-run, --yes to apply)\n custom-game-balance Balance custom game teams (dry-run, --yes to apply)\n party-default Set party default queue (<queue>) (dry-run, --yes to apply)\n party-servers Set preferred game servers (<id,...>) (dry-run, --yes to apply)\n party-moderator Set member moderator status (<puuid> on|off) (dry-run, --yes to apply)\n party-refresh Refresh party member pings and identity (dry-run, --yes to apply)\n party-ready Set party ready state (on|off)\n party-queue Change party queue (<queue>)\n party-access Set party accessibility (open|closed)\n party-start Start party matchmaking\n party-stop Stop party matchmaking\n party-leave Leave current party\n\nRaw (unsupported):\n local Send raw request to local Riot client API (<get|post|put|delete> <path> [--body json])\n riot Send raw request to remote Riot game servers (<get|post|put|delete> <url> [--body json])\n\nEvents:\n watch Stream real-time events as JSON lines until interrupted\n watch-match Stream match lifecycle events until interrupted\n watch-friends Stream friend activity and presence events until interrupted\n\nServer:\n serve Start local HTTP server with SSE events and OpenAPI docs [--port 47800] [--host 127.0.0.1] [--allow-remote]\n\nOptions:\n --yes Execute write command (default is dry-run)\n --confirm Confirm write action (required with buy, dodge, leave-match, settings-save)\n --offer <id> Store offer ID to purchase\n --bundle <id> Store bundle ID to purchase\n --badge <on|off> Hide or show act rank badge\n --leaderboard <on|off> Anonymize or reveal leaderboard presence\n --season <uuid> Season ID for leaderboard\n --start <n> Leaderboard starting index\n --size <n> Leaderboard page size (max 510)\n --query <text> Leaderboard player search query\n --revoke Revoke party invite code (used with party-code)\n --to <target> Message recipient (puuid, name#tag, or cid)\n --text <msg> Message text\n --gun <spec> Gun to equip: <weapon>=<skin>[:level[:chroma]] (repeatable)\n --buddy <spec> Buddy to equip: <weapon>=<buddy|none> (repeatable)\n --spray <spec> Spray to equip: <slot>=<uuid|none> (repeatable)\n --card <uuid> Player card UUID\n --title <uuid> Player title UUID\n --flex <uuid|none> Flex item UUID or none\n --border <uuid> Level border UUID\n --incognito <on|off> Enable or disable incognito\n --hide-level <on|off> Hide or show account level\n --count <n> Number of matches or rank history entries to fetch\n --queue <queue> Queue filter (e.g. competitive, unrated)\n --ranks Fetch MMR and rank for each player in live match\n --no-loadouts Skip fetching player loadouts in live match\n --map <name> Map name or path for custom game\n --mode <name> Game mode name or path for custom game\n --server <id> Server pod ID for custom game\n --rule <spec> Game rule override: <name>=<value> (repeatable)\n --body <json> JSON request body for local and riot raw commands\n --only <events> Comma-separated list of event names to print\n --raw Include raw client event frames or unformatted settings\n --cid <id> Conversation ID for filtering messages or participants\n --language <lang> Catalogue language (default: en-US)\n --cache <seconds> Reuse Riot responses younger than this many seconds\n --port <n> Port to bind HTTP server (default: 47800)\n --host <ip> Host address to bind HTTP server (default: 127.0.0.1)\n --allow-remote Allow binding HTTP server to non-loopback address\n --pretty Pretty-print JSON output\n --help Show usage instructions\n --version Show version number\n";
3
3
  export declare function exitCodeForError(error: unknown): number;
4
4
  export declare function formatError(error: unknown): {
5
5
  error: {
@@ -14,5 +14,12 @@ export declare function runWatch(client: RiotClient, options?: {
14
14
  only?: string;
15
15
  raw?: boolean;
16
16
  }): Promise<number>;
17
+ export declare function runWatchMatch(client: RiotClient): Promise<number>;
18
+ export declare function runWatchFriends(client: RiotClient): Promise<number>;
19
+ export declare function runServe(client: RiotClient, options?: {
20
+ port?: number;
21
+ host?: string;
22
+ allowRemote?: boolean;
23
+ }): Promise<number>;
17
24
  export declare function runCli(args: string[]): Promise<number>;
18
25
  //# sourceMappingURL=cli.d.ts.map
package/dist/cli.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAA6C,MAAM,iBAAiB,CAAC;AAExF,eAAO,MAAM,KAAK,krQA6IjB,CAAC;AAeF,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAKvD;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,OAAO,GAAG;IAC3C,KAAK,EAAE;QACL,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;QAChB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACnC,CAAC;CACH,CA0BA;AAED,wBAAgB,eAAe,CAC7B,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,OAAO,EACb,EAAE,GAAE,MAAiC,GACpC,MAAM,CAMR;AAiBD,wBAAsB,QAAQ,CAC5B,MAAM,EAAE,UAAU,EAClB,OAAO,GAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,GAC7C,OAAO,CAAC,MAAM,CAAC,CAqCjB;AAusBD,wBAAsB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAwG5D"}
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAA6C,MAAM,iBAAiB,CAAC;AAExF,eAAO,MAAM,KAAK,68SA+JjB,CAAC;AAwBF,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAKvD;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,OAAO,GAAG;IAC3C,KAAK,EAAE;QACL,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;QAChB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACnC,CAAC;CACH,CA0BA;AAED,wBAAgB,eAAe,CAC7B,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,OAAO,EACb,EAAE,GAAE,MAAiC,GACpC,MAAM,CAMR;AAiBD,wBAAsB,QAAQ,CAC5B,MAAM,EAAE,UAAU,EAClB,OAAO,GAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,GAC7C,OAAO,CAAC,MAAM,CAAC,CAqCjB;AAED,wBAAsB,aAAa,CAAC,MAAM,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,CAqBvE;AAED,wBAAsB,eAAe,CAAC,MAAM,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,CAqBzE;AAED,wBAAsB,QAAQ,CAC5B,MAAM,EAAE,UAAU,EAClB,OAAO,GAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAO,GACpE,OAAO,CAAC,MAAM,CAAC,CAiBjB;AAmzBD,wBAAsB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CA8H5D"}
package/dist/cli.js CHANGED
@@ -7,6 +7,7 @@ export const USAGE = `Usage: riotclient <command> [options]
7
7
  Account:
8
8
  whoami Print signed-in player profile and region
9
9
  owned-items Print owned inventory items
10
+ collection-value Calculate estimated VP and Radianite value of owned collection
10
11
  loadout Print currently equipped loadout
11
12
  wallet Print VP, Radianite, and Kingdom Credits balances
12
13
  xp Print account level, XP progression and recent match XP history
@@ -21,6 +22,9 @@ Account:
21
22
  settings-save Save player settings from JSON file (<file.json>, requires --yes --confirm)
22
23
  equip Equip skins, buddies, sprays, card, title, border, flex (dry-run, --yes to apply)
23
24
  equip-collection Equip a collection of skins (<skinUuid,...>) (dry-run, --yes to apply)
25
+ loadout-export Export current loadout as a preset JSON
26
+ loadout-diff Compare current loadout against preset JSON file (<preset.json>)
27
+ loadout-apply Apply loadout preset from JSON file (<preset.json>, dry-run, --yes to apply)
24
28
  contract-activate Activate an agent contract (<uuid>) (dry-run, --yes to apply)
25
29
  favourite-add Add skin to favourites (<skin>) (dry-run, --yes to apply)
26
30
  favourite-remove Remove skin from favourites (<skin>) (dry-run, --yes to apply)
@@ -44,6 +48,8 @@ Social:
44
48
 
45
49
  Store:
46
50
  store Print storefront (daily, night market, bundles, accessories)
51
+ store-history Print recorded daily store rotations [--days <n>]
52
+ store-seen Print when a skin was last seen in daily store (<skin>)
47
53
  offers Print full item offers catalog and pricing
48
54
  order <id> Print store order details
49
55
  night-market-reveal Reveal night market offers (dry-run, --yes to apply)
@@ -51,6 +57,7 @@ Store:
51
57
 
52
58
  Matches:
53
59
  matches Print recent match history summaries
60
+ matches-sync Synchronize match history to local cache [--pages <n>]
54
61
  match <id> Print full match details by ID
55
62
  mmr Print current rank, rating, and MMR breakdown
56
63
  rank-history Print competitive rating adjustments and tier changes
@@ -61,6 +68,9 @@ Matches:
61
68
  leaderboard Print competitive leaderboard [--season] [--start] [--size] [--query]
62
69
  content Print active act, episode and live events
63
70
  premier Print premier eligibility, roster, and season info
71
+ trend Print competitive rating streak, net RR gains, and climbing pace
72
+ summary Print player performance summary across recent matches [--count n] [--queue q]
73
+ assess [puuid] Assess player rank anomalies, streaks, and warning flags
64
74
  agent-select Select an agent in pregame (<uuid|name>) (dry-run, --yes to apply)
65
75
  agent-lock Lock in an agent in pregame (<uuid|name>) (dry-run, --yes to apply)
66
76
  dodge Dodge pregame agent select (requires --yes --confirm)
@@ -102,6 +112,11 @@ Raw (unsupported):
102
112
 
103
113
  Events:
104
114
  watch Stream real-time events as JSON lines until interrupted
115
+ watch-match Stream match lifecycle events until interrupted
116
+ watch-friends Stream friend activity and presence events until interrupted
117
+
118
+ Server:
119
+ serve Start local HTTP server with SSE events and OpenAPI docs [--port 47800] [--host 127.0.0.1] [--allow-remote]
105
120
 
106
121
  Options:
107
122
  --yes Execute write command (default is dry-run)
@@ -140,11 +155,22 @@ Options:
140
155
  --cid <id> Conversation ID for filtering messages or participants
141
156
  --language <lang> Catalogue language (default: en-US)
142
157
  --cache <seconds> Reuse Riot responses younger than this many seconds
158
+ --port <n> Port to bind HTTP server (default: 47800)
159
+ --host <ip> Host address to bind HTTP server (default: 127.0.0.1)
160
+ --allow-remote Allow binding HTTP server to non-loopback address
143
161
  --pretty Pretty-print JSON output
144
162
  --help Show usage instructions
145
163
  --version Show version number
146
164
  `;
147
- const packageJson = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf-8"));
165
+ function getPackageVersion() {
166
+ try {
167
+ return JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf-8")).version;
168
+ }
169
+ catch {
170
+ return "0.3.0";
171
+ }
172
+ }
173
+ const PACKAGE_VERSION = getPackageVersion();
148
174
  const ERROR_EXIT_CODES = {
149
175
  RIOT_CLIENT_NOT_RUNNING: 2,
150
176
  RIOT_CLIENT_NOT_READY: 3,
@@ -240,6 +266,66 @@ export async function runWatch(client, options = {}) {
240
266
  await client.close();
241
267
  return 0;
242
268
  }
269
+ export async function runWatchMatch(client) {
270
+ const watcher = client.watch.match();
271
+ const onSignal = () => {
272
+ process.off("SIGINT", onSignal);
273
+ process.off("SIGTERM", onSignal);
274
+ watcher.stop();
275
+ };
276
+ process.on("SIGINT", onSignal);
277
+ process.on("SIGTERM", onSignal);
278
+ try {
279
+ for await (const item of watcher) {
280
+ process.stdout.write(`${JSON.stringify(item)}\n`);
281
+ }
282
+ }
283
+ finally {
284
+ process.off("SIGINT", onSignal);
285
+ process.off("SIGTERM", onSignal);
286
+ watcher.stop();
287
+ await client.close();
288
+ }
289
+ return 0;
290
+ }
291
+ export async function runWatchFriends(client) {
292
+ const watcher = client.watch.friends();
293
+ const onSignal = () => {
294
+ process.off("SIGINT", onSignal);
295
+ process.off("SIGTERM", onSignal);
296
+ watcher.stop();
297
+ };
298
+ process.on("SIGINT", onSignal);
299
+ process.on("SIGTERM", onSignal);
300
+ try {
301
+ for await (const item of watcher) {
302
+ process.stdout.write(`${JSON.stringify(item)}\n`);
303
+ }
304
+ }
305
+ finally {
306
+ process.off("SIGINT", onSignal);
307
+ process.off("SIGTERM", onSignal);
308
+ watcher.stop();
309
+ await client.close();
310
+ }
311
+ return 0;
312
+ }
313
+ export async function runServe(client, options = {}) {
314
+ const server = await client.serve(options);
315
+ process.stdout.write(`Riot Client HTTP server listening on ${server.url}\n`);
316
+ await new Promise((resolve) => {
317
+ const onSignal = () => {
318
+ process.off("SIGINT", onSignal);
319
+ process.off("SIGTERM", onSignal);
320
+ resolve();
321
+ };
322
+ process.on("SIGINT", onSignal);
323
+ process.on("SIGTERM", onSignal);
324
+ });
325
+ await server.close();
326
+ await client.close();
327
+ return 0;
328
+ }
243
329
  const UNKNOWN_COMMAND = Symbol("UNKNOWN_COMMAND");
244
330
  function parseTarget(to) {
245
331
  if (to.includes("#"))
@@ -347,6 +433,8 @@ async function executeStandardCommand(client, command, options) {
347
433
  return client.account.whoami();
348
434
  case "owned-items":
349
435
  return client.account.ownedItems({ language: options?.language });
436
+ case "collection-value":
437
+ return client.account.collectionValue();
350
438
  case "loadout":
351
439
  return client.account.loadout();
352
440
  case "wallet":
@@ -377,6 +465,12 @@ async function executeStandardCommand(client, command, options) {
377
465
  return client.social.messages(options?.cid);
378
466
  case "store":
379
467
  return client.store.current({ language: options?.language });
468
+ case "store-history":
469
+ return client.store.history({ days: options?.days });
470
+ case "store-seen": {
471
+ const skin = requirePositional(pos, 1, "Usage: riotclient store-seen <skin>");
472
+ return client.store.seen(skin);
473
+ }
380
474
  case "offers":
381
475
  return client.store.offers();
382
476
  case "order":
@@ -399,6 +493,8 @@ async function executeGameCommand(client, command, options) {
399
493
  switch (command) {
400
494
  case "matches":
401
495
  return client.matches.list({ count: options?.count, queue: options?.queue });
496
+ case "matches-sync":
497
+ return client.matches.sync({ maxPages: options?.pages });
402
498
  case "match":
403
499
  if (!options?.matchId)
404
500
  throw new Error("Missing match ID: riotclient match <id>");
@@ -426,6 +522,12 @@ async function executeGameCommand(client, command, options) {
426
522
  return client.matches.content();
427
523
  case "premier":
428
524
  return client.matches.premier();
525
+ case "trend":
526
+ return client.matches.trend({ count: options?.count });
527
+ case "summary":
528
+ return client.matches.summary({ count: options?.count, queue: options?.queue });
529
+ case "assess":
530
+ return client.matches.assess(pos[1]);
429
531
  case "party":
430
532
  return client.party.current();
431
533
  case "queues":
@@ -445,23 +547,33 @@ async function executeSocialWriteCommand(client, command, yes, pos, vals) {
445
547
  throw new ValidationError("invalid-argument", "Usage: riotclient send --to <puuid|name#tag|cid> --text <message>");
446
548
  }
447
549
  const target = parseTarget(to);
448
- return yes ? client.social.sendMessage(target, text) : client.social.validateSendMessage(target, text);
550
+ return yes
551
+ ? client.social.sendMessage(target, text)
552
+ : client.social.validateSendMessage(target, text);
449
553
  }
450
554
  case "friend-request": {
451
555
  const riotId = requirePositional(pos, 1, "Usage: riotclient friend-request <name#tag>");
452
- return yes ? client.social.sendFriendRequest(riotId) : client.social.validateSendFriendRequest(riotId);
556
+ return yes
557
+ ? client.social.sendFriendRequest(riotId)
558
+ : client.social.validateSendFriendRequest(riotId);
453
559
  }
454
560
  case "friend-accept": {
455
561
  const puuid = requirePositional(pos, 1, "Usage: riotclient friend-accept <puuid>");
456
- return yes ? client.social.acceptFriendRequest(puuid) : client.social.validateAcceptFriendRequest(puuid);
562
+ return yes
563
+ ? client.social.acceptFriendRequest(puuid)
564
+ : client.social.validateAcceptFriendRequest(puuid);
457
565
  }
458
566
  case "friend-decline": {
459
567
  const puuid = requirePositional(pos, 1, "Usage: riotclient friend-decline <puuid>");
460
- return yes ? client.social.declineFriendRequest(puuid) : client.social.validateDeclineFriendRequest(puuid);
568
+ return yes
569
+ ? client.social.declineFriendRequest(puuid)
570
+ : client.social.validateDeclineFriendRequest(puuid);
461
571
  }
462
572
  case "friend-cancel": {
463
573
  const puuid = requirePositional(pos, 1, "Usage: riotclient friend-cancel <puuid>");
464
- return yes ? client.social.cancelFriendRequest(puuid) : client.social.validateCancelFriendRequest(puuid);
574
+ return yes
575
+ ? client.social.cancelFriendRequest(puuid)
576
+ : client.social.validateCancelFriendRequest(puuid);
465
577
  }
466
578
  case "friend-remove": {
467
579
  const puuid = requirePositional(pos, 1, "Usage: riotclient friend-remove <puuid>");
@@ -506,15 +618,36 @@ async function executeAccountWriteCommand(client, command, yes, pos, vals) {
506
618
  }
507
619
  case "equip-collection": {
508
620
  const raw = pos.slice(1).join(",");
509
- const skinUuids = raw.split(",").map((s) => s.trim()).filter(Boolean);
621
+ const skinUuids = raw
622
+ .split(",")
623
+ .map((s) => s.trim())
624
+ .filter(Boolean);
510
625
  if (skinUuids.length === 0) {
511
626
  throw new ValidationError("invalid-argument", "Usage: riotclient equip-collection <skinUuid,...>");
512
627
  }
513
- return yes ? client.account.equipCollection(skinUuids) : client.account.validateEquipCollection(skinUuids);
628
+ return yes
629
+ ? client.account.equipCollection(skinUuids)
630
+ : client.account.validateEquipCollection(skinUuids);
631
+ }
632
+ case "loadout-export":
633
+ return client.account.exportLoadout();
634
+ case "loadout-diff": {
635
+ const file = requirePositional(pos, 1, "Usage: riotclient loadout-diff <preset.json>");
636
+ const content = JSON.parse(readFileSync(file, "utf-8"));
637
+ return client.account.diffLoadout(content);
638
+ }
639
+ case "loadout-apply": {
640
+ const file = requirePositional(pos, 1, "Usage: riotclient loadout-apply <preset.json> [--yes]");
641
+ const content = JSON.parse(readFileSync(file, "utf-8"));
642
+ return yes
643
+ ? client.account.equipPreset(content)
644
+ : client.account.validateEquipPreset(content);
514
645
  }
515
646
  case "contract-activate": {
516
647
  const uuid = requirePositional(pos, 1, "Usage: riotclient contract-activate <uuid>");
517
- return yes ? client.account.activateContract(uuid) : client.account.validateActivateContract(uuid);
648
+ return yes
649
+ ? client.account.activateContract(uuid)
650
+ : client.account.validateActivateContract(uuid);
518
651
  }
519
652
  case "favourite-add": {
520
653
  const skin = requirePositional(pos, 1, "Usage: riotclient favourite-add <skin>");
@@ -522,7 +655,9 @@ async function executeAccountWriteCommand(client, command, yes, pos, vals) {
522
655
  }
523
656
  case "favourite-remove": {
524
657
  const skin = requirePositional(pos, 1, "Usage: riotclient favourite-remove <skin>");
525
- return yes ? client.account.removeFavourite(skin) : client.account.validateRemoveFavourite(skin);
658
+ return yes
659
+ ? client.account.removeFavourite(skin)
660
+ : client.account.validateRemoveFavourite(skin);
526
661
  }
527
662
  case "privacy":
528
663
  return executePrivacyCommand(client, yes, vals);
@@ -574,8 +709,12 @@ async function executePartyCommand(client, command, options) {
574
709
  }
575
710
  case "party-code":
576
711
  return vals.revoke
577
- ? (yes ? client.party.revokeInviteCode() : client.party.validateRevokeInviteCode())
578
- : (yes ? client.party.createInviteCode() : client.party.validateCreateInviteCode());
712
+ ? yes
713
+ ? client.party.revokeInviteCode()
714
+ : client.party.validateRevokeInviteCode()
715
+ : yes
716
+ ? client.party.createInviteCode()
717
+ : client.party.validateCreateInviteCode();
579
718
  case "party-join": {
580
719
  const target = requirePositional(pos, 1, "Usage: riotclient party-join <partyId|code>");
581
720
  const isPartyId = target.includes("-") || target.length >= 32;
@@ -586,7 +725,9 @@ async function executePartyCommand(client, command, options) {
586
725
  }
587
726
  case "party-ready": {
588
727
  const ready = parseBooleanFlag("ready", requirePositional(pos, 1, "Usage: riotclient party-ready on|off"));
589
- return yes ? client.party.setReady(Boolean(ready)) : client.party.validateSetReady(Boolean(ready));
728
+ return yes
729
+ ? client.party.setReady(Boolean(ready))
730
+ : client.party.validateSetReady(Boolean(ready));
590
731
  }
591
732
  case "party-queue": {
592
733
  const queue = requirePositional(pos, 1, "Usage: riotclient party-queue <queue>");
@@ -597,7 +738,9 @@ async function executePartyCommand(client, command, options) {
597
738
  if (access !== "open" && access !== "closed") {
598
739
  throw new ValidationError("invalid-argument", "Usage: riotclient party-access open|closed");
599
740
  }
600
- return yes ? client.party.setAccessibility(access) : client.party.validateSetAccessibility(access);
741
+ return yes
742
+ ? client.party.setAccessibility(access)
743
+ : client.party.validateSetAccessibility(access);
601
744
  }
602
745
  case "party-start":
603
746
  return yes ? client.party.startMatchmaking() : client.party.validateStartMatchmaking();
@@ -645,13 +788,20 @@ async function executePartyExtraCommand(client, command, yes, pos) {
645
788
  }
646
789
  case "party-servers": {
647
790
  const raw = requirePositional(pos, 1, "Usage: riotclient party-servers <id,...>");
648
- const ids = raw.split(",").map((s) => s.trim()).filter(Boolean);
649
- return yes ? client.party.setPreferredServers(ids) : client.party.validateSetPreferredServers(ids);
791
+ const ids = raw
792
+ .split(",")
793
+ .map((s) => s.trim())
794
+ .filter(Boolean);
795
+ return yes
796
+ ? client.party.setPreferredServers(ids)
797
+ : client.party.validateSetPreferredServers(ids);
650
798
  }
651
799
  case "party-moderator": {
652
800
  const puuid = requirePositional(pos, 1, "Usage: riotclient party-moderator <puuid> on|off");
653
801
  const mod = parseBooleanFlag("moderator", requirePositional(pos, 2, "Usage: riotclient party-moderator <puuid> on|off"));
654
- return yes ? client.party.setModerator(puuid, Boolean(mod)) : client.party.validateSetModerator(puuid, Boolean(mod));
802
+ return yes
803
+ ? client.party.setModerator(puuid, Boolean(mod))
804
+ : client.party.validateSetModerator(puuid, Boolean(mod));
655
805
  }
656
806
  case "party-refresh":
657
807
  return yes ? client.party.refresh() : client.party.validateRefresh();
@@ -660,7 +810,11 @@ async function executePartyExtraCommand(client, command, yes, pos) {
660
810
  }
661
811
  }
662
812
  function parseCustomGameRules(vals) {
663
- const ruleList = Array.isArray(vals.rule) ? vals.rule : vals.rule ? [String(vals.rule)] : [];
813
+ const ruleList = Array.isArray(vals.rule)
814
+ ? vals.rule
815
+ : vals.rule
816
+ ? [String(vals.rule)]
817
+ : [];
664
818
  const rules = {};
665
819
  for (const r of ruleList) {
666
820
  const idx = r.indexOf("=");
@@ -854,11 +1008,16 @@ export async function runCli(args) {
854
1008
  server: { type: "string" },
855
1009
  rule: { type: "string", multiple: true },
856
1010
  body: { type: "string" },
1011
+ days: { type: "string" },
1012
+ pages: { type: "string" },
1013
+ port: { type: "string" },
1014
+ host: { type: "string" },
1015
+ "allow-remote": { type: "boolean", default: false },
857
1016
  },
858
1017
  allowPositionals: true,
859
1018
  });
860
1019
  if (parsed.values.version) {
861
- process.stdout.write(`${packageJson.version}\n`);
1020
+ process.stdout.write(`${PACKAGE_VERSION}\n`);
862
1021
  return 0;
863
1022
  }
864
1023
  if (parsed.values.help || parsed.positionals.length === 0) {
@@ -878,6 +1037,18 @@ export async function runCli(args) {
878
1037
  raw: parsed.values.raw,
879
1038
  });
880
1039
  }
1040
+ if (command === "watch-match") {
1041
+ return await runWatchMatch(client);
1042
+ }
1043
+ if (command === "watch-friends") {
1044
+ return await runWatchFriends(client);
1045
+ }
1046
+ if (command === "serve") {
1047
+ const port = parsed.values.port ? Number(parsed.values.port) : undefined;
1048
+ const host = parsed.values.host;
1049
+ const allowRemote = Boolean(parsed.values["allow-remote"]);
1050
+ return await runServe(client, { port, host, allowRemote });
1051
+ }
881
1052
  const count = parsed.values.count ? Number(parsed.values.count) : undefined;
882
1053
  const loadouts = parsed.values["no-loadouts"] ? false : (parsed.values.loadouts ?? true);
883
1054
  const result = await executeCommand(client, command, {
@@ -889,6 +1060,8 @@ export async function runCli(args) {
889
1060
  loadouts,
890
1061
  matchId: command === "match" ? parsed.positionals[1] : undefined,
891
1062
  yes: Boolean(parsed.values.yes),
1063
+ days: parsed.values.days ? Number(parsed.values.days) : undefined,
1064
+ pages: parsed.values.pages ? Number(parsed.values.pages) : undefined,
892
1065
  positionals: parsed.positionals,
893
1066
  rawValues: parsed.values,
894
1067
  });