【发布时间】:2020-12-13 18:17:49
【问题描述】:
我有两个平面 Feed 组,main,主要新闻 Feed 和 main_topics。
我可以成功地向任何一个发帖。
但是当我尝试使用to 字段“抄送”另一个时,例如to: ["main_topics:donuts"],我得到:
code: 17
detail: "You do not have permission to do this, you got this error because there are no policies allowing this request on this application. Please consult the documentation https://getstream.io/docs/"
duration: "0.16ms"
exception: "NotAllowedException"
status_code: 403
日志:
请求没有正确的权限或授权。请查看我们的文档以了解如何签署请求。
我们在服务器端生成用户令牌,该令牌可以在没有to 的情况下对两个组进行读写。
// on server
stream_client.user(user.user_id).create({
name: user.name,
username: user.username,
});
帖子正文:
actor: "SU:5f40650ad9b60a00370686d7"
attachments: {images: [], files: []}
foreign_id: "post:1598391531232"
object: "Newsfeed"
text: "Yum #donuts"
time: "2020-08-25T14:38:51.232"
to: ["main_topics:donuts", "main_topics:all"]
verb: "post"
文档显示了to: ['team:barcelona', 'match:1'], 的示例,并说您需要在面板中创建提要组,但没有提及设置特定权限以使用此功能。
知道为什么会发生这种情况吗?请注意,我正在尝试创建发布此帖子时不存在的新主题(甜甜圈,全部)。但是,文档没有指定需要首先明确创建提要 - 也许这是缺少的部分?
【问题讨论】:
标签: hashtag getstream-io