Skip to main content

Signals for posting messages on Facebook and Twitter.

Project description

Signals for posting messages on Facebook and Twitter.

Requirements

  • Django

  • facepy

  • python-twitter

Installation

Using PyPI you can simply type into a terminal:

pip install django-social-poster

or:

easy_install django-social-poster

Configuration

Add social_poster to the list of INSTALLED_APPS in your settings.py file.

Following settings are required:

Twitter

  • TWITTER_CONSUMER_KEY

  • TWITTER_CONSUMER_SECRET

  • TWITTER_ACCESS_TOKEN_KEY

  • TWITTER_ACCESS_TOKEN_SECRET

You have to create a new Twitter application. After creating one, the four required strings are in the details tab. Please make sure that the application can write. You can set the permissions in the settings tab.

Facebook

  • FACEBOOK_ACCESS_TOKEN: You can get the required access token at the Graph Explorer

In your models, you have to create a new model which inherits from social_poster.models.AbstractSocialPoster. Please override twitter_message and facebook_message, because they are empty. Don’t forget to sync your database!

Last but not least, add signals:

from social_poster import signals
models.signals.post_save.connect(signals.post_to_twitter,
                                 sender=MyModel)
models.signals.post_save.connect(signals.post_to_facebook,
                                 sender=MyModel)

Author

Copyright 2013 Raphael Jasjukaitis <webmaster@raphaa.de>

Released under the BSD license.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-social-poster-0.1.tar.gz (3.8 kB view details)

Uploaded Source

File details

Details for the file django-social-poster-0.1.tar.gz.

File metadata

File hashes

Hashes for django-social-poster-0.1.tar.gz
Algorithm Hash digest
SHA256 3637451275332de3220e72e1f8a520317879c5947d8a834ea728020f92a7b5a3
MD5 e99ea4377a0422b98dedc3bfeb44aa51
BLAKE2b-256 9f0b26331c4859fae3cc3de0045b8b595cfe58eca316e299a0dccdd55427a13b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page