Ejabberd api using subscribe room

347 Views Asked by At

In ejabberd api, i can fill user,nick,room, but how can i fill the nodes? Is there any example. Thank you.

POST /api/subscribe_room

{
  "user": "aaaaa",
  "nick": "bbbbb",
  "room": "ccccc",
  "nodes": "ddddd"
}

HTTP/1.1 200 OK [ "aaaaa", "bbbbb" ]

My example :

{
  "user":"muuser",
  "nick":"ccccdd",
  "room":"myRoom",
  "nodes": ["urn:xmpp:mucsub:nodes:presence","urn:xmpp:mucsub:nodes:messages","urn:xmpp:mucsub:nodes:affiliations","urn:xmpp:mucsub:nodes:subject", "urn:xmpp:mucsub:nodes:config","urn:xmpp:mucsub:nodes:system"] 
}
1

There are 1 best solutions below

0
On

as explained here nodes attribute is filled like so :

nodes : "urn:xmpp:mucsub:nodes:messages,urn:xmpp:mucsub:nodes:affiliations"