2017 © Pedro Peláez
 

library tfs-rest-api

An api wrapper for the TFS/VisualStudio REST API

image

opensoft/tfs-rest-api

An api wrapper for the TFS/VisualStudio REST API

  • Thursday, November 12, 2015
  • by richardfullmer
  • Repository
  • 4 Watchers
  • 0 Stars
  • 18 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 1 Versions
  • 6 % Grown

The README.md

PHP TFS Rest Api

A simple object oriented wrapper for the Visual Studio Online / Team Foundation Server REST API in PHP 5.5, (*1)

Uses Guzzle 6 for REST requests., (*2)

Installation

Installable through composer via:, (*3)

$ composer require opensoft/tfs-rest-api

Basic Usage

<?php

use Opensoft\Tfs\Rest\Client;

require_once __DIR__ . '/vendor/autoload.php';

$client = new Client(
    // your tfs/vso
    'https://opensoft.visualstudio.com',
    // your collection
    'AcmeApp',
    // (optional) raw options to pass to guzzle (ntlm example here)
    [                                      
        'curl' => [
            CURLOPT_HTTPAUTH => CURLAUTH_NTLM, 
            CURLOPT_USERPWD => 'username:password'
        ]
    ]
);

// retrieve a work item by its ID
$response = $client->workItemTracking()->getWorkItem(12345);

// get the result as an array
print_r($response->asArray());

// follow hypermedia links
$response = $response->follow('workItemHistory');

print_r($response->asArray());

Caution: There are many more APIs exposed by TFS/VSO than are implemented here. We've implemented only what we've needed internally for now, and will implement more as the need arises. Feel free to submit pull requests implementing more APIs and we'll be happy to merge them., (*4)

License

Licensed under the MIT License - see the LICENSE file for details, (*5)

The Versions

12/11 2015

dev-master

9999999-dev

An api wrapper for the TFS/VisualStudio REST API

  Sources   Download

MIT

The Requires

 

The Development Requires

api rest tfs visual studio vso