Compare commits

...

4 Commits

Author SHA1 Message Date
d042606aa1 Update map.json 2025-05-25 09:41:16 +08:00
01c270caa7 unlock > unlock_all 2025-04-17 09:15:43 +08:00
5ecb34920a add timeout 2025-04-17 09:14:06 +08:00
5f81c60716 Update README.md 2025-04-17 09:12:02 +08:00
4 changed files with 581 additions and 7 deletions

View File

@ -58,7 +58,7 @@ You send your information to __Maquitous__, __Maquitous__ transfer your informat
"userId": integer "userId": integer
} }
- `GET /unlock?userid=userId` - Unlock all DX Master Charts in account. - `GET /unlock_all?userid=userId` - Unlock all DX Master Charts in account.
Params: `userId` Params: `userId`
Response: Response:
@ -105,7 +105,7 @@ You send your information to __Maquitous__, __Maquitous__ transfer your informat
```bash ```bash
pip install -r requirements.txt pip install -r requirements.txt
python3 host.py python3 main.py
``` ```
## Warning and Statements ## Warning and Statements

View File

@ -38,7 +38,7 @@ def bad_request(e):
@app.route("/") @app.route("/")
def index(): def index():
return jsonify({"status": "200 OK", "timestamp": int(time.time()), "info": "Project Fragrance","availableApi": ["qr", "ticket", "mapstock", "unlock", "map", "bonus"], "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8')}), 200 return jsonify({"status": "200 OK", "timestamp": int(time.time()), "info": "Project Fragrance","availableApi": ["qr", "ticket", "mapstock", "unlock_all", "map", "bonus"], "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8')}), 200
@app.route("/qr") @app.route("/qr")
def qr_to_userid(): def qr_to_userid():
@ -156,11 +156,11 @@ def mapstock_process():
data = jsonify({"status": status, "timestamp": timestamp, "info": info, "apiName": "mapstock", "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8'), "userId": userId}) data = jsonify({"status": status, "timestamp": timestamp, "info": info, "apiName": "mapstock", "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8'), "userId": userId})
return data, returnCode return data, returnCode
@app.route("/unlock") @app.route("/unlock_all")
def unlock_process(): def unlock_process():
userId = request.args.get('userid') userId = request.args.get('userid')
if userId is None or userId.isdigit() is False or len(str(userId)) != 8: if userId is None or userId.isdigit() is False or len(str(userId)) != 8:
return jsonify({"apiName": "unlock", "apiInfo": "Unlock All DX Master Charts.", "apiUsage": "/unlock?userid=<userId>"}) return jsonify({"apiName": "unlock", "apiInfo": "Unlock All DX Master Charts.", "apiUsage": "/unlock_all?userid=<userId>"})
else: else:
userId = int(userId) userId = int(userId)
timestamp = int(time.time()) timestamp = int(time.time())
@ -183,7 +183,7 @@ def unlock_process():
status = "200 OK" status = "200 OK"
info = "Succeed." info = "Succeed."
log = {"UserLoginApiStatus": 1, "UploadUserPlaylogApiStatus": 1, "UpsertUserAllApi": 1, "UserLogoutApiStatus": 1} log = {"UserLoginApiStatus": 1, "UploadUserPlaylogApiStatus": 1, "UpsertUserAllApi": 1, "UserLogoutApiStatus": 1}
data = jsonify({"status": status, "timestamp": timestamp, "info": info, "apiName": "unlock", "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8'), "userId": userId}) data = jsonify({"status": status, "timestamp": timestamp, "info": info, "apiName": "unlock_all", "date": datetime.now(pytz.timezone('Asia/Shanghai')).strftime('%a, %d %b %Y %H:%M:%S GMT+8'), "userId": userId})
return data, returnCode return data, returnCode
@app.route("/music", methods=['POST']) @app.route("/music", methods=['POST'])

570
map.json
View File

@ -8404,5 +8404,575 @@
"kind": 11 "kind": 11
} }
] ]
},
{
"mapId": 400003,
"name": "天空街区域5",
"treasure": [
{
"id": 400301,
"distance": 0,
"name": "ノア",
"kind": 9
},
{
"id": 400371,
"distance": 35000,
"name": "フェイクフェイス・フェイルセイフ",
"kind": 5
},
{
"id": 400302,
"distance": 80000,
"name": "ソウ",
"kind": 9
},
{
"id": 400372,
"distance": 150000,
"name": "シックスプラン",
"kind": 5
},
{
"id": 400303,
"distance": 210000,
"name": "トキヤ",
"kind": 9
},
{
"id": 400351,
"distance": 270000,
"name": "スカイストリートちほー5",
"kind": 11
},
{
"id": 400304,
"distance": 330000,
"name": "ナノハ",
"kind": 9
},
{
"id": 400373,
"distance": 500000,
"name": "フタタビ",
"kind": 5
},
{
"id": 400305,
"distance": 600000,
"name": "ユウキ",
"kind": 9
},
{
"id": 400381,
"distance": 800000,
"name": "ふらふらふら、 スカイストリートちほー5 チャレンジ",
"kind": 5
},
{
"id": 400361,
"distance": 900000,
"name": "スカイストリートちほー5",
"kind": 11
}
]
},
{
"mapId": 400053,
"name": "ヘブンバーンズレッド区域",
"treasure": [
{
"id": 405301,
"distance": 0,
"name": "茅森月歌",
"kind": 9
},
{
"id": 405302,
"distance": 5000,
"name": "和泉ユキ",
"kind": 9
},
{
"id": 405303,
"distance": 10000,
"name": "逢川めぐみ",
"kind": 9
},
{
"id": 405304,
"distance": 15000,
"name": "東城つかさ",
"kind": 9
},
{
"id": 405305,
"distance": 20000,
"name": "朝倉可憐",
"kind": 9
},
{
"id": 405306,
"distance": 25000,
"name": "國見タマ",
"kind": 9
},
{
"id": 405371,
"distance": 30000,
"name": "Burn My Soul",
"kind": 5
},
{
"id": 405351,
"distance": 40000,
"name": "ヘブンバーンズレッドちほー その1",
"kind": 1
},
{
"id": 405308,
"distance": 60000,
"name": "水瀬いちご",
"kind": 9
},
{
"id": 405309,
"distance": 80000,
"name": "水瀬すもも",
"kind": 9
},
{
"id": 405310,
"distance": 105000,
"name": "樋口聖華",
"kind": 9
},
{
"id": 405311,
"distance": 130000,
"name": "柊木梢",
"kind": 9
},
{
"id": 405312,
"distance": 160000,
"name": "ビャッコ",
"kind": 9
},
{
"id": 405307,
"distance": 190000,
"name": "蒼井えりか",
"kind": 9
},
{
"id": 405352,
"distance": 220000,
"name": "ヘブンバーンズレッドちほー その2",
"kind": 1
},
{
"id": 405313,
"distance": 260000,
"name": "七瀬七海",
"kind": 9
},
{
"id": 405361,
"distance": 300000,
"name": "ヘブンバーンズレッドちほー",
"kind": 11
}
]
},
{
"mapId": 400056,
"name": "sasakure.UK区域",
"treasure": [
{
"id": 405602,
"distance": 0,
"name": "テラ(トンデモワンダーズ)",
"kind": 9
},
{
"id": 405671,
"distance": 25000,
"name": "トンデモワンダーズ",
"kind": 5
},
{
"id": 405651,
"distance": 30000,
"name": "sasakure.UKちほー その1",
"kind": 11
},
{
"id": 405603,
"distance": 40000,
"name": "カラス(トンデモワンダーズ)",
"kind": 9
},
{
"id": 405661,
"distance": 75000,
"name": "sasakure.UKちほー その1",
"kind": 11
},
{
"id": 405672,
"distance": 90000,
"name": "Good Bye, Mr. Jack",
"kind": 5
},
{
"id": 405652,
"distance": 100000,
"name": "sasakure.UKちほー その2",
"kind": 11
},
{
"id": 405604,
"distance": 120000,
"name": "初音ミク(*ハロー、プラネット。)",
"kind": 9
},
{
"id": 405673,
"distance": 150000,
"name": "*ハロー、プラネット。",
"kind": 5
},
{
"id": 405662,
"distance": 160000,
"name": "sasakure.UKちほー その2",
"kind": 11
},
{
"id": 405601,
"distance": 180000,
"name": "sasakure.UK",
"kind": 9
},
{
"id": 405674,
"distance": 230000,
"name": "PinqPiq (xovevox Remix)",
"kind": 5
},
{
"id": 405653,
"distance": 240000,
"name": "sasakure.UKちほー その3",
"kind": 1
}
]
},
{
"mapId": 400057,
"name": "TJ.hangneil区域",
"treasure": [
{
"id": 405701,
"distance": 0,
"name": "TJ.hangneil",
"kind": 9
},
{
"id": 405771,
"distance": 30000,
"name": "ozma",
"kind": 5
},
{
"id": 405702,
"distance": 60000,
"name": "男の子(神威)",
"kind": 9
},
{
"id": 405751,
"distance": 120000,
"name": "TJ.hangneilちほー",
"kind": 11
},
{
"id": 405703,
"distance": 150000,
"name": "女の子(神威)",
"kind": 9
},
{
"id": 405761,
"distance": 300000,
"name": "TJ.hangneilちほー",
"kind": 11
},
{
"id": 405781,
"distance": 400000,
"name": "神威 TJ.hangneilちほー チャレンジ",
"kind": 5
},
{
"id": 405791,
"distance": 444000,
"name": "旅行スタンプ(月面基地)",
"kind": 3
}
]
},
{
"mapId": 400058,
"name": "月面区域",
"treasure": [
{
"id": 405891,
"distance": 1000,
"name": "That's one small step for a man, one giant leap for mankind.",
"kind": 2
},
{
"id": 405871,
"distance": 100000,
"name": "月面基地",
"kind": 5
},
{
"id": 405892,
"distance": 120000,
"name": "S H T R B",
"kind": 2
},
{
"id": 405893,
"distance": 140000,
"name": "E A E K E",
"kind": 2
},
{
"id": 405894,
"distance": 160000,
"name": "E W B M A",
"kind": 2
},
{
"id": 405895,
"distance": 180000,
"name": "A B I N O",
"kind": 2
},
{
"id": 405896,
"distance": 200000,
"name": "◤ M H T O",
"kind": 2
},
{
"id": 405861,
"distance": 240000,
"name": "月面ちほー",
"kind": 11
}
]
},
{
"mapId": 400059,
"name": "裏 月面区域",
"treasure": [
{
"id": 405901,
"distance": 199000,
"name": "宇宙飛行士Apollo",
"kind": 9
},
{
"id": 405981,
"distance": 200000,
"name": "Apollo 裏月面ちほー チャレンジ1",
"kind": 5
},
{
"id": 405961,
"distance": 210000,
"name": "裏 月面ちほー その1",
"kind": 11
},
{
"id": 405982,
"distance": 654000,
"name": "Raputa 裏月面ちほー チャレンジ2",
"kind": 5
},
{
"id": 405962,
"distance": 660000,
"name": "裏 月面ちほー その2",
"kind": 11
},
{
"id": 405991,
"distance": 666000,
"name": "project raputa completed",
"kind": 2
}
]
},
{
"mapId": 400004,
"name": "7sRef区域3",
"treasure": [
{
"id": 400401,
"distance": 0,
"name": "リズ",
"kind": 9
},
{
"id": 400471,
"distance": 150000,
"name": "Redemption",
"kind": 5
},
{
"id": 400402,
"distance": 200000,
"name": "フルーンシュピラー",
"kind": 9
},
{
"id": 400472,
"distance": 400000,
"name": "Ether Second",
"kind": 5
},
{
"id": 400403,
"distance": 450000,
"name": "シュヴァルツローゼ",
"kind": 9
},
{
"id": 400451,
"distance": 550000,
"name": "7sRefちほー3",
"kind": 11
},
{
"id": 400404,
"distance": 600000,
"name": "ヘルブラオ",
"kind": 9
},
{
"id": 400473,
"distance": 850000,
"name": "The Great Banquet",
"kind": 5
},
{
"id": 400405,
"distance": 900000,
"name": "アシッド(幼少期)",
"kind": 9
},
{
"id": 400481,
"distance": 1300000,
"name": "Straight into the lights 7sRefちほー3 チャレンジ",
"kind": 5
},
{
"id": 400461,
"distance": 1400000,
"name": "7sRefちほー3",
"kind": 11
}
]
},
{
"mapId": 400062,
"name": "CHUNITHM区域3",
"treasure": [
{
"id": 406201,
"distance": 0,
"name": "縁​",
"kind": 9
},
{
"id": 406272,
"distance": 30000,
"name": "Ring",
"kind": 5
},
{
"id": 406202,
"distance": 50000,
"name": "冴川 芽依",
"kind": 9
},
{
"id": 406205,
"distance": 130000,
"name": "ヴェルゼビュートネメシス​",
"kind": 9
},
{
"id": 406273,
"distance": 190000,
"name": "8-EM",
"kind": 5
},
{
"id": 406206,
"distance": 210000,
"name": "リヒトシュッツェ​",
"kind": 9
},
{
"id": 406274,
"distance": 270000,
"name": "World Vanquisher",
"kind": 5
},
{
"id": 406251,
"distance": 280000,
"name": "CHUNITHMちほー3",
"kind": 11
},
{
"id": 406204,
"distance": 300000,
"name": "不来方 とあ​",
"kind": 9
},
{
"id": 406275,
"distance": 360000,
"name": "蜘蛛の糸",
"kind": 5
},
{
"id": 406203,
"distance": 380000,
"name": "ロト・トゥエルヴ",
"kind": 9
},
{
"id": 406276,
"distance": 480000,
"name": "WE'RE BACK!!",
"kind": 5
},
{
"id": 406261,
"distance": 600000,
"name": "CHUNITHMちほー3",
"kind": 11
}
]
} }
] ]

View File

@ -56,6 +56,9 @@ def sdgb_api(data, useApi, userId):
data_enc = aes.encrypt(data) data_enc = aes.encrypt(data)
data_def = zlib.compress(data_enc) data_def = zlib.compress(data_enc)
endpoint = "https://maimai-gm.wahlap.com:42081/Maimai2Servlet/" endpoint = "https://maimai-gm.wahlap.com:42081/Maimai2Servlet/"
timeout = httpx.Timeout(40.0, read=40.0)
r = httpx.post( r = httpx.post(
endpoint + get_hash_api(useApi), endpoint + get_hash_api(useApi),
headers = { headers = {
@ -67,7 +70,8 @@ def sdgb_api(data, useApi, userId):
"Content-Encoding": "deflate", "Content-Encoding": "deflate",
"Expect": "100-continue" "Expect": "100-continue"
}, },
data = data_def data = data_def,
timeout=timeout
) )
resp_def = r.content resp_def = r.content