v0.0.1 2018-05-16 00:13 UTC

This package is not auto-updated.

Last update: 2024-09-20 09:06:42 UTC


README

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

  • API版本:4.0.0
  • 包版本:v0.0.1
  • 构建日期:2018-05-16T00:56:54.871+01:00
  • 构建包:class io.swagger.codegen.languages.PhpClientCodegen

要求

PHP 5.4.0 及以上版本

安装与使用

Composer

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

{
  "repositories": [
    {
      "type": "git",
      "url": "https://github.com/smsgatewayme/client-php.git"
    }
  ],
  "require": {
    "smsgatewayme/client": "^0.0.1"
  }
}

然后运行 composer install

手动安装

下载文件并包含 autoload.php

    require_once('/path/to/SwaggerClient-php/autoload.php');

测试

要运行单元测试

composer install
./vendor/bin/phpunit lib/Tests

入门

请遵循安装步骤,然后运行以下命令

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

// Configure API key authorization: Authorization
SMSGatewayMe\Client\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
// SMSGatewayMe\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'BEARER');

$api_instance = new SMSGatewayMe\Client\Api\CallbackApi();
$callback = new \SMSGatewayMe\Client\Model\CreateCallbackRequest(); // \SMSGatewayMe\Client\Model\CreateCallbackRequest | callback to create

try {
    $result = $api_instance->createCallback($callback);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CallbackApi->createCallback: ', $e->getMessage(), "\n";
}

?>

API端点文档

所有URI都是相对于 https://smsgateway.me/api/v4

模型文档

授权文档

授权

  • 类型: API密钥
  • API密钥参数名: Authorization
  • 位置: HTTP头

作者