William Lee
William Lee

Reputation: 1

How to create a chat room and add users into the room in openfire using Python REST API

I'm using this module Openfire REST API

I write the main.py import muc.py

from ofrestapi.muc import Muc
m = Muc(host = 'http://desktop-oam4s7o:9090', secret = 'poYixzhOJsPmB4tB')
m.add_room(roomname = 'test', name = 'test', description = 'test')

But it's failed, I encountered an exception:

ofrestapi.exception.InvalidResponseException: 500

Can anybody have some sample Python for MUC service to create chat room and adding users into the chat room?

Upvotes: 0

Views: 312

Answers (1)

see this sample code in github maybe help you, this is command line interface for Openfire RestAPI: https://github.com/seamus-45/openfire-cli

Upvotes: 0

Related Questions