]> jfr.im git - z_archive/twitter.git/blame - twitter/__init__.py
Improve documentation wrt OAuth.
[z_archive/twitter.git] / twitter / __init__.py
CommitLineData
7364ea65 1"""
2The minimalist yet fully featured Twitter API and Python toolset.
3
24950891
MV
4The Twitter and TwitterStream classes are the key to building your own
5Twitter-enabled applications.
5f47b302 6
7364ea65 7"""
8
a6a7f763
MV
9from textwrap import dedent
10
f7e63802 11from .api import Twitter, TwitterError, TwitterHTTPError, TwitterResponse
24950891 12from .auth import NoAuth, UserPassAuth
a6a7f763
MV
13from .oauth import (OAuth, read_token_file, write_token_file,
14 __doc__ as oauth_doc)
dd648a25 15from .stream import TwitterStream
a6a7f763 16from .oauth_dance import oauth_dance
24950891
MV
17
18# Who needs Sphinx? Not me!
19
20__doc__ += """
21The Twitter class
22=================
23"""
a6a7f763 24__doc__ += dedent(Twitter.__doc__)
24950891
MV
25
26__doc__ += """
27The TwitterStream class
28=======================
29"""
a6a7f763 30__doc__ += dedent(TwitterStream.__doc__)
24950891
MV
31
32
33__doc__ += """
34Twitter Response Objects
35========================
36"""
a6a7f763 37__doc__ += dedent(TwitterResponse.__doc__)
24950891
MV
38
39
40__doc__ += """
a6a7f763
MV
41Authentication
42==============
24950891
MV
43
44You can authenticate with Twitter in three ways: NoAuth, OAuth, or
45UserPassAuth. Get help() on these classes to learn how to use them.
46
a6a7f763 47OAuth is probably the most useful.
24950891 48
24950891 49
a6a7f763
MV
50Working with OAuth
51==================
24950891
MV
52"""
53
a6a7f763
MV
54__doc__ += dedent(oauth_doc)
55
24950891
MV
56__all__ = ["Twitter", "TwitterStream", "TwitterResponse", "TwitterError",
57 "TwitterHTTPError", "NoAuth", "OAuth", "UserPassAuth",
a6a7f763 58 "read_token_file", "write_token_file", "oauth_dance"]