-
Notifications
You must be signed in to change notification settings - Fork 2
Resource MUResource
CrucifiedPain edited this page Jun 26, 2026
·
10 revisions
Endpoints: • mu.getById • mu.getManyPaginated (cursor-paginated)
Fetch all items across all pages concurrently using parallel time-slicing.
await client.mu.collect_all(**kwargs: 'typing.Any') -> 'list[MilitaryUnit]'| Name | Type | Default |
|---|---|---|
kwargs |
Any |
*Required* |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
name |
string |
Optional |
countryId |
string |
Optional |
ownerId |
string |
Optional |
members |
array[string] |
Optional |
damage |
number |
Optional |
terrain |
number |
Optional |
wealth |
number |
Optional |
image |
string |
Optional |
description |
string |
Optional |
isRecruiting |
boolean |
Optional |
activeUpgradeLevels |
MuActiveUpgradeLevels |
Optional |
avatarUrl |
string |
Optional |
rankings |
MuRankings |
Optional |
region |
string |
Optional |
roles |
MuRoles |
Optional |
user |
string |
Optional |
leveling |
MuLeveling |
Optional |
investedMoneyByUsers |
object |
Optional |
mercenaryReputation |
number |
Optional |
lastReputationBuyAt |
string |
Optional |
createdAt |
string |
Optional |
updatedAt |
string |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
headquarters |
integer |
Optional |
dormitories |
integer |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
level |
integer |
Optional |
monthlyDamages |
number |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
muWeeklyDamages |
RankingDetail |
Optional |
muDamages |
RankingDetail |
Optional |
muTerrain |
RankingDetail |
Optional |
muWealth |
RankingDetail |
Optional |
muBounty |
RankingDetail |
Optional |
muReputation |
RankingDetail |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
commanders |
array[string] |
Optional |
managers |
array[string] |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
value |
number |
Optional |
rank |
integer |
Optional |
tier |
string |
Optional |
country |
string |
Optional |
Get a military unit by ID.
await client.mu.get(mu_id: 'str') -> 'MilitaryUnit'| Name | Type | Default |
|---|---|---|
mu_id |
str |
*Required* |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
name |
string |
Optional |
countryId |
string |
Optional |
ownerId |
string |
Optional |
members |
array[string] |
Optional |
damage |
number |
Optional |
terrain |
number |
Optional |
wealth |
number |
Optional |
image |
string |
Optional |
description |
string |
Optional |
isRecruiting |
boolean |
Optional |
activeUpgradeLevels |
MuActiveUpgradeLevels |
Optional |
avatarUrl |
string |
Optional |
rankings |
MuRankings |
Optional |
region |
string |
Optional |
roles |
MuRoles |
Optional |
user |
string |
Optional |
leveling |
MuLeveling |
Optional |
investedMoneyByUsers |
object |
Optional |
mercenaryReputation |
number |
Optional |
lastReputationBuyAt |
string |
Optional |
createdAt |
string |
Optional |
updatedAt |
string |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
headquarters |
integer |
Optional |
dormitories |
integer |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
level |
integer |
Optional |
monthlyDamages |
number |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
muWeeklyDamages |
RankingDetail |
Optional |
muDamages |
RankingDetail |
Optional |
muTerrain |
RankingDetail |
Optional |
muWealth |
RankingDetail |
Optional |
muBounty |
RankingDetail |
Optional |
muReputation |
RankingDetail |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
commanders |
array[string] |
Optional |
managers |
array[string] |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
value |
number |
Optional |
rank |
integer |
Optional |
tier |
string |
Optional |
country |
string |
Optional |
Fetch multiple military units by ID concurrently using the auto-batcher.
await client.mu.get_many(mu_ids: 'list[str]') -> 'list[MilitaryUnit | None]'| Name | Type | Default |
|---|---|---|
mu_ids |
list[str] |
*Required* |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
name |
string |
Optional |
countryId |
string |
Optional |
ownerId |
string |
Optional |
members |
array[string] |
Optional |
damage |
number |
Optional |
terrain |
number |
Optional |
wealth |
number |
Optional |
image |
string |
Optional |
description |
string |
Optional |
isRecruiting |
boolean |
Optional |
activeUpgradeLevels |
MuActiveUpgradeLevels |
Optional |
avatarUrl |
string |
Optional |
rankings |
MuRankings |
Optional |
region |
string |
Optional |
roles |
MuRoles |
Optional |
user |
string |
Optional |
leveling |
MuLeveling |
Optional |
investedMoneyByUsers |
object |
Optional |
mercenaryReputation |
number |
Optional |
lastReputationBuyAt |
string |
Optional |
createdAt |
string |
Optional |
updatedAt |
string |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
headquarters |
integer |
Optional |
dormitories |
integer |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
level |
integer |
Optional |
monthlyDamages |
number |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
muWeeklyDamages |
RankingDetail |
Optional |
muDamages |
RankingDetail |
Optional |
muTerrain |
RankingDetail |
Optional |
muWealth |
RankingDetail |
Optional |
muBounty |
RankingDetail |
Optional |
muReputation |
RankingDetail |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
commanders |
array[string] |
Optional |
managers |
array[string] |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
value |
number |
Optional |
rank |
integer |
Optional |
tier |
string |
Optional |
country |
string |
Optional |
Get military units (cursor-paginated).
Args: member_id: Filter: MUs that this user is a member of. user_id: Filter: MUs owned/created by this user. search: Text search across MU names.
await client.mu.get_paginated(*, limit: 'int' = 20, cursor: 'str | None' = None, member_id: 'str | None' = None, user_id: 'str | None' = None, search: 'str | None' = None, auto_items: 'bool' = False, max_pages: 'int | float' = inf, cursor_end: 'str | None' = None) -> 'CursorPage[MilitaryUnit] | AsyncIterator[MilitaryUnit]'| Name | Type | Default |
|---|---|---|
limit |
int |
20 |
cursor |
str |
None |
member_id |
str |
None |
user_id |
str |
None |
search |
str |
None |
auto_items |
bool |
False |
max_pages |
int | float |
inf |
cursor_end |
str |
None |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
items |
array[MilitaryUnit] |
Required |
nextCursor |
string |
Optional |
hasMore |
boolean |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
name |
string |
Optional |
countryId |
string |
Optional |
ownerId |
string |
Optional |
members |
array[string] |
Optional |
damage |
number |
Optional |
terrain |
number |
Optional |
wealth |
number |
Optional |
image |
string |
Optional |
description |
string |
Optional |
isRecruiting |
boolean |
Optional |
activeUpgradeLevels |
MuActiveUpgradeLevels |
Optional |
avatarUrl |
string |
Optional |
rankings |
MuRankings |
Optional |
region |
string |
Optional |
roles |
MuRoles |
Optional |
user |
string |
Optional |
leveling |
MuLeveling |
Optional |
investedMoneyByUsers |
object |
Optional |
mercenaryReputation |
number |
Optional |
lastReputationBuyAt |
string |
Optional |
createdAt |
string |
Optional |
updatedAt |
string |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
headquarters |
integer |
Optional |
dormitories |
integer |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
level |
integer |
Optional |
monthlyDamages |
number |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
muWeeklyDamages |
RankingDetail |
Optional |
muDamages |
RankingDetail |
Optional |
muTerrain |
RankingDetail |
Optional |
muWealth |
RankingDetail |
Optional |
muBounty |
RankingDetail |
Optional |
muReputation |
RankingDetail |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
commanders |
array[string] |
Optional |
managers |
array[string] |
Optional |
| Field | Type | Required |
|---|---|---|
_id |
string |
Optional |
__v |
integer |
Optional |
value |
number |
Optional |
rank |
integer |
Optional |
tier |
string |
Optional |
country |
string |
Optional |
Clear the SWR cache for all resources.
await client.mu.invalidate_cache() -> 'None'- action_log
- alliance
- article
- battle
- battle_loot_summary
- battle_order
- battle_ranking
- company
- country
- donation
- election
- event
- game_config
- game_stat
- government
- inventory
- item_trading
- mercenary_contract_auction
- mu
- mu_member
- party
- ranking
- region
- round
- search
- tournament
- transaction
- upgrade
- user
- work
- work_offer
- worker