PHPackages                             papi-ai/azure-openai - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. papi-ai/azure-openai

ActiveLibrary[API Development](/categories/api)

papi-ai/azure-openai
====================

Azure OpenAI provider for PapiAI

v0.9.1(1mo ago)00MITPHPPHP ^8.2CI passing

Since Mar 7Pushed 1mo agoCompare

[ Source](https://github.com/papi-ai/azure-openai)[ Packagist](https://packagist.org/packages/papi-ai/azure-openai)[ RSS](/packages/papi-ai-azure-openai/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (4)Versions (3)Used By (0)

Azure OpenAI Provider for PapiAI
================================

[](#azure-openai-provider-for-papiai)

[![CI](https://github.com/papi-ai/azure-openai/workflows/CI/badge.svg)](https://github.com/papi-ai/azure-openai/actions?query=workflow%3ACI) [![Latest Version](https://camo.githubusercontent.com/659a59933bacbdea1cbb1c5b8c87642585dc56bcba3de2f9b7cc9a6b8374ae14/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f706170692d61692f617a7572652d6f70656e61692e737667)](https://packagist.org/packages/papi-ai/azure-openai) [![Total Downloads](https://camo.githubusercontent.com/f4312d8e638b26988ca9338dd4fe178bf489444b82e52f7d223862760beec9db/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f706170692d61692f617a7572652d6f70656e61692e737667)](https://packagist.org/packages/papi-ai/azure-openai) [![PHP Version](https://camo.githubusercontent.com/ed24158712786d4d227479a44916845e59743be308f9808410161d00caa23d04/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f706170692d61692f617a7572652d6f70656e61692e737667)](https://packagist.org/packages/papi-ai/azure-openai) [![License](https://camo.githubusercontent.com/e90691a04b89240bca962b28005e9894f2a60a904dc6187eef3250c4884f6ad4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f706170692d61692f617a7572652d6f70656e61692e737667)](https://packagist.org/packages/papi-ai/azure-openai)

Azure OpenAI provider with AAD auth support for the PapiAI agent library.

Installation
------------

[](#installation)

```
composer require papi-ai/azure-openai
```

Usage
-----

[](#usage)

```
use PapiAI\AzureOpenAI\AzureOpenAIProvider;
use PapiAI\Core\Message;

$provider = new AzureOpenAIProvider(
    apiKey: 'your-azure-api-key-or-aad-token',
    endpoint: 'https://myresource.openai.azure.com',
    deployment: 'gpt-4o',
);

$response = $provider->chat([
    Message::system('You are a helpful assistant.'),
    Message::user('Hello!'),
]);

echo $response->text;
```

Embeddings
----------

[](#embeddings)

```
$response = $provider->embed('Hello world', [
    'model' => 'text-embedding-ada-002',
]);

$vector = $response->first();
```

License
-------

[](#license)

MIT

###  Health Score

36

—

LowBetter than 81% of packages

Maintenance95

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

2

Last Release

59d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/126c34b4dff8d42336ea07ac5297bcc3ec0a0e306fd964a7497f02240da4b142?d=identicon)[md](/maintainers/md)

---

Top Contributors

[![MarcelloDuarte](https://avatars.githubusercontent.com/u/144535?v=4)](https://github.com/MarcelloDuarte "MarcelloDuarte (6 commits)")

###  Code Quality

TestsPest

Static AnalysisPsalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/papi-ai-azure-openai/health.svg)

```
[![Health](https://phpackages.com/badges/papi-ai-azure-openai/health.svg)](https://phpackages.com/packages/papi-ai-azure-openai)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M475](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M270](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M186](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M33](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M452](/packages/google-gax)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
