I have been reviewing the API documentation and can not seem to find how I can edit user information other than email and avatar. For example firstname, lastname, and more importantly custom fields.
Can someone please help.
Thank you.
I have been reviewing the API documentation and can not seem to find how I can edit user information other than email and avatar. For example firstname, lastname, and more importantly custom fields.
Can someone please help.
Thank you.
You can learn the API request for that using How to reverse engineer the Discourse API
This is at least twice in as many days that this has been the answer to a question. That link really needs to be at the top of the docs.
I agree, if there is a docs document it is kind of assumed it is complete and if not it would be good to mention it.
对于这个话题,@hjalali 是否有任何详细的解决方案?
这个话题有帮助吗?
docs.discourse.org 现在有一条消息:
注意:对于未列出的任何端点,您可以遵循 逆向工程 Discourse API 指南来找出如何使用 API 端点。
但我们会不时尝试更新它,使其更完整。
@philipp96,您是否查看了 https://meta.discourse.org/t/how-to-reverse-engineer-the-discourse-api/20576?理解此类操作的完成方式非常简单。一旦您学会了如何操作,这真的只需要几秒钟。:)
关于自定义字段的问题:
打开浏览器开发者工具的网络选项卡。
更新您用户个人资料中的一个字段。
在网络选项卡的“名称”部分查看 [your username].json(您也可以按 json 字符串进行过滤)。
点击右侧的“Payload”选项卡。
您请求正文中发送的所有数据都写在这里:
其他请求的过程也相同。
4 个帖子已拆分为新主题:在个人资料填写过程中动态更新可用用户字段值