jumper423/voximplant-phpsdk

Voximplant HTTP API PHP SDK

1.0 2018-02-21 16:30 UTC

This package is auto-updated.

Last update: 2024-09-05 19:04:33 UTC


README

Voximplant HTTP API 描述

要求

PHP 5.4.0 及以上版本

安装与使用

Composer

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

{
  "repositories": [
    {
      "type": "git",
      "url": "https://github.com/DmitryIvaneychik/phpsdk.git"
    }
  ],
  "require": {
    "voximplant/phpsdk": "*@dev"
  }
}

然后运行 composer install

手动安装

下载文件并包含 autoload.php

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

入门指南

请按照安装流程进行操作,然后运行以下命令

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

// Configure API key: api_key
Voximplant\Configuration::getDefaultConfiguration()->setApiKey('api_key', 'YOUR_API_KEY');

// Configure account name: account_name
Voximplant\Configuration::getDefaultConfiguration()->setApiKey('account_name', 'YOUR_ACCOUNT_NAME');

$api_instance = new \Voximplant\Api\AccountsAuthenticationApi();

try {
    $result = $api_instance->logon();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountsAuthenticationApi->logon: ', $e->getMessage(), PHP_EOL;
}

?>

API端点文档

所有URI都是相对于 https://api.voximplant.com/platform_api/

模型文档

授权文档

account_name

  • 类型: 账户名称
  • 账户名称参数名: account_name
  • 位置: URL查询字符串

api_key

  • 类型: API密钥
  • API密钥参数名:api_key
  • 位置: URL查询字符串

作者

Дмитрий Иванович ivaneychik@zingaya.com