离线铺面服务器 #823
Shua-github
started this conversation in
Ideas
离线铺面服务器
#823
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
我有一个本地批量铺面生成工具,现在导入需要操作多次,想要Phira能通过API批量查询+缓存铺面
我自己的想法
协议
/info/songs
{ "$schema": "http://json-schema.org/draft-07/schema#", "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "composer": { "type": "string" }, "illustrator": { "type": "string" }, "preview_time": { "type": "number" }, "preview_end_time": { "type": "number" }, "levels": { "type": "object", "additionalProperties": { "type": "object", "properties": { "charter": { "type": "string" }, "difficulty": { "type": "number" } }, "additionalProperties": false, "required": [ "charter", "difficulty" ] } } }, "additionalProperties": false, "required": [ "id", "name", "composer", "illustrator", "preview_time", "preview_end_time", "levels" ] } }/asset/songs/{id}/music
返回音频二进制
/asset/songs/{id}/illustration
返回封面二进制
/asset/songs/{id}/levels/{level}/chart
返回铺面文件,通过MIME类型识别铺面类型
通讯
使用HTTP或Android/Context
如果这个协议可以接受,我可以编写PR
All reactions