定制 hiddeco/transip 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

hiddeco/transip

最新稳定版本:v5.7

Composer 安装命令:

composer require hiddeco/transip

包简介

The better TransIP API client.

README 文档

README

This library is an Object Oriented wrapper for the TransIP SOAP API (v5.6), which aims to provide a better and more structured client than the official TransIP API package, including extensive documentation.

TransIP SOAP client

Installation

To use this library without running in to trouble you will need PHP 5.6+ or HHVM 3.6+ and Composer.

  1. Get the latest version of TransIP by adding the following line to your composer.json file "hiddeco/transip": "5.7.*"

  2. Run composer update or composer install

Features

  • All TransIP services and methods available through one Client
  • Follows PSR-4 conventions and PSR-2 coding standards
  • Extensively documented

Usage

Basics

Using the Client

// Composer autoload
require_once 'vendor/autoload.php';

$client = new \TransIP\Client('username', 'privateKey');
$domainNames = $client->api('domain')->getDomainNames();

Setting the permission mode and endpoint

Although the permission mode and endpoint are configured by default as readonly and api.transip.nl, it is possible to change them according to your wishes.

Note: accepted permission modes are readonly and readwrite. Invalid permission mode will throw an \InvalidArgumentException.

$client = new \TransIP\Client('username', 'privateKey', 'readwrite', 'api.transip.nl');

// set permission mode on the run
try {
    $client->setMode('readonly');
} catch(\InvalidArgumentException $e) {
    echo $e->getMessage();
}

Catching \SoapFault

$client = new \TransIP\Client('username', 'privateKey');

try {
    $client->api('domain')->getDomainNames();
} catch(\SoapFault $e) {
    $echo $e->getMessage();
}

API documentation

For a full documentation on the available methods foreach API and how to use them take a look at the extensive docs.

Contributors

License

TransIP is licensed under The MIT License (MIT).

统计信息

  • 总下载量: 306.72k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 22
  • 点击次数: 1
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 22
  • Watchers: 0
  • Forks: 4
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-08-14