Python API to utilise the goslide.io Open Cloud API
Project description
GoSlide Open Cloud API
Python API to utilise the GoSlide Open Cloud JSON API
Requirements
- Python >= 3.5.2
Usage
import asyncio
from goslideapi import GoSlideCloud
loop = asyncio.get_event_loop()
goslide = GoSlideCloud('email', 'password')
login = loop.run_until_complete(goslide.login())
if login:
# Get the slide list
slides = loop.run_until_complete(goslide.slidesoverview())
if slides:
for slidedev in slides:
print(slidedev['device_id'], slidedev['device_name'])
print(' ', slidedev['device_info']['pos'])
else:
print('Something went wrong while retrieving the slide information')
# Open slide with id 1
result = loop.run_until_complete(goslide.slideopen(1))
if result:
print('Succesfully opened slide 1')
else:
print('Failed opened slide 1')
# Close slide with id 1
result = loop.run_until_complete(goslide.slideclose(1))
loop.run_until_complete(goslide.logout())
else:
print('login failed')
TODO:
- Test with a real slide (awaiting delivery ;-))
- Expose more API functions
License
Apache License 2.0
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
goslide-api-0.0.2.tar.gz
(3.4 kB
view hashes)
Built Distribution
Close
Hashes for goslide_api-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3640dc660a97dfcbc7180efa29c827650b8d88e79a7d7e9ddb5efe7c0b4c01d1 |
|
MD5 | 0ad8770983c442da4a583032d8ac8076 |
|
BLAKE2b-256 | f6257172d4c3888d33262296fdf9a3428817ce736bc586d2ebd60bfa0e82e578 |