Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions docs/source/getting_started.rst
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,17 @@ Making Connections
>>> import syncano
>>> connection = syncano.connect(email='YOUR_EMAIL', password='YOUR_PASSWORD')

If you want to connect directly to chosen instance you can use :func:`~syncano.connect_instance` function::
If you want to use instance in connection you can use :func:`~syncano.connect` function,
then you can omit the instance_name in other calls::

>>> import syncano
>>> connection = syncano.connect_instance('instance_name', email='YOUR_EMAIL', password='YOUR_PASSWORD')
>>> connection = syncano.connect(instance_name='instance_name', email='YOUR_EMAIL', password='YOUR_PASSWORD')

If you have obtained your ``Account Key`` from the website you can omit ``email`` & ``password`` and pass ``Account Key`` directly to connection:

>>> import syncano
>>> connection = syncano.connect(api_key='YOUR_API_KEY')
>>> connection = syncano.connect_instance('instance_name', api_key='YOUR_API_KEY')
>>> connection = syncano.connect(instance_name='instance_name', api_key='YOUR_API_KEY')


Troubleshooting Connections
Expand Down Expand Up @@ -127,8 +128,8 @@ Each model has a different set of fields and commands. For more information chec
Next Steps
----------

If you'd like more information on interacting with Syncano, check out the :ref:`interacting tutorial<interacting>` or if you
want to know what kind of models are available check out the :ref:`available models <models>` list.
If you'd like more information on interacting with Syncano, check out the :ref:`interacting tutorial<interacting>`
or if you want to know what kind of models are available check out the :ref:`available models <models>` list.



4 changes: 1 addition & 3 deletions docs/source/interacting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,6 @@ to :meth:`~syncano.models.manager.Manager.list` method::

>>> ApiKey.please.list(instance_name='test-one')
[<ApiKey 1>...]
>>> ApiKey.please.list('test-one')
[<ApiKey 1>...]

This performs a **GET** request to ``/v1/instances/test-one/api_keys/``.

Expand All @@ -226,7 +224,7 @@ all :class:`~syncano.models.base.Instance` objects will have backward relation t
>>> instance = Instance.please.get('test-one')
>>> instance.api_keys.list()
[<ApiKey 1>...]
>>> instance.api_keys.get(1)
>>> instance.api_keys.get(id=1)
<ApiKey 1>

.. note::
Expand Down