1***@qq.com
1***@qq.com
  • 发布:2023-12-07 09:22
  • 更新:2024-01-06 19:45
  • 阅读:635

Uni-id-co 外部联登注册 uni-id-illegal-request

分类:uniCloud

errCode:uni-id-illegal-request,云里面日志如下,timestamp error 到底是啥问题?

请求入参: {
"args": {
"path": "/externalRegister",
"httpMethod": "POST",
"headers": {
"content-length": "123",
"x5-uuid": "936d558db0fc1909c4b43bfd2928c4b0",
"x-client-ip": "139.9.148.204",
"x-forwarded-for": "139.9.148.204, 120.27.173.87, 39.96.130.165",
"x-real-ip": "139.9.148.204",
"x-sinfo": "on",
"host": "fc-mp-689c4f6f-487e-4c29-bc8f-c6e9fa469718.next.bspapp.com",
"content-type": "application/json",
"x-forwarded-by": "172.28.194.248:80",
"user-agent": "GuzzleHttp/7"
},
"queryStringParameters": {},
"isBase64Encoded": false,
"body": "{\"clientInfo\":{\"uniPlatform\":\"web\",\"appId\":\"UNIFFD508F\",\"deviceId\":\"LKX7N18328000931\"},\"params\":{\"externalUid\":600001}}"
},
"requestId": "ac1cc2f81701910340769169186"
}
[uni-id-co/ac1cc2f81701910340769169186/113ms/ERROR] [timestamp error], timestamp: undefined timeout: 20000
请求响应状态: success

2023-12-07 09:22 负责人:无 分享
已邀请:
DCloud_uniCloud_CRL

DCloud_uniCloud_CRL

需要添加一下公共请求头,看下文档

xvector

xvector

请求入参: {
"args": {
"path": "/externalRegister",
"httpMethod": "POST",
"headers": {
"content-length": "295",
"x5-uuid": "271dde336834b7048c8a400ddd0156d5",
"uni-id-signature": "F7DEA28388C3E7271D53E8419E63018BDD7E44C161452A0D8ECE987FCAC8D83E",
"x-client-ip": "210.22.9.130",
"uni-id-nonce": "xxxxxxx",
"host": "fc-mp-ae747153-8c6a-4c94-9a15-742fa2ef5c7c.next.bspapp.com",
"content-type": "application/json",
"cookie": "aliyungf_tc=ac1e64d5f79b393e0133627fa9ec1334b12de16329729cbea5dbcef53e8bf748; acw_tc=ac11000117044337566234761e9fd976fbc7765f2580884b24b9a72084b8ce",
"x-forwarded-for": "210.22.9.130, 47.111.193.92, 39.96.119.184",
"accept": "/",
"x-real-ip": "210.22.9.130",
"uni-id-timestamp": "1704433929259",
"x-sinfo": "on",
"x-forwarded-by": "172.28.194.248:80",
"accept-encoding": "gzip, deflate, br",
"user-agent": "Apifox/1.0.0 (https://apifox.com)"
},
"queryStringParameters": {},
"isBase64Encoded": false,
"body": "{\n \"clientInfo\": {\n \"uniPlatform\": \"app\",\n \"appId\": \"UNI58E061E\",\n \"deviceId\": \"deviceId_svr\"\n },\n \"uniIdToken\": \"\",\n \"params\": {\n \"externalUid\": \"2D987a1zyTA2U3y3\",\n \"nickname\": \"微信用户\",\n \"avatar\": \"\",\n \"gender\": 0\n }\n}"
},
"requestId": "ac1cc2f81704433956669158475"
}
[uni-id-co/ac1cc2f81704433956669158475/2ms/ERROR] [timestamp error], timestamp: 1704433929259 timeout: 20000

xvector

xvector

解决了,还是用代码模拟请求比较方便

要回复问题请先登录注册