/KeyakiMsgAssistant

CLI tool for extracting resources from "欅坂46/日向坂46 メッセージ" app

Primary LanguagePythonGNU General Public License v3.0GPL-3.0

logo

KeyakiMsgAssistant

CLI tool for extracting resources from "欅坂46/日向坂46 メッセージ" app

Requirement

  • Rooted
  • ADB tool
  • Python environment

Implementation

  • Extract profile and database from device
  • Decrypt access token and get resource id
  • Forge requests for resource urls
  • Download media files to local

Dependency

pip install pycryptodome requests

Usage

1. Get parameters (ADB Required)

Run python get_params.py in terminal

Program will generate params.json like

{
    "authorization": {
        ...
    },
    "user_agent": ...,
    "app_id": ...
}

If you want to use proxy, add a line like

    "proxy": "http://127.0.0.1:1080",

This step is only needed when run for the first time or after changing login device

2. Get download queue (ADB Required)

Run python get_dl_queue.py in terminal

Program will pull SQLite file main.db from device to working directory

and generate download.json like

[
    ...,
    {
        "status": 0,
        "media_type": "photo",
        "talk_id": "0000007527"
    },
    ...
]

as download queue which supports progress reserved and incremental update

"status": 1 means media file has already downloaded

3. Start download

Run python start_dl.py in terminal

All media files are downloaded to ./resource directory

Enjoy yourself

License

This project is under the GNU General Public License v3.0