The python egg for cine.io.
install cine_io via pip:
pip install cine_io
import cine_io
client = cine_io.Client({"secretKey": "CINE_IO_SECRET_KEY"})
client = cine_io.Client({"secretKey": "CINE_IO_SECRET_KEY", "masterKey": "CINE_IO_MASTER_KEY"})
To get data about your projects:
project = client.projects.index()
# => [cine_io.Project, …]
To get data about your project:
project = client.project.get()
# => cine_io.Project
To update your project:
project = client.project.update({"name": 'new project name'})
# => cine_io.Project
To delete your project:
deleted_at = client.project.delete()
# => String of datetime when the project was deleted
To get all your streams:
streams = client.streams.index()
streams = client.streams.index({"name": "my custom name"})
# => [cine_io.Stream, …]
To get a specific stream:
stream = client.streams.get('STREAM_ID')
# => cine_io.Stream
To create a new stream:
stream = client.streams.create()
# => cine_io.Stream
# you can optionally pass params
# params
# name: 'a stream name'
# record: True|False (default False). record: True will save recordings of all streaming sessions
stream = client.streams.create({"name": 'new stream name'})
# => cine_io.Stream
To update a specific stream:
# params:
# 'name': 'some stream name'
# record: True|False (updating a stream from true to false will not delete old stream recordings)
stream = client.streams.update('STREAM_ID', params)
# => cine_io.Stream
To fetch the Flash Media Live Encoder profile for a stream:
stream = client.streams.fmle_profile('STREAM_ID')
# => String of profile contents
To delete a stream:
stream = client.streams.delete('STREAM_ID')
# => String of datetime when the stream was deleted
To get all the recordings of stream:
recordings = client.streams.recordings.index('STREAM_ID')
# => [cine_io.StreamRecording, …]
To delete a recordings of stream:
recordings = client.streams.recordings.delete('STREAM_ID', 'recordingName')
# => String of datetime when the stream recording was deleted
var identity = "Unique user name to your app"
response = client.peer.generate_identity_signature(identity)
# response looks like {'signature': "sha1-hash", 'timestamp': 1420258111, 'identity': "Unique user name to your app"}
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request