Search by

aisdk / azure

aisdk

Official Azure OpenAI provider for the PHP AI SDK.

Package info

github.com/phpaisdk/azure

pkg:composer/aisdk/azure

Fund package maintenance!

Open Collective

Statistics

Installs: 18

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 1

v0.11.0 2026-10-31 02:58 UTC

This package is auto-updated.

Last update: 2026-11-03 18:51:12 UTC


README

Text generation, streaming, tools, images, audio, embeddings, and live sessions with Azure OpenAI for the PHP AI SDK.

Installation

composer require aisdk/azure

Set AZURE_OPENAI_API_KEY and AZURE_RESOURCE_NAME in your environment.

Usage

use AiSdk\Azure;
use AiSdk\Generate;

$result = Generate::text('Explain closures in PHP in one sentence.')
    ->model(Azure::model('your-deployment-name'))
    ->run();

echo $result->text;

Use the name of your Azure model deployment, rather than an OpenAI model ID. Choose a current model available in your Azure region.

Documentation

Read the documentation for configuration, supported features, and more examples.

Contributing ยท Support

License

The MIT License (MIT). See LICENSE for details.