Skip to main content

Python library to communicate with the Slide API.

Project description

GitHub Actions GitHub Activity GitHub Last Commit

GitHub Stars GitHub Watchers GitHub Forks

Slide API client

Python API client to utilise the lide Open Cloud or local API.

Usage

Cloud API

import asyncio
from slide import SlideCloud, get_slides

slide = SlideCloud(username="email@address.com", password="some-password")
slides = asyncio.run(get_slides(slide=slide))
print(f"Found slides: {','.join([s.device_name for s in slides])}")

Local API

import asyncio
from slide import SlideCloud, get_slide_state

slide = SlideCloud(base_url="http://192.168.1.10", device_code="some-device-code")
slide_state = asyncio.run(get_slide_state(slide=slide))
print(f"Got slide state: {slide_state}")

Environment variables

Instead of providing explicit values for username/password or device code, you could also set environment variables. The used environment variables are listed and described below.

Key Description
SLIDE_API_USERNAME Username when using the Slide Cloud API
SLIDE_API_PASSWORD Password when using the Slide Cloud API
SLIDE_API_DEVICE_CODE Device code when using the local Slide API

Installation

pip install slide-api-client

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

slide_api_client-0.1.2.tar.gz (22.8 kB view hashes)

Uploaded Source

Built Distribution

slide_api_client-0.1.2-py3-none-any.whl (24.1 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