mirai-api-http icon indicating copy to clipboard operation
mirai-api-http copied to clipboard

部分接口返回未使用RESTful封装

Open nepsyn opened this issue 4 years ago • 0 comments

部分用于获取信息的接口返回结果没有使用RESTful封装

测试已知的接口有:

  1. 获取profile的相关接口(botProfile, friendProfile, groupProfile)
  2. 获取群信息接口(groupConfig)
  3. 获取群成员信息接口(memberInfo)
> curl 127.0.0.1:23333/botProfile?sessionKey=P3R0fGNg
{"nickname":"L","email":"","age":0,"level":14,"sign":"","sex":"UNKNOWN"}
> curl 127.0.0.1:23333/groupConfig?target=123456789&sessionKey=wPmJoLbv
{"name":"L、C","announcement":"","confessTalk":false,"allowMemberInvite":true,"autoApprove":true,"anonymousChat":false}
> curl 127.0.0.1:23333/memberInfo?target=123456789&memberId=10000000&sessionKey=wPmJoLbv
{"id":10000000,"memberName":"N","specialTitle":"","permission":"OWNER","joinTimestamp":1591279073,"lastSpeakTimestamp":1629126963,"muteTimeRemaining":0,"group":{"id":123456789,"name":"L、C","permission":"ADMINISTRATOR"}}
> curl 127.0.0.1:23333/about
{"code":0,"msg":"","data":{"version":"2.2.0"}}

mah版本:V2.2.0 mirai-console版本:V2.7-RC

nepsyn avatar Aug 17 '21 07:08 nepsyn