Python client: add an instance-by-id lookup

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: add `refresh` to Instance

Calling `refresh` on an instance makes it to fire a new request to the
Deltacloud API and update the attributes.

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: add check for valid credentials

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Add support for keypairs.

Add support for keypairs.

Signed-off-by: Ian Main <imain@redhat.com>
Woops s/dckey/key for consistency.

Signed-off-by: Ian Main <imain@redhat.com>
Workaround for a Deltacloud JSON response bug

When there is have 1 image, deltacloud returns

    {'images': {'image': { ... } }}

When you have more than one:

    {'images': [{'image': ...}, {'image': ...}]}

This breaks our client code. This commit adds a temporary workaround but
this needs to be fixed on Deltacloud's side.

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: fix discover_entrypoints

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Update Python client to new JSON response format

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Add support for modern `requests` versions

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: fix the instance key colection

The recent JSON API fixes changed the format of the key-related response
bodies, breaking the client.

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: update the ip addresses format

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: add compatibility with Python3

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Update README

Added license, updated the examples and the links in the readme. Also
switched to reStructuredText because we can then easilly include it as
`long_description` in `setup.py` and thus have it on PYPI.

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Update setup.py and MANIFEST.in

This fixes some of the outdated packaging metadata and makes the
package ready for distribution.

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Add Python client-specific .gitignore

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: add installation instructions

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Python client: use setuptools to declare dependencies

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Check for keys existing before getting them.

Signed-off-by: Ian Main <imain@redhat.com>
Python client: Add networks and subnets methods

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
Add Subnet and Network resources

Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>