I found this library: golang xmpp, and it is quite low level (exposed the details of xmpp protocol).I took some time to dig into it, but quite time consuming. Since,right now,I just need three functions:
So, can anybody tell me how to do it in this library?
I assume you want to manage an XMPP server from you backend. I would not use an XMPP bot to perform those task.
You should consider using ejabberd XMLRPC API to perform those tasks. All commands available from ejabberdctl are exposed. It means that you can control a lot of ejabberd behaviour using that API.