Skip to main content
Help us improve PyPI by participating in user testing. All experience levels needed!

a python client library for easy leaseweb api access

Project description

https://travis-ci.org/nrocco/lswapi.svg?branch=master

python module to talk to LeaseWeb’s API.

For more information refer to the documentation available at [http://developer.leaseweb.com]

Installation

Install the module using pip:

pip install lswapi

Usage

The lswapi.get_leaseweb_api function creates an instance of the LeaseWeb Api object with the X-Lsw-Auth key. You can provide the api key as an argument to get_leaseweb_api:

$ python
>>> import lswapi
>>> client = lswapi.get_leaseweb_api(api_key="xxxx-xxx-xxxxxx")
>>> client.get("/v1/bareMetals")

or as an environment variable LSW_API_KEY:

$ LSW_API_KEY=xxxx-xxxx-xxxxx python
>>> import lswapi
>>> client = lswapi.get_leaseweb_api()
>>> client.get("/v1/bareMetals")

Contribute

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am ‘Add some feature’)
  4. Make sure that tests pass (make test)
  5. Push to the branch (git push origin my-new-feature)
  6. Create new Pull Request

Project details


Release history Release notifications

This version
History Node

0.3.5

History Node

0.3.4

History Node

0.3.3

History Node

0.3.2

History Node

0.3.1

History Node

0.3.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
lswapi-0.3.5.tar.gz (7.6 kB) Copy SHA256 hash SHA256 Source None Feb 16, 2018

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page