PHP SDK
The official PHP client for the inference API, installed with Composer and generated from the OpenAPI spec.
For authentication, resources, errors and the other shared concepts, see all SDKs.
Install
PHP, via Composer:
composer require akumi-cloud/sdk
Quickstart
use Akumi\Sdk\Akumi;
$akumi = Akumi::fromApiKey($_ENV['AKUMI_API_KEY']);
$response = $akumi->chat->create([
'model' => 'mistral/mistral-small-2603',
'messages' => [
['role' => 'user', 'content' => 'Summarize this contract.'],
],
]);
In Laravel the SDK registers itself. Set AKUMI_API_KEY in your environment, then resolve the client from the container or use the Akumi facade; no manual provider wiring is needed.
Streaming
Call $akumi->chat->createStreamed([...]) for a streamed variant of the chat call that returns a Generator yielding chunks as they arrive. Pass "stream": true in the request alongside it.
Source
The PHP SDK lives in its own repository and is generated, not hand-written. When the API changes, it is regenerated from the spec.