42videobricks / php-client
42videobricks是一个视频平台即服务(VPaaS)
1.4.0
2024-07-31 09:20 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
This package is not auto-updated.
Last update: 2024-09-27 17:55:52 UTC
README
42videobricks是一个视频平台即服务(VPaaS)
安装与使用
要求
PHP 7.4及更高版本。也应适用于PHP 8.0。
Composer
要通过Composer安装绑定,请在composer.json
中添加以下内容
{ "repositories": [ { "type": "vcs", "url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git" } ], "require": { "GIT_USER_ID/GIT_REPO_ID": "*@dev" } }
然后运行composer install
手动安装
下载文件并包含autoload.php
<?php require_once('/path/to/Package\Subpackage/vendor/autoload.php');
入门指南
请按照安装过程进行操作,然后运行以下命令
<?php require_once(__DIR__ . '/vendor/autoload.php'); // Configure API key authorization: gw-42vb-authorizer $config = Api42Vb\Client\Configuration::getDefaultConfiguration()->setApiKey('x-api-key', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = Api42Vb\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('x-api-key', 'Bearer'); $apiInstance = new Api42Vb\Client\Api\DataApi( // 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 ); $limit = 56; // int | Number of elements to return (default=10) $offset = 56; // int | offset for pagination $start_date = {{starDate}}; // string | Start date for the period $end_date = {{endDate}}; // string | End date for the period try { $result = $apiInstance->getDataVideoAnalytics($limit, $offset, $start_date, $end_date); print_r($result); } catch (Exception $e) { echo 'Exception when calling DataApi->getDataVideoAnalytics: ', $e->getMessage(), PHP_EOL; }
API端点
所有URI相对于https://api-sbx.42videobricks.com
模型
- DataVideoAnalytic
- DataVideoAnalyticList
- DataVideoUsage
- DataVideoUsageList
- 错误
- 导出
- 导出列表
- 导出属性
- GetScenesByLiveId200Response
- 链接
- 直播
- 直播所有资源
- 直播列表
- 直播属性
- 直播状态
- 分页
- 播放列表
- 播放列表资源
- 播放列表列表
- 播放列表属性
- 场景
- 板
- 标签列表
- 视频
- 视频资源
- 视频附件
- 视频附件列表
- 视频列表
- 视频分片上传最终化
- 视频分片上传最终化部分内部
- 视频分片上传初始化
- 视频分片上传初始化响应
- 视频分片上传初始化响应部分内部
- 视频属性
- 视频状态
- 视频上传初始化响应
- Webhook
- Webhook列表
- Webhook属性
授权
API定义的认证方案
api_key
- 类型:API密钥
- API密钥参数名:x-api-key
- 位置:HTTP头
gw-42vb-authorizer
- 类型:API密钥
- API密钥参数名:x-api-key
- 位置:HTTP头
测试
要运行测试,使用
composer install vendor/bin/phpunit
作者
关于此包
此PHP包由OpenAPI Generator项目自动生成
- API版本:
1.4
- 包版本:
1.4.0
- 包版本:
- 构建包:
org.openapitools.codegen.languages.PhpClientCodegen