mirror of
https://github.com/PaiGramTeam/HonkaiStarRailWikiDataParser.git
synced 2024-11-16 06:25:25 +00:00
17 lines
432 B
Python
17 lines
432 B
Python
from typing import List
|
|
|
|
from func.client import client
|
|
from func.url import list_url
|
|
|
|
from models.wiki import Children
|
|
|
|
|
|
async def get_list(channel_id: str = '17') -> List[Children]:
|
|
params = {
|
|
'app_sn': 'sr_wiki',
|
|
'channel_id': channel_id,
|
|
}
|
|
resp = await client.get(list_url, params=params)
|
|
children = resp.json()["data"]["list"][0]["children"]
|
|
return [Children(**child) for child in children]
|