Giter VIP home page Giter VIP logo

python-pocketcasts's Introduction

python-pocketcasts

python module to interact with the unofficial Pocket Casts API.

This module is in no way affiliated with or endorsed by shifty jelly! Use at your own risk!


What works

  • Receive podcast and episode listings
  • Receive episode show notes
  • Star and unstar podcast

What is (or at least seems) off limits

Everything not doable via web player:

  • Next up
  • Playlists

I only looked at the web player's api not the android and iOS apps

TODO

  • API documentation
  • docstrings
  • Improve error handling
  • Packaging as PyPI module

Example

import pocketcasts as pc
api = pc.Api('user', 'password')::

my_podcasts = api.my_podcasts()           # get my subscribed podcasts
my_podcast[0].title                       # show first podcasts title
my_podcasts[2].unsubscribe()              # unsubscribe 3rd podcast
my_podcast[5].episodes[3].url             # get url of the 4th episode of 6th podcast

cool_podcast = api.popular_podcasts()[0]
cool_podcast.subscribe()
cool_podcast.episodes[1].starred = True
episode = cool_podcast.episodes[0]
episode.played_up_to = episode.duration / 2 # set the episode exactly half played

python-pocketcasts's People

Contributors

koalajoe23 avatar molobrakos avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

zackbcom

python-pocketcasts's Issues

403 Client Error

Using the module seems no longer be possible.

>>> import pocketcasts as pc
>>> api = pc.Api('the_username', 'the_passwrod')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/fab/Documents/repos/ha/home-assistant/lib64/python3.6/site-packages/pocketcasts/api.py", line 18, in __init__
    response.raise_for_status()
  File "/home/fab/Documents/repos/ha/home-assistant/lib64/python3.6/site-packages/requests/models.py", line 939, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://play.pocketcasts.com/users/sign_in

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.