arkprtserver

GPL-3.0 License

Stars
2

arkprtserver

Website displaying arknights user information.

Built with ArkPRTS


Source Code: https://github.com/thesadru/arkprtserver


API docs

/api/raw/search?nickname=foo&server=[en|jp|kr]

Returns raw data for an arknights user. Server defaults to en.

example

[{"nickName": "PeterYR", "nickNumber": "3977", "uid": "93679156", "registerTs": 1579195252, "mainStageProgress": null, "charCnt": 304, "furnCnt": 1537, "skinCnt": 213, ...

/api/search?nickname=foo&server=[en|jp|kr]&lang=[en|jp|kr|cn]

Returns pretty data for an arknights user. Server defaults to en. Lang determines the static data language (such as character name) and defaults to the server lang.

example

[{"nickname": "PeterYR", "nicknumber": "3977", "uid": "93679156", "server": "Terra", "level": 120, "avatar": {"type": "ICON", "id": "avatar_def_03", "asset": null}, ...

/api/login/sendcode?email=example%40gmail.com&server=[en|jp|kr]

Sends an email with a code to the specified email address.

/api/login?email=example%40gmail.com&code=123456&server=[en|jp|kr]

Logs in using the email and code (if they are currently in-game, this will kick them out). Returns authentication as both json and cookies (for compatibility).

Example:

{"server": "en", "channeluid": "12345678", "token": "..."}

/api/raw/user

Returns private raw arknights user data. Requires authentication (server, channeluid, token) which can be sent anywhere in query, headers or cookies. Server can be any of en, jp, kr, cn, bili, tw.

If you are a bit familiar with the arknights internals, uid, secret, seqnum are also accepted.

example (when logged in)

{"dungeon": {"stages": {"main_00-01": {"stageId": "main_00-01", "completeTimes": 4, "startTimes": 5, "practiceTimes": 0, "state": 3, "hasBattleReplay": 1, "noCostCnt": 0}, ...

POST /proxy/...

Proxies any request towards the arknights servers. This can be used to get futher raw data. For example /api/raw/user is just /proxy/account/syncData. Requires authentication (server, channeluid, token) which can be sent anywhere in query, headers or cookies. Server can be any of en, jp, kr, cn, bili, tw.

If you are a bit familiar with the arknights internals, uid, secret, seqnum are also accepted. If the endpoint complains about needing to log in first, try /proxy/...?sync=true to send an extra sync request beforehand.

example (when logged in)

POST https://arkprts.ashlen.top/proxy/crisisV2/getInfo?sync=true
{}
{"info": {"seasonId": "", "mapStageDataMap": {}, "mapDetailDataMap": {}, "seasonConst": {}, "achievementDataMap": {"crisis_v2_season_1_1": {"pMapName": {"name": "Ashen Swampland", "code": "Victoria"}, ...

Contributing

Any kind of contribution is welcome. Please read CONTRIBUTING.md for more information.