]>
Commit | Line | Data |
---|---|---|
7364ea65 | 1 | """ |
2 | The minimalist yet fully featured Twitter API and Python toolset. | |
3 | ||
24950891 MV |
4 | The Twitter and TwitterStream classes are the key to building your own |
5 | Twitter-enabled applications. | |
5f47b302 | 6 | |
7364ea65 | 7 | """ |
8 | ||
a6a7f763 MV |
9 | from textwrap import dedent |
10 | ||
f7e63802 | 11 | from .api import Twitter, TwitterError, TwitterHTTPError, TwitterResponse |
24950891 | 12 | from .auth import NoAuth, UserPassAuth |
c2176d4e MV |
13 | from .oauth import ( |
14 | OAuth, read_token_file, write_token_file, | |
15 | __doc__ as oauth_doc) | |
16 | from .oauth2 import ( | |
17 | OAuth2, read_bearer_token_file, write_bearer_token_file, | |
18 | __doc__ as oauth2_doc) | |
dd648a25 | 19 | from .stream import TwitterStream |
c2176d4e | 20 | from .oauth_dance import oauth_dance, oauth2_dance |
24950891 | 21 | |
ede8b119 | 22 | __doc__ = __doc__ or "" |
24950891 MV |
23 | |
24 | __doc__ += """ | |
25 | The Twitter class | |
51e0b8f1 | 26 | ----------------- |
24950891 | 27 | """ |
ede8b119 | 28 | __doc__ += dedent(Twitter.__doc__ or "") |
24950891 MV |
29 | |
30 | __doc__ += """ | |
31 | The TwitterStream class | |
51e0b8f1 | 32 | ----------------------- |
24950891 | 33 | """ |
ede8b119 | 34 | __doc__ += dedent(TwitterStream.__doc__ or "") |
24950891 MV |
35 | |
36 | ||
37 | __doc__ += """ | |
38 | Twitter Response Objects | |
51e0b8f1 | 39 | ------------------------ |
24950891 | 40 | """ |
ede8b119 | 41 | __doc__ += dedent(TwitterResponse.__doc__ or "") |
24950891 MV |
42 | |
43 | ||
44 | __doc__ += """ | |
a6a7f763 | 45 | Authentication |
51e0b8f1 | 46 | -------------- |
24950891 MV |
47 | |
48 | You can authenticate with Twitter in three ways: NoAuth, OAuth, or | |
c2176d4e | 49 | OAuth2 (app-only). Get help() on these classes to learn how to use them. |
24950891 | 50 | |
c2176d4e | 51 | OAuth and OAuth2 are probably the most useful. |
24950891 | 52 | |
24950891 | 53 | |
a6a7f763 | 54 | Working with OAuth |
51e0b8f1 | 55 | ------------------ |
24950891 MV |
56 | """ |
57 | ||
ede8b119 | 58 | __doc__ += dedent(oauth_doc or "") |
a6a7f763 | 59 | |
c2176d4e MV |
60 | __doc__ += """ |
61 | Working with OAuth2 | |
62 | ------------------- | |
63 | """ | |
64 | ||
65 | __doc__ += dedent(oauth2_doc or "") | |
66 | ||
67 | __all__ = [ | |
68 | "NoAuth", | |
69 | "OAuth", | |
70 | "OAuth2", | |
71 | "oauth2_dance", | |
72 | "oauth_dance", | |
73 | "read_bearer_token_file", | |
74 | "read_token_file", | |
75 | "Twitter", | |
76 | "TwitterError", | |
77 | "TwitterHTTPError", | |
78 | "TwitterResponse", | |
79 | "TwitterStream", | |
80 | "UserPassAuth", | |
81 | "write_bearer_token_file", | |
82 | "write_token_file", | |
83 | ] |