How can i rename a group with the help of discourse api?


(Siddhu Dhangar) #1

I have referred following url,
https://docs.discourse.org/#tag/Groups%2Fpaths%2F~1groups~1{name}.json%2Fput

With the help of above url, i can update a group title but i want to rename a group.
So there is any way to rename a group using discourse api.


(Jay Pfaffman) #2

See How to reverse engineer the Discourse API


(Siddhu Dhangar) #3

I did some reverse engineering, by following below steps now i can rename a group.

GET /groups/{name}.json
Firstly i get group info with the help of name
e.g GET /groups/staff.json

Then I have a group id which i already fetched using above method. Replaced below id to actual group id.
PUT /groups/{id}.json
e.g PUT /groups/12.json and includes a group name in your PUT request.

Now it is working. Thanks.