Fixed some bugs in streams
[diaspy.git] / README.md
CommitLineData
f2eaa3c7
MM
1#### Python API for Diaspora (unofficial)
2
3`diaspy` is a set of modules which form API for D\* social network.
c8b0cc01
MM
4The API is written in Python and should be both 3.x and 2.x compatible.
5Test suite will cause problems when run with 2.x so testing should be done
6using python3 interpreter.
f2eaa3c7
MM
7
8Object oriented design of `diaspy` makes it easily reusable by other
9developers who want to use only part of the API.
10
11----
12
13#### Quick intro
14
15#### 1. Posting text to your stream
16
17You only need two objects to do this: `Stream()` and `Connection()`.
18
19 >>> import diaspy
20 >>> c = diaspy.connection.Connection(pod='https://pod.example.com',
21 ... username='foo',
22 ... password='bar')
23 >>> c.login()
24 >>> stream = diaspy.models.Stream(c)
25 >>> stream.post('Your first post')
26
27
28#### 2. More features
29
30There is a special `client` module in diaspy which is an example client
31of D\* written using the `diapsy` API. It provides many features useful for
32interactions with social network like messages, mentions, likes etc.
33It is full of good, useful stuff.
34
35----
36
37To get more information about how the code works read
38documentation (`./doc/` directory) and manual (`./manual/` directory).