Skip to main content
Help us improve Python packaging – donate today!

CLI/IRC/XMPP bot you can use to display RSS feeds.

Project Description

JSONBOT is a python3 framework you can use to program bots.

JSONBOT makes it possible to program your own module enabling your own commands and contains serveral modules that can be used to program bots.

JSONBOT has a MIT no-clause license.

install

you might need to do the following if the bot doesn’t work:

export PYTHONPATH="."
export PYTHONIOENCODING="utf-8"

download

clone the source:

hg clone https://bitbucket.org/bthate/jsonbot2
cd jsonbot2
sudo python3 setup.py install

another option is to download with pip3 and install globally:

pip3 install jsonbot --upgrade

irc

use the -i option to start an IRC bot and RSS poller:

jsonbot -z -i irc,rss -n jsonbot -s irc.freenode.net -c \#dunkbots

xmpp

use the -i xmpp option to start a XMPP bot and RSS poller:

jsonbot -i xmpp,rss -u monitor@localhost --room test@conference.localhost

users

you need to add a users origin to be able to give the bot commands, add a user with the meet command:

jsonbot meet user@server
user user@server created

to give the user a permission you can use the perm command:

jsonbot perm user@server oper
ok user@server

the default shell user is root@shell and gives access to all the commands that are available.

cli

jsonbot can be used as a command line shell program

bart@okdan:~$ jsonbot version
BOTLIB 44
JSONBOT 2.1.1

shell

use -z to enable shell mode

bart@okdan:~$ jsonbot -z
> ps
1    1s       Task(CLI.select)

>
> ls
todo log runtime feed timed shop email object user rss tomorrow
> find log
0 wakker - 1y6d
1 test - 1y5d
2 brightest idea ever ls - 1y4d
3 joint 2 of the day - 1y4d
4 what else to think of ? - 1y4d
>

commands

available commands as of jan 2018 are:

attr                     # show attributes of an object type.
begin                    # begin stopwatch.
cmds                     # show list of commands.
deleted                  # show deleted records.
delperm                  # delete permissions of an user.
ed                       # show running threads.
end                      # stop stopwatch.
exit                     # stop the program.
find                     # present a list of objects based on prompt input.
first                    # show the first record matching the given criteria.
fix                      # fix a object by loading and saving it.
last                     # show last objectect matching the criteria.
load                     # force a plugin reload.
log                      # log some text.
ls                       # show subdirs in working directory.
man                      # show descriptions of the available commands.
mbox                     # convert emails to bot objects.
meet                     # create an user record.
mods                     # show available modules.
modules                  # show available modules.
perm                     # add/change permissions of an user.
permissions              # show permissions granted to a user.
perms                    # show permission of user.
pid                      # show pid of the bot.
ps                       # show running threads.
quit                     # stop the program.
reboot                   # reboot the ldr, allowing statefull reboot (keeping connections alive).
reload                   # reload a plugin.
restore                  # set deleted=false in selected records.
rm                       # set deleted flag on objects.
rss                      # add a rss url.
shop                     # add a shopitem to the shopping list.
start                    # start a plugin.
stop                     # stop a plugin.
test                     # echo origin.
timer                    # timer command to schedule a text to be printed on a given time. stopwatch to measure elapsed time.
tinder                   # loop an command nr of times.
today                    # show last week's logged objects.
todo                     # log a todo item.
tomorrow                 # show todo items for tomorrow.
u                        # show user selected by userhost.
uptime                   # show uptime.
version                  # show version.
w                        # show user data.
week                     # show last week's logged objects.
yesterday                # show last week's logged objects.

contact

you can email me or contact me on IRC/freenode/#dunkbots.

botfather on #dunkbots irc.freenode.net

Release history Release notifications

This version
History Node

2.1.2

History Node

2.1.1

History Node

2.1

History Node

2.0.2

History Node

2.0.1

History Node

2.0

History Node

1.0.4

History Node

1.0.3

History Node

1.0.2

History Node

1.0.1

History Node

1.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
jsonbot-2.1.2.tar.gz (4.8 kB) Copy SHA256 hash SHA256 Source None Jan 23, 2018

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page