fix: 修复游客登陆接口

This commit is contained in:
ElyPrism 2026-06-09 00:09:48 +08:00
parent e2324e26da
commit e3a1c041b6
No known key found for this signature in database
3 changed files with 26 additions and 18 deletions

View File

@ -1,3 +1,5 @@
// 获取游客cookie
const CryptoJS = require('crypto-js') const CryptoJS = require('crypto-js')
const path = require('path') const path = require('path')
const fs = require('fs') const fs = require('fs')
@ -37,7 +39,7 @@ module.exports = async (query, request) => {
let result = await request( let result = await request(
`/api/register/anonimous`, `/api/register/anonimous`,
data, data,
createOption(query, 'weapi'), createOption(query, 'xeapi'),
) )
if (result.body.code === 200) { if (result.body.code === 200) {
result = { result = {

View File

@ -1,6 +1,6 @@
{ {
"name": "@neteasecloudmusicapienhanced/api", "name": "@neteasecloudmusicapienhanced/api",
"version": "4.35.0", "version": "4.35.1",
"description": "全网最全的网易云音乐API接口 || A revival project for NeteaseCloudMusicApi Node.js Services (Half Refactor & Enhanced) || 网易云音乐 API 备份 + 增强 || 本项目自原版v4.28.0版本后开始自行维护", "description": "全网最全的网易云音乐API接口 || A revival project for NeteaseCloudMusicApi Node.js Services (Half Refactor & Enhanced) || 网易云音乐 API 备份 + 增强 || 本项目自原版v4.28.0版本后开始自行维护",
"scripts": { "scripts": {
"dev": "nodemon app.js", "dev": "nodemon app.js",
@ -80,7 +80,7 @@
"express": "^5.2.1", "express": "^5.2.1",
"express-fileupload": "^1.5.2", "express-fileupload": "^1.5.2",
"gzip": "^0.1.0", "gzip": "^0.1.0",
"music-metadata": "^11.12.3", "music-metadata": "^11.13.0",
"node-forge": "^1.4.0", "node-forge": "^1.4.0",
"pac-proxy-agent": "^7.2.0", "pac-proxy-agent": "^7.2.0",
"qrcode": "^1.5.4", "qrcode": "^1.5.4",

36
pnpm-lock.yaml generated
View File

@ -30,8 +30,8 @@ importers:
specifier: ^0.1.0 specifier: ^0.1.0
version: 0.1.0 version: 0.1.0
music-metadata: music-metadata:
specifier: ^11.12.3 specifier: ^11.13.0
version: 11.12.3 version: 11.13.0
node-forge: node-forge:
specifier: ^1.4.0 specifier: ^1.4.0
version: 1.4.0 version: 1.4.0
@ -1636,6 +1636,10 @@ packages:
resolution: {integrity: sha512-aisnrDP4GNe06UcKFnV5bfMNPBUw4jsLGaWwWfnH3v02GnBuXX2MCVn5RbrWo0j3pczUilYblq7fQ7Nw2t5XKw==} resolution: {integrity: sha512-aisnrDP4GNe06UcKFnV5bfMNPBUw4jsLGaWwWfnH3v02GnBuXX2MCVn5RbrWo0j3pczUilYblq7fQ7Nw2t5XKw==}
engines: {node: '>= 0.8'} engines: {node: '>= 0.8'}
media-typer@2.0.0:
resolution: {integrity: sha512-kOy3OxT2HH39N70UnKgu4NWDZjLOz8W/mfyvniHjRH/DrL3f2pOfvWQ4p60offbbtDAnXWp0v9LfMIqMec269Q==}
engines: {node: '>=18'}
merge-descriptors@1.0.3: merge-descriptors@1.0.3:
resolution: {integrity: sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==} resolution: {integrity: sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==}
@ -1729,8 +1733,8 @@ packages:
multistream@4.1.0: multistream@4.1.0:
resolution: {integrity: sha512-J1XDiAmmNpRCBfIWJv+n0ymC4ABcf/Pl+5YvC5B/D2f/2+8PtHvCNxMPKiQcZyi922Hq69J2YOpb1pTywfifyw==} resolution: {integrity: sha512-J1XDiAmmNpRCBfIWJv+n0ymC4ABcf/Pl+5YvC5B/D2f/2+8PtHvCNxMPKiQcZyi922Hq69J2YOpb1pTywfifyw==}
music-metadata@11.12.3: music-metadata@11.13.0:
resolution: {integrity: sha512-n6hSTZkuD59qWgHh6IP5dtDlDZQXoxk/bcA85Jywg8Z1iFrlNgl2+GTFgjZyn52W5UgQpV42V4XqrQZZAMbZTQ==} resolution: {integrity: sha512-uXRaov9dfjSpQufXIU7sMxVZnh+FilCQv2mXn+K5EJ/decP3dTWrgvPYa5r6MtRbieNSCE708Da4J0u1UGfQIw==}
engines: {node: '>=18'} engines: {node: '>=18'}
napi-build-utils@1.0.2: napi-build-utils@1.0.2:
@ -2149,8 +2153,8 @@ packages:
secure-json-parse@2.7.0: secure-json-parse@2.7.0:
resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==} resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==}
semver@7.8.2: semver@7.8.3:
resolution: {integrity: sha512-c8jsqUZm3omBOI66G90z1Dyw5z622G8oLG+omfsHBJf3CWQTlOcwOjvOG6wtiNfW6anKm/eA39LMwMtMez2TiQ==} resolution: {integrity: sha512-wnilbGyMxzbY7dNOl7jpKbLSjcfeweJWU5j4+u5qW+6/wuGD9KzIGOyZnQVSBM9E7DtWaaH3CyHkppYrKYoxwg==}
engines: {node: '>=10'} engines: {node: '>=10'}
hasBin: true hasBin: true
@ -2919,7 +2923,7 @@ snapshots:
'@typescript-eslint/visitor-keys': 8.60.1 '@typescript-eslint/visitor-keys': 8.60.1
debug: 4.4.3 debug: 4.4.3
minimatch: 10.2.5 minimatch: 10.2.5
semver: 7.8.2 semver: 7.8.3
tinyglobby: 0.2.17 tinyglobby: 0.2.17
ts-api-utils: 2.5.0(typescript@5.9.3) ts-api-utils: 2.5.0(typescript@5.9.3)
typescript: 5.9.3 typescript: 5.9.3
@ -4428,6 +4432,8 @@ snapshots:
media-typer@1.1.0: {} media-typer@1.1.0: {}
media-typer@2.0.0: {}
merge-descriptors@1.0.3: {} merge-descriptors@1.0.3: {}
merge-descriptors@2.0.0: {} merge-descriptors@2.0.0: {}
@ -4520,14 +4526,14 @@ snapshots:
once: 1.4.0 once: 1.4.0
readable-stream: 3.6.2 readable-stream: 3.6.2
music-metadata@11.12.3: music-metadata@11.13.0:
dependencies: dependencies:
'@borewit/text-codec': 0.2.2 '@borewit/text-codec': 0.2.2
'@tokenizer/token': 0.3.0 '@tokenizer/token': 0.3.0
content-type: 1.0.5 content-type: 2.0.0
debug: 4.4.3 debug: 4.4.3
file-type: 21.3.4 file-type: 21.3.4
media-typer: 1.1.0 media-typer: 2.0.0
strtok3: 10.3.5 strtok3: 10.3.5
token-types: 6.1.2 token-types: 6.1.2
uint8array-extras: 1.5.0 uint8array-extras: 1.5.0
@ -4549,7 +4555,7 @@ snapshots:
node-abi@3.92.0: node-abi@3.92.0:
dependencies: dependencies:
semver: 7.8.2 semver: 7.8.3
node-fetch@2.7.0: node-fetch@2.7.0:
dependencies: dependencies:
@ -4569,7 +4575,7 @@ snapshots:
ignore-by-default: 1.0.1 ignore-by-default: 1.0.1
minimatch: 10.2.5 minimatch: 10.2.5
pstree.remy: 1.1.8 pstree.remy: 1.1.8
semver: 7.8.2 semver: 7.8.3
simple-update-notifier: 2.0.0 simple-update-notifier: 2.0.0
supports-color: 5.5.0 supports-color: 5.5.0
touch: 3.1.1 touch: 3.1.1
@ -4744,7 +4750,7 @@ snapshots:
https-proxy-agent: 5.0.1 https-proxy-agent: 5.0.1
node-fetch: 2.7.0 node-fetch: 2.7.0
progress: 2.0.3 progress: 2.0.3
semver: 7.8.2 semver: 7.8.3
tar-fs: 2.1.4 tar-fs: 2.1.4
yargs: 16.2.0 yargs: 16.2.0
transitivePeerDependencies: transitivePeerDependencies:
@ -5038,7 +5044,7 @@ snapshots:
secure-json-parse@2.7.0: {} secure-json-parse@2.7.0: {}
semver@7.8.2: {} semver@7.8.3: {}
send@0.19.2: send@0.19.2:
dependencies: dependencies:
@ -5168,7 +5174,7 @@ snapshots:
simple-update-notifier@2.0.0: simple-update-notifier@2.0.0:
dependencies: dependencies:
semver: 7.8.2 semver: 7.8.3
slash@3.0.0: {} slash@3.0.0: {}