[fix] Live

This commit is contained in:
Lkeme 2021-10-05 10:58:13 +08:00
parent fcac6e9102
commit 4ecb331717
3 changed files with 5 additions and 2623 deletions

1
.gitignore vendored
View File

@ -14,6 +14,7 @@ tmp/
out
gen
/vendor/
composer.lock
/configs/
/tests/
config

2621
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -332,12 +332,14 @@ class Live
* @param int $page_size
* @return array
*/
public static function fetchMedalList(int $page_size = 100): array
public static function fetchMedalList(int $page_size = 10): array
{
$metal_list = [];
for ($i = 1; $i <= 10; $i++) {
for ($i = 1; $i <= 100; $i++) {
// https://live.bilibili.com/p/html/live-app-fansmedal-manange/index.html
// $url = 'https://api.live.bilibili.com/fans_medal/v5/live_fans_medal/iApiMedal';
$url = 'https://api.live.bilibili.com/i/api/medal';
// TODO size变小 需要优化获取逻辑 可能会412
$payload = [
'page' => $i,
'pageSize' => $page_size