Skip to content

AlbertSuarez/chromecast-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chromecast API

HitCount Python application GitHub stars GitHub forks GitHub contributors GitHub license Open Source Love

📺 Chromecast API within your local network

API Endpoint | API Documentation | Swagger UI


Animation


Motivation

The idea of this project was to play a bit with the awesome PyChromecast Python library and move its functionalities to a the black box concept of an API.

Currently the implemented API, at port 8321, is able to list all the available devices within the local network and cast a source given the device name and a URL with some media. Optionally, you can set source_url=random for being surprised with one of the gallery videos.

http://localhost:8321/play?source=CHROMECAST_NAME&source_url=random

Apart from its functionality, an API documentation (using ReDoc) and the typical Swagger UI are available at the following URLs.


API Documentation Swagger UI


Requirements

  1. Python 3.7+

Recommendations

Usage of virtualenv is recommended for package library / runtime isolation.

Usage

To run the API, please execute the following commands from the root directory:

  1. Setup virtual environment

  2. Install dependencies

    pip3 install -r requirements.lock
  3. Run the server as a uWSGI server with the given bash script

    ./run.sh

    or as a Python module

    python3 -m src

Authors

License

MIT © Chromecast API

Releases

No releases published

Sponsor this project

 

Packages

No packages published