A python client for interacting with the MicroServices
pip install microclient
Target Pythons is: 2.7, 3.4
#clone the repo:
[email protected]:TangentMicroServices/PythonClient.git
virtualenv env
# use virtualenv-3.4 fr python 3
run the unit tests
nosetests
Run the integration tests
nosetests microclient/integration_ITCase.py -s
Run specific test case
nosetests microclient/integration_ITCase.py:EntryFetcherTestCase.test_get_entries -s
For detailed examples see the tests
The process will be the same for any service. Using project service as an example
Authentication with a token
from microservice.clients import ProjectService
service = ProjectService(token=mytoken)
Authentication with username and password
from microservice.clients import ProjectService
service = ProjectService()
response = service.authenticate(username=user, password=pass)
is_logged_in, token = service.login(response)
...