Skip to main content

Python wrapper for the Marvel API.

Project description

https://img.shields.io/pypi/v/esak.svg?logo=PyPI&label=Version&style=flat-square:alt:PyPI https://img.shields.io/pypi/pyversions/esak.svg?logo=Python&label=Python-Versions&style=flat-square https://img.shields.io/github/license/bpepple/esak https://codecov.io/gh/Metron-Project/esak/branch/master/graph/badge.svg?token=L1EGNX24I2 https://img.shields.io/badge/Code%20Style-Black-000000.svg?style=flat-square

This project is a fork of marvelous with the goal of supporting the full Marvel API.

To install:

$ pip3 install --user esak

Example Usage:

import esak

# 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 = esak.api(public_key, private_key)

# Get all comics from this week, sorted alphabetically by title
pulls = sorted(m.comics_list({
    '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(f'{comic.title} (series #{comic.series.id})')

Documentation

Bugs/Requests

Please use the GitHub issue tracker to submit bugs or request features.

Contributing

  • 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


Download files

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

Source Distribution

esak-1.3.2.tar.gz (323.8 kB view hashes)

Uploaded Source

Built Distribution

esak-1.3.2-py3-none-any.whl (22.8 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