ciltocruz/swagger-bankstore-api-rest

3.0 2021-10-13 17:55 UTC

This package is auto-updated.

Last update: 2024-09-14 00:18:52 UTC


README

PAYCOMET API REST 客户端。

此 PHP 包由 Swagger Codegen 项目自动生成,详情请访问 Swagger Codegen

  • API 版本:2.37.0
  • 构建包:io.swagger.codegen.v3.generators.php.PhpClientCodegen 更多信息,请访问 https://www.paycomet.com

要求

PHP 5.5 及以上版本

安装 & 使用

Composer

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

{
  "repositories": [
    {
      "type": "git",
      "url": "https://github.com/ciltocruz/swagger-bankstore-api-rest.git"
    }
  ],
  "require": {
    "ciltocruz/swagger-bankstore-api-rest": "*@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: paycometApiKey
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('PAYCOMET-API-TOKEN', 'YOUR_API_KEY');
$apiInstance = new Swagger\Client\Api\BalanceApi(
    // 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()
);
$body = new \Swagger\Client\Model\V1BalanceBody(); // \Swagger\Client\Model\V1BalanceBody | 
$paycomet_api_token = "paycomet_api_token_example"; // string | PAYCOMET API key (Query privilege required)

try {
    $result = $apiInstance->productBalance($body, $paycomet_api_token);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BalanceApi->productBalance: ', $e->getMessage(), PHP_EOL;
}
?>

API 端点文档

所有 URI 都相对于 https://rest.paycomet.com

模型文档

授权文档

paycometApiKey

  • 类型: API密钥
  • API密钥参数名: PAYCOMET-API-TOKEN
  • 位置: HTTP头

作者

tecnico@paycomet.com