Added baseline for sphinx documentation and on2FACode event

The docs are still very WIP, but they should be functional. Just
execute `make html` in the docs folder, and you should be able to
navigate to `/docs/_build/html` and view it in your browser
This commit is contained in:
Mads Marquart
2017-05-26 13:38:54 +02:00
parent a76ebbb22a
commit d2741ca419
26 changed files with 1191 additions and 361 deletions

52
docs/examples.rst Normal file
View File

@@ -0,0 +1,52 @@
.. highlight:: python
.. _examples:
Examples
========
These are a few examples on how to use `fbchat`. Remember to swap out `<email>` and `<password>` for your email and password
Sending messages
----------------
This will send one of each message type to the specified thread
.. literalinclude:: ../examples/send.py
:language: python
Getting information
-------------------
This will show the different ways of fetching information about users and threads
.. literalinclude:: ../examples/get.py
:language: python
Echobot
-------
This will reply to any message with the same message
.. literalinclude:: ../examples/echobot.py
:language: python
Remove bot
----------
This will remove a user from a group if they write the message `Remove me!`
.. literalinclude:: ../examples/removebot.py
:language: python
"Keep it"-bot
-------------
This will prevent chat color, emoji, nicknames and chat name from being changed. It will also prevent people from being added and removed
.. literalinclude:: ../examples/keepbot.py
:language: python