spryker-sdk/azure-php-client

Azure Repos client for PHP

0.2.2 2024-01-10 08:27 UTC

This package is auto-updated.

Last update: 2024-12-17 15:25:27 UTC


README

Build Status codecov Latest Stable Version Minimum PHP Version PHPStan

PHP client for Azure Repos.

Installation

Require the library in your project:

composer require spryker-sdk/azure-php-client

Usage

use SprykerAzure\Client\Plugin\Request\PersonalAccessTokenAuthPlugin;
use SprykerAzure\Client\ClientFactory;

$clientFactory = new ClientFactory();

$requestBuilder = $clientFactory->getDefaultRequestBuilder();
$requestBuilder->addRequestPlugin(new PersonalAccessTokenAuthPlugin('Personal Access Token'));

$client = $clientFactory->createClient($requestBuilder);


$response = $this->azureClientFactory->getClient()->getPullRequestApi()->createPullRequest(...);
$response = $this->azureClientFactory->getClient()->getRepositoryApi()->getRepositoryInfo(...);