stack.chat is an unofficial Python 3 library and command-line tool for Stack Exchange chat.
Using your Python 3 package manager of choice:
pip3 install stack.chat
Contributors who clone this repo can install our dev packages with pipenv:
pip install pipenv pipenv install --dev
The default config uses a temporary in-memory database and requires your
Stack Exchange credentials to be provided through environment variables.
We can see this by checking the current config with
$ stack.chat config # the default config should appear
Instead, we’ll want to use
stack.chat init --global to remember our
credentials and create a persistent local database.
$ stack.chat init --global # TODO: what happens here? # seeding database... $ stack.chat config #
We can confirm it worked with TODO:
$ stack.chat whoami --server=se
You can read the latest messages in a chat room with
$ stack.chat tail --server=se --room=1 # TODO
Certain common parameters, such as
--room, will be
saved and used as the default if you omit that parameter the next time
it’s required for a command. TODO
$ stack.chat tail --since-last --follow # ^C
$ stack.chat send "hello, world" #
More details are available from the application itself.
$ stack.chat help
The Python interface is not yet stable.
Licensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache License, Version 2.0, shall be dual licensed as above, without any additional terms or conditions.
Please see the Git commit history or this list on GitHub.