ecapi-sdk 3.7.8__tar.gz → 3.7.10__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ecapi-sdk
3
- Version: 3.7.8
3
+ Version: 3.7.10
4
4
  Summary: ECAPI SDK for Python
5
5
  Author: EaseCation
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "ecapi-sdk"
7
- version = "3.7.8"
7
+ version = "3.7.10"
8
8
  description = "ECAPI SDK for Python"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
@@ -725,6 +725,10 @@ class AdminPunishmentAPI(_BaseApi):
725
725
  """创建处罚"""
726
726
  return self._post(f"/admin/players/{quote(str(ecid), safe='')}/punishments", payload, **kwargs)
727
727
 
728
+ def get_report_punishment(self, ecid: str, **kwargs: Any) -> Any:
729
+ """获取玩家禁用举报状态"""
730
+ return self._get(f"/admin/players/{quote(str(ecid), safe='')}/report-punishment", None, **kwargs)
731
+
728
732
  def list(self, query: Optional[QueryParams] = None, **kwargs: Any) -> Any:
729
733
  """分页查询处罚列表"""
730
734
  return self._get(f"/admin/punishments", query, **kwargs)
@@ -1601,6 +1605,19 @@ class PlayerStatusAPI(_BaseApi):
1601
1605
  """查询玩家服内状态"""
1602
1606
  return self._get(f"/player-statuses", query, **kwargs)
1603
1607
 
1608
+ class PlayerLotteryAPI(_BaseApi):
1609
+ def get_chests(self, **kwargs: Any) -> Any:
1610
+ """查询主服抽奖箱目录"""
1611
+ return self._get(f"/lottery/chests", None, **kwargs)
1612
+
1613
+ def get_progress(self, ecid: str, query: Optional[QueryParams] = None, **kwargs: Any) -> Any:
1614
+ """读取玩家已保存的抽奖保底进度"""
1615
+ return self._get(f"/players/{quote(str(ecid), safe='')}/lottery/progress", query, **kwargs)
1616
+
1617
+ def get_records(self, ecid: str, query: Optional[QueryParams] = None, **kwargs: Any) -> Any:
1618
+ """分页查询主服各类箱子抽奖记录"""
1619
+ return self._get(f"/players/{quote(str(ecid), safe='')}/lottery/records", query, **kwargs)
1620
+
1604
1621
  class ServerAPI(_BaseApi):
1605
1622
  def __init__(self, http: _HttpClient) -> None:
1606
1623
  super().__init__(http)
@@ -2012,6 +2029,7 @@ class ECAPIClient:
2012
2029
  self.parkour = ParkourAPI(self._http)
2013
2030
  self.pit2 = PIT2API(self._http)
2014
2031
  self.player = PlayerAPI(self._http)
2032
+ self.player_lottery = PlayerLotteryAPI(self._http)
2015
2033
  self.replay = ReplayAPI(self._http)
2016
2034
  self.server = ServerAPI(self._http)
2017
2035
  self.system = SystemAPI(self._http)
@@ -697,7 +697,7 @@ class AuthAPILoginByOauth2BodyRequired(TypedDict):
697
697
  code: str
698
698
 
699
699
  class AuthAPILoginByOauth2Body(AuthAPILoginByOauth2BodyRequired, total=False):
700
- pass
700
+ redirectUri: str
701
701
 
702
702
  class AuthAPIRefreshTokenBodyRequired(TypedDict):
703
703
  refreshToken: str
@@ -1462,6 +1462,19 @@ class PlayerStatusAPIGetQueryRequired(TypedDict):
1462
1462
  class PlayerStatusAPIGetQuery(PlayerStatusAPIGetQueryRequired, total=False):
1463
1463
  pass
1464
1464
 
1465
+ class PlayerLotteryAPIGetProgressQueryRequired(TypedDict):
1466
+ chestId: QueryValue
1467
+
1468
+ class PlayerLotteryAPIGetProgressQuery(PlayerLotteryAPIGetProgressQueryRequired, total=False):
1469
+ pass
1470
+
1471
+ class PlayerLotteryAPIGetRecordsQuery(TypedDict, total=False):
1472
+ chestId: QueryValue
1473
+ days: QueryValue
1474
+ endTime: QueryValue
1475
+ current: QueryValue
1476
+ pageSize: QueryValue
1477
+
1465
1478
  class ServerAPIListQuery(TypedDict, total=False):
1466
1479
  filter: QueryValue
1467
1480
  min: QueryValue
@@ -1768,6 +1781,7 @@ class ServerRoomAPICreateBody(ServerRoomAPICreateBodyRequired, total=False):
1768
1781
  map: str
1769
1782
  name: str
1770
1783
  owner: str
1784
+ publicRoom: bool
1771
1785
  metadata: str
1772
1786
  ownerOnlyStart: bool
1773
1787
  allowCreative: bool
@@ -1980,6 +1994,7 @@ class AdminPlayerWalletAPI:
1980
1994
  class AdminPunishmentAPI:
1981
1995
  def clear_degree(self, ecid: str, **kwargs: Any) -> Any: ...
1982
1996
  def create(self, ecid: str, payload: AdminPunishmentAPICreateBody, **kwargs: Any) -> Any: ...
1997
+ def get_report_punishment(self, ecid: str, **kwargs: Any) -> Any: ...
1983
1998
  def list(self, query: Optional[AdminPunishmentAPIListQuery] = ..., **kwargs: Any) -> Any: ...
1984
1999
  def list_prism_device_ban_logs(self, query: Optional[AdminPunishmentAPIListPrismDeviceBanLogsQuery] = ..., **kwargs: Any) -> Any: ...
1985
2000
  def remove(self, ecid: str, type: str, query: Optional[AdminPunishmentAPIRemoveQuery] = ..., **kwargs: Any) -> Any: ...
@@ -2257,6 +2272,11 @@ class PlayerStatusAPI:
2257
2272
  def create_query(self, payload: PlayerStatusAPICreateQueryBody, **kwargs: Any) -> Any: ...
2258
2273
  def get(self, query: PlayerStatusAPIGetQuery, **kwargs: Any) -> Any: ...
2259
2274
 
2275
+ class PlayerLotteryAPI:
2276
+ def get_chests(self, **kwargs: Any) -> Any: ...
2277
+ def get_progress(self, ecid: str, query: PlayerLotteryAPIGetProgressQuery, **kwargs: Any) -> Any: ...
2278
+ def get_records(self, ecid: str, query: Optional[PlayerLotteryAPIGetRecordsQuery] = ..., **kwargs: Any) -> Any: ...
2279
+
2260
2280
  class ServerAPI:
2261
2281
  broadcast: ServerBroadcastAPI
2262
2282
  config_sync: ServerConfigSyncAPI
@@ -2422,6 +2442,7 @@ class ECAPIClient:
2422
2442
  parkour: ParkourAPI
2423
2443
  pit2: PIT2API
2424
2444
  player: PlayerAPI
2445
+ player_lottery: PlayerLotteryAPI
2425
2446
  replay: ReplayAPI
2426
2447
  server: ServerAPI
2427
2448
  system: SystemAPI
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ecapi-sdk
3
- Version: 3.7.8
3
+ Version: 3.7.10
4
4
  Summary: ECAPI SDK for Python
5
5
  Author: EaseCation
6
6
  License: MIT
File without changes
File without changes