当朗/avacloud

0.1.27 2024-06-28 18:42 UTC

README

请访问官方网站以获取更多信息及进一步文档: https://www.dangl-it.com/products/avacloud-gaeb-saas/
要开始,您可以使用PHP演示应用程序: https://github.com/Dangl-IT/avacloud-demo-php

AVACloud API规范

此PHP包由Swagger Codegen项目自动生成

  • API版本:1.52.1
  • 包版本:1.52.1
  • 构建包:io.swagger.codegen.languages.PhpClientCodegen

需求

PHP 5.5及以后版本

安装与使用

Composer

要使用Composer安装绑定,请将以下内容添加到composer.json

{
  "repositories": [
    {
      "type": "git",
      "url": "https://github.com/Dangl-IT/avacloud-client-php.git"
    }
  ],
  "require": {
    "dangl/avacloud": "*@dev"
  }
}

然后运行composer install

手动安装

下载文件并包含autoload.php

    require_once('/path/to/Dangl\AVACloud/vendor/autoload.php');

测试

要运行单元测试

composer install
./vendor/bin/phpunit

入门

请遵循安装过程,然后运行以下命令

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: Dangl.Identity
$config = Dangl\AVACloud\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Dangl\AVACloud\Api\AslvConversionApi(
    // 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
);
$aslv_file = "/path/to/file.txt"; // \SplFileObject | The input file
$remove_plain_text_long_texts = true; // bool | If set to true, plain text long texts will be removed from the output to reduce response sizes
$remove_html_long_texts = true; // bool | If set to true, html long texts will be removed from the output to reduce response sizes

try {
    $result = $apiInstance->aslvConversionConvertToAva($aslv_file, $remove_plain_text_long_texts, $remove_html_long_texts);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AslvConversionApi->aslvConversionConvertToAva: ', $e->getMessage(), PHP_EOL;
}

?>

API端点文档

所有URI均相对于https://avacloud-api.dangl-it.com

模型文档

授权说明文档

Dangl.Identity

作者