NAME

WebService::TeamCity - Client for the TeamCity REST API

VERSION

version 0.04

SYNOPSIS

use WebService::TeamCity;

my $client = WebService::TeamCity->new(
    scheme   => 'https',
    host     => 'tc.example.com',
    port     => 8123,
    user     => 'tc-user',
    password => 'tc-password',
);

my $projects = $client->projects;
for my $project ( @{$projects} ) {
    say $project->id;
    for my $build_type ( @{ $project->build_types } ) {
        say $build_type->id;
    }
}

my $projects = $client->projects;
for my $project ( @{$projects} ) {
    ...;
}

DESCRIPTION

This distribution provides a client for the TeamCity REST API.

Currently, this client targets the TeamCity 9.1 release exclusively. It is also quite incomplete and only supports read operations. Pull requests are very welcome!

The entry point for the API is this module, WebService::TeamCity. Once you have an object of that class, you can use it to get at various other objects provided by the API.

INSTABILITY WARNING

This distribution is still in its early days and its API may change without warning in future releases.

API

This module provides the top-level client for the API.

WebService::TeamCity->new(...)

This method takes named parameters to construct a new TeamCity client.

$client->projects(...)

Returns an array reference of WebService::TeamCity::Entity::Project objects. This contains all the projects defined on the TeamCity server.

You can pass arguments as key/value pairs to limit the projects returned:

$client->build_types

Returns an array reference of WebService::TeamCity::Entity::BuildType objects. This contains all the build types defined on the TeamCity server.

You can pass arguments as key/value pairs to limit the build types returned:

$client->builds

Returns a WebService::TeamCity::Iterator which returns WebService::TeamCity::Entity::Build objects.

You can pass arguments as key/value pairs to limit the projects returned:

SUPPORT

Bugs may be submitted through https://github.com/maxmind/WebService-TeamCity/issues.

AUTHOR

Dave Rolsky autarch@urth.org

CONTRIBUTORS

COPYRIGHT AND LICENSE

This software is copyright (c) 2018 by MaxMind, Inc.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.