Use the TeamCity REST API from Python
Project description
# Pytc3 [WIP]
**This is not production Ready yet.**
[](https://pypi.python.org/pypi/pytc3/)
[](https://travis-ci.org/ageekymonk/pytc3)
Python interface to the [REST
API](https://confluence.jetbrains.com/display/TCD10/REST+API) of
[TeamCity](https://www.jetbrains.com/teamcity/)
## Installation
```
pip install pytc3
```
## Examples
### Connect to server
```python
from pytc3 import TeamCity
# This initialises the Client with the settings passed. <port> has to be an integer.
tc = TeamCity('account', 'password', 'server', <port>)
```
or specify no parameters and it will read settings from environment
variables:
- `TEAMCITY_USER`
- `TEAMCITY_PASSWORD`
- `TEAMCITY_HOST`
- `TEAMCITY_PORT` (Defaults to 80 if not set)
```python
from pytc3 import TeamCity
# Initialises with environment variables: TEAMCITY_{USER,PASSWORD,HOST,PORT}
tc = TeamCity()
```
### Getting data
You can also look at
[sample.py](https://github.com/ageekymonk/pytc3/blob/master/sample.py)
## Acknowledgements
This is a heavily-modified fork of https://github.com/SurveyMonkey/pyteamcity so many thanks are due to [SurveyMonkey](https://github.com/SurveyMonkey)
# Changes
**This is not production Ready yet.**
[](https://pypi.python.org/pypi/pytc3/)
[](https://travis-ci.org/ageekymonk/pytc3)
Python interface to the [REST
API](https://confluence.jetbrains.com/display/TCD10/REST+API) of
[TeamCity](https://www.jetbrains.com/teamcity/)
## Installation
```
pip install pytc3
```
## Examples
### Connect to server
```python
from pytc3 import TeamCity
# This initialises the Client with the settings passed. <port> has to be an integer.
tc = TeamCity('account', 'password', 'server', <port>)
```
or specify no parameters and it will read settings from environment
variables:
- `TEAMCITY_USER`
- `TEAMCITY_PASSWORD`
- `TEAMCITY_HOST`
- `TEAMCITY_PORT` (Defaults to 80 if not set)
```python
from pytc3 import TeamCity
# Initialises with environment variables: TEAMCITY_{USER,PASSWORD,HOST,PORT}
tc = TeamCity()
```
### Getting data
You can also look at
[sample.py](https://github.com/ageekymonk/pytc3/blob/master/sample.py)
## Acknowledgements
This is a heavily-modified fork of https://github.com/SurveyMonkey/pyteamcity so many thanks are due to [SurveyMonkey](https://github.com/SurveyMonkey)
# Changes
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size pytc3-0.1.1-py3-none-any.whl (14.2 kB) | File type Wheel | Python version py3 | Upload date | Hashes View |
Filename, size pytc3-0.1.1.tar.gz (13.1 kB) | File type Source | Python version None | Upload date | Hashes View |