Skip to main content

A framework for generate JSON feeds

Project description

This framework is highly experimental and very likely to change significantly

feeder

feeder is a small Python framework that helps you generate JSON Feeds.

Usage

For now, install from Github with:

python3 -m pip install json-feeder

Create a directory for your new feed, the start the new feed with:

feeder startfeed

settings.py, feed.py and generate.py files will be created for you.

The following settings can be configured:

  • FEED_FUNCTION the path to a Python function that will return a list of FeedItem objects.
  • FEED_FILENAME the filename on disk for the feed. If you are using Github Pages then this should be set to out/feed.json or similar.
  • FEED_URL the remote url of the feed. This is used to ensure that duplicates are not added to the file.
  • FEED_TITLE is the title of your feed.
  • FEED_HOMEPAGE_URL is the homepage of your feed, this is optional.
  • FEED_ICON is a url to an icon that feed readers might use for your feed. Very optional.
  • FEED_VERSION defaults to "1.1" and represents the JSON Feed version.
  • FEED_MAX_ITEMS limits the number of items to output in the feed. Default is 100.

Once you've updated your settings.py and created your FEED_FUNCTION you can generate your feed by running:

python3 generate.py

Runnings Tests

python3 -m unittest discover

Project details


Download files

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

Source Distribution

json-feeder-0.1.1.tar.gz (6.2 kB view hashes)

Uploaded Source

Built Distribution

json_feeder-0.1.1-py3-none-any.whl (4.3 kB view hashes)

Uploaded Python 3

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