极光IM 创建聊天室 参数错误!
REST API ```
POST /v1/chatroom/
创建聊天室参数错误:
--> POST https://api.im.jpush.cn/v1/chatroom http/1.1
Content-Type: application/json; charset=utf-8
Content-Length: 81
Accept-Language: zh-CN,zh;q=0.8
Authorization: Basic YmEyOGNjNzZkZWQwZjk2YWUwYTYzYzJlOmI0ZThjN2NiNzJjZjU0MDgxMmJjOGY5Nw==
body:{"owner_username":"yyy","name":"测试聊天室","description":"测试聊天室"}
--> END POST
<-- 400 https://api.im.jpush.cn/v1/chatroom (1272ms)
server: nginx
date: Tue, 14 Apr 2020 06:52:37 GMT
content-type: application/json;charset=UTF-8
content-length: 56
body:{"error":{"code":899003,"message":"parameter invalid!"}}
```
Authorization 加密方式是拿appkey+:+Master Secret base64加密的
Authorization: Basic base64_auth_string
其中 base64_auth_string 的生成算法为:base64(appKey:masterSecret)
即,对 appKey 加上冒号,加上 masterSecret 拼装起来的字符串,再做 base64 转换。