flyo / nitro-php
Flyo Nitro PHP SDK
1.0.1
2024-08-23 15:16 UTC
Requires
- php: ^7.4 || ^8.0
- ext-curl: *
- ext-json: *
- ext-mbstring: *
- guzzlehttp/guzzle: ^7.3
- guzzlehttp/psr7: ^1.7 || ^2.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.5
- phpunit/phpunit: ^8.0 || ^9.0
README
未提供描述(由 Openapi Generator 生成 https://github.com/openapitools/openapi-generator)
入门指南
安装库
composer require flyo/nitro-php
基本用法
<?php require_once(__DIR__ . '/vendor/autoload.php'); // Configure API key authorization: ApiKeyAuth $config = Flyo\Configuration::getDefaultConfiguration()->setApiKey('token', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = Flyo\Configuration::getDefaultConfiguration()->setApiKeyPrefix('token', 'Bearer'); $apiInstance = new Flyo\Api\ConfigApi( // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`. // This is optional, `GuzzleHttp\Client` will be used as default. new GuzzleHttp\Client(), $config ); try { $result = $apiInstance->config(); print_r($result); } catch (Exception $e) { echo 'Exception when calling ConfigApi->config: ', $e->getMessage(), PHP_EOL; }