@@ -8,14 +8,12 @@ OpenTok Python SDK
88The OpenTok Python SDK lets you generate
99`sessions <http://tokbox.com/opentok/tutorials/create-session/ >`_ and
1010`tokens <http://tokbox.com/opentok/tutorials/create-token/ >`_ for `OpenTok <http://www.tokbox.com/ >`_
11- applications. This version of the SDK also includes support for working with OpenTok 2.0 archives.
11+ applications. This version of the SDK also includes support for working with OpenTok 2.0 archives
12+ (see http://tokbox.com/#archiving).
1213
1314
14- Installation
15- ------------
16-
17- Pip (recommended):
18- ~~~~~~~~~~~~~~~~~~
15+ Installation using Pip (recommended):
16+ -------------------------------------
1917
2018Pip helps manage dependencies for Python projects using the PyPI index. Find more info here:
2119http://www.pip-installer.org/en/latest/
@@ -29,12 +27,6 @@ Next, install the dependencies::
2927
3028 $ pip install -r requirements.txt
3129
32- Manually:
33- ~~~~~~~~~
34-
35- Download the latest package zip from the `Releases page
36- <https://github.com/opentok/Opentok-Python-SDK/releases> `_
37-
3830
3931Usage
4032-----
@@ -56,16 +48,17 @@ Creating Sessions
5648
5749The create an OpenTok Session, use the ``opentok.create_session() `` method. There are two optional
5850keyword parameters for this method: ``location `` which can be set to a string containing an IP
59- address, and ``p2p `` which is a boolean. This method returns a ``Session `` object. Its
60- ``session_id `` attribute is useful when saving to a persistent store (e.g. database).
51+ address, and ``media_mode `` which is a String (defined by the MediaModes class). This method returns
52+ a ``Session `` object. Its ``session_id `` attribute is useful when saving to a persistent store (such
53+ as a database).
6154
6255.. code :: python
6356
6457 # Just a plain Session:
6558 session = opentok.create_session()
6659 # A Session that attempts to send streams directly between clients (falling back
6760 # to use the OpenTok TURN server to relay streams if the clients cannot connect):
68- session = opentok.create_session(mediaMode = MediaModes.relayed)
61+ session = opentok.create_session(media_mode = MediaModes.relayed)
6962 # A Session with a location hint
7063 session = opentok.create_session(location = u ' 12.34.56.78' )
7164
@@ -180,6 +173,11 @@ Important changes in v2.0
180173This version of the SDK includes support for working with OpenTok 2.0 archives. (This API does not
181174work with OpenTok 1.0 archives.)
182175
176+ The OpenTok.create_session() method now includes a media_mode parameter, instead of a p2p parameter.
177+
178+ For details, see the reference documentation at
179+ <http://www.tokbox.com/opentok/libraries/server/python/reference/index.html>.
180+
183181Development and Contributing
184182----------------------------
185183
0 commit comments