Marvel API python wrapper.
Project description
Links:
To install:
pip install marvelous
Example Usage:
import marvelous
# Your own config file to keep your private key local and secret
from config import public_key, private_key
# Authenticate with Marvel, with keys I got from http://developer.marvel.com/
m = marvelous.api(public_key, private_key)
# Get all comics from this week, sorted alphabetically by title
pulls = sorted(m.comics({
'format': "comic",
'formatType': "comic",
'noVariants': True,
'dateDescriptor': "thisWeek",
'limit': 100}),
key=lambda comic: comic.title)
for comic in pulls:
# Write a line to the file with the name of the issue, and the
# id of the series
print('{} (series #{})'.format(comic.title, comic.series.id))
Output available in full documentation
Contributing
To run the test suite, run python -m nose in the tests folder
When running a new test for the first time, set the environment variables PUBLIC_KEY and PRIVATE_KEY to any Marel API keys. The result will be stored in the tests/testing_mock.sqlite database without your keys.
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
marvelous-1.0.0.tar.gz
(5.1 kB
view details)
File details
Details for the file marvelous-1.0.0.tar.gz.
File metadata
- Download URL: marvelous-1.0.0.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
903ff0846dc31ac0752788cbce49ef72d6fbd4625db059db5dcc3bb3246aa0d5
|
|
| MD5 |
7b9bd8d49da6acc8aa9428e68f38f4be
|
|
| BLAKE2b-256 |
04031a0f9608bea75a12cfad8de170d39b3a342d309c44f182568b2810dfbb1c
|