Skip to main content

A simpler wrapper for Sunlight's Congress API

Project description

Sometimes, all you need is the data. This is the simplest possible wrapper I could make. It returns decoded JSON, with some fat trimmed. It should stay out of your way.

Usage:

>>> from sunlight import Sunlight
>>> sunlight = Sunlight(API_KEY)
>>> pelosi = sunlight.legislators.get(lastname='pelosi')
>>> print pelosi['firstname']
Nancy

This should work with any method on Sunlight’ Congress API defined here: http://services.sunlightlabs.com/docs/Sunlight_Congress_API/

See test.py for more details and examples.

Project details


Download files

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

Source Distributions

simple-sunlight-0.1.2.zip (3.4 kB view hashes)

Uploaded Source

simple-sunlight-0.1.2.tar.gz (2.3 kB view hashes)

Uploaded Source

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