Django implementation for Twitter API
Project description
# Django Twitter API
[![Build Status](https://travis-ci.org/ramusus/django-twitter-api.png?branch=master)](https://travis-ci.org/ramusus/django-twitter-api) [![Coverage Status](https://coveralls.io/repos/ramusus/django-twitter-api/badge.png?branch=master)](https://coveralls.io/r/ramusus/django-twitter-api)
Application for interacting with Twitter API objects using Django model interface
## Installation
pip install django-twitter-api
Add into `settings.py` lines:
INSTALLED_APPS = (
...
'oauth_tokens',
'twitter-api',
)
# oauth-tokens settings
OAUTH_TOKENS_HISTORY = True # to keep in DB expired access tokens
OAUTH_TOKENS_TWITTER_CLIENT_ID = '' # application ID
OAUTH_TOKENS_TWITTER_CLIENT_SECRET = '' # application secret key
OAUTH_TOKENS_TWITTER_USERNAME = '' # user login
OAUTH_TOKENS_TWITTER_PASSWORD = '' # user password
## Usage examples
### Simple API Graph request
>>> from facebook_api.utils import graph
>>> graph('zuck')
Node(<Graph(u'https://graph.facebook.com/zuck') at 0xb1cbfac>,
{'first_name': 'Mark',
'gender': 'male',
'id': '4',
'last_name': 'Zuckerberg',
'link': 'http://www.facebook.com/zuck',
'locale': 'en_US',
'name': 'Mark Zuckerberg',
'updated_time': '2013-03-13T20:36:43+0000',
'username': 'zuck'})
>>> graph('zuck', fields='id,name')
Node(<Graph(u'https://graph.facebook.com/zuck') at 0xb1d2a8c>,
{'id': '4', 'name': 'Mark Zuckerberg'})
[![Build Status](https://travis-ci.org/ramusus/django-twitter-api.png?branch=master)](https://travis-ci.org/ramusus/django-twitter-api) [![Coverage Status](https://coveralls.io/repos/ramusus/django-twitter-api/badge.png?branch=master)](https://coveralls.io/r/ramusus/django-twitter-api)
Application for interacting with Twitter API objects using Django model interface
## Installation
pip install django-twitter-api
Add into `settings.py` lines:
INSTALLED_APPS = (
...
'oauth_tokens',
'twitter-api',
)
# oauth-tokens settings
OAUTH_TOKENS_HISTORY = True # to keep in DB expired access tokens
OAUTH_TOKENS_TWITTER_CLIENT_ID = '' # application ID
OAUTH_TOKENS_TWITTER_CLIENT_SECRET = '' # application secret key
OAUTH_TOKENS_TWITTER_USERNAME = '' # user login
OAUTH_TOKENS_TWITTER_PASSWORD = '' # user password
## Usage examples
### Simple API Graph request
>>> from facebook_api.utils import graph
>>> graph('zuck')
Node(<Graph(u'https://graph.facebook.com/zuck') at 0xb1cbfac>,
{'first_name': 'Mark',
'gender': 'male',
'id': '4',
'last_name': 'Zuckerberg',
'link': 'http://www.facebook.com/zuck',
'locale': 'en_US',
'name': 'Mark Zuckerberg',
'updated_time': '2013-03-13T20:36:43+0000',
'username': 'zuck'})
>>> graph('zuck', fields='id,name')
Node(<Graph(u'https://graph.facebook.com/zuck') at 0xb1d2a8c>,
{'id': '4', 'name': 'Mark Zuckerberg'})
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
django-twitter-api-0.1.1.tar.gz
(29.4 kB
view details)
File details
Details for the file django-twitter-api-0.1.1.tar.gz
.
File metadata
- Download URL: django-twitter-api-0.1.1.tar.gz
- Upload date:
- Size: 29.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 72b378e99f0a08fef34f3323d97421afd9eeb565d658320b1307b0aed8dbadf7 |
|
MD5 | 1aa771450e03bc0e1bb391b20b0bd92a |
|
BLAKE2b-256 | 90b71e632a02e9082432dda18de4f855732e251195693f9845bc37c4713de3a4 |