ventureleap / leap-one-rating-sdk
dev-master
2021-09-21 17:28 UTC
Requires
- php: >=5.5
- ext-curl: *
- ext-json: *
- ext-mbstring: *
- guzzlehttp/guzzle: ^6.2
Requires (Dev)
- friendsofphp/php-cs-fixer: ~1.12
- phpunit/phpunit: ^4.8
- squizlabs/php_codesniffer: ~2.6
This package is auto-updated.
Last update: 2024-09-22 00:23:16 UTC
README
未提供描述(由Swagger Codegen生成 https://github.com/swagger-api/swagger-codegen)
此PHP软件包由Swagger Codegen项目自动生成
- API版本:1.0.0
- 构建包:io.swagger.codegen.v3.generators.php.PhpClientCodegen
要求
PHP 5.5及更高版本
安装与使用
Composer
要通过Composer安装绑定,请在composer.json
中添加以下内容
{
"repositories": [
{
"type": "git",
"url": "https://github.com/ventureleap/leap-one-rating-sdk.git"
}
],
"require": {
"ventureleap/leap-one-rating-sdk": "*@dev"
}
}
然后运行composer install
手动安装
下载文件并包含autoload.php
require_once('/path/to/SwaggerClient-php/vendor/autoload.php');
测试
要运行单元测试
composer install
./vendor/bin/phpunit
入门
请按照安装过程进行操作,然后运行以下命令
<?php require_once(__DIR__ . '/vendor/autoload.php'); // Configure API key authorization: apiKey $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer'); $apiInstance = new VentureLeap\RatingService\Api\ConfigurationEntryApi( // 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 ); $id = "id_example"; // string | try { $apiInstance->deleteConfigurationEntryItem($id); } catch (Exception $e) { echo 'Exception when calling ConfigurationEntryApi->deleteConfigurationEntryItem: ', $e->getMessage(), PHP_EOL; } // Configure API key authorization: apiKey $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer'); $apiInstance = new VentureLeap\RatingService\Api\ConfigurationEntryApi( // 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 ); $key = "key_example"; // string | $sub_key = "sub_key_example"; // string | $value = "value_example"; // string | $application_id = "application_id_example"; // string | $page = 1; // int | The collection page number try { $result = $apiInstance->getConfigurationEntryCollection($key, $sub_key, $value, $application_id, $page); print_r($result); } catch (Exception $e) { echo 'Exception when calling ConfigurationEntryApi->getConfigurationEntryCollection: ', $e->getMessage(), PHP_EOL; } // Configure API key authorization: apiKey $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer'); $apiInstance = new VentureLeap\RatingService\Api\ConfigurationEntryApi( // 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 ); $id = "id_example"; // string | try { $result = $apiInstance->getConfigurationEntryItem($id); print_r($result); } catch (Exception $e) { echo 'Exception when calling ConfigurationEntryApi->getConfigurationEntryItem: ', $e->getMessage(), PHP_EOL; } // Configure API key authorization: apiKey $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer'); $apiInstance = new VentureLeap\RatingService\Api\ConfigurationEntryApi( // 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 ); $body = new \VentureLeap\RatingService\Model\ConfigurationEntryJsonldConfigurationWrite(); // \VentureLeap\RatingService\Model\ConfigurationEntryJsonldConfigurationWrite | The new ConfigurationEntry resource try { $result = $apiInstance->postConfigurationEntryCollection($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling ConfigurationEntryApi->postConfigurationEntryCollection: ', $e->getMessage(), PHP_EOL; } // Configure API key authorization: apiKey $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY'); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // $config = VentureLeap\RatingService\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer'); $apiInstance = new VentureLeap\RatingService\Api\ConfigurationEntryApi( // 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 ); $id = "id_example"; // string | $body = new \VentureLeap\RatingService\Model\ConfigurationEntryJsonldConfigurationWrite(); // \VentureLeap\RatingService\Model\ConfigurationEntryJsonldConfigurationWrite | The updated ConfigurationEntry resource try { $result = $apiInstance->putConfigurationEntryItem($id, $body); print_r($result); } catch (Exception $e) { echo 'Exception when calling ConfigurationEntryApi->putConfigurationEntryItem: ', $e->getMessage(), PHP_EOL; } ?>
API端点文档
所有URI都是相对于/
模型文档
- AverageRating
- ConfigurationEntryJsonldConfigurationRead
- ConfigurationEntryJsonldConfigurationWrite
- InlineResponse200
- InlineResponse2001
- InlineResponse200Hydrasearch
- InlineResponse200HydrasearchHydramapping
- InlineResponse200Hydraview
- RatingJsonldRatingRead
- RatingJsonldRatingWrite
授权文档
apiKey
- 类型:API密钥
- API密钥参数名:Authorization
- 位置:HTTP头