Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dedaldino3d/ejabberd-python3d

Execute ejabberd commands, register users, etc. Later will be possible to set a custom authentication
https://github.com/dedaldino3d/ejabberd-python3d

django-ejabberd ejabberd erlang python xml-rpc xmpp

Last synced: about 1 month ago
JSON representation

Execute ejabberd commands, register users, etc. Later will be possible to set a custom authentication

Awesome Lists containing this project

README

        

**A python lib to run ejabberd XML-RPC commands**

**Features**


  • Execute XML-RPC commands

  • External authentication

  • Register Users

  • Delete Users

  • Create Rooms

  • Subscribe to Rooms

  • Send Messages

  • and many others features, ... .

#### How to install
When working with python its a common approach to use a virtualenv to encapsulate all dependencies.
First create a virtual environment:
__if you have virtualenv installed run this code__
```python
virtualenv ejabberd_python3d_venv
```
__if not, so install with this code:__
````python
pip install virtualenv
````
and then install **ejabberd_python3d** lib:
```python
pip install ejabberd_python3d
```

To get the most updated version, you'll need to clone this repository:
````git
git clone http://github.com/Dedaldino3D/ejabberd_python3d.git
````
Run
````python
python setup.py
````

After installation is completed, create a client instance:

````python
from ejabberd_python3d.client import EjabberdAPIClient

client = EjabberdAPIClient('localhost','dedaldino','123456')
users = client.registered_users('localhost')
# assuming that you have an user registered (the admin)
print(users) # [dedaldino]
client.register('dedaldino3d','localhost','nopassword')
users = client.registered_users('localhost')
print(users) # ['dedaldino3d']
````