infomaniak/api-php-client

此包已被废弃,不再维护。未建议替代包。
此包最新版本(0.1.01)没有提供许可证信息。

一个用于访问Infomaniak API的PHP客户端库。

0.1.01 2017-03-01 13:33 UTC

This package is not auto-updated.

Last update: 2022-06-01 08:53:44 UTC


README

介绍

infomaniak/api-php-client 是 Infomaniak API 的 PHP 客户端。此客户端将提供可用服务的文档,描述 URI、HTTP 方法和输入参数。

安装

您可以使用 Composer 安装 infomaniak/api-php-client

以下命令快速集成

composer require infomaniak/api-php-client

或将它添加到项目 composer.json 文件的 require 部分。

"infomaniak/api-php-client": "0.1"

使用

<?php

require 'vendor/autoload.php';
use Infomaniak\Api;

$token = '123456789';
$client = new Api(['token' => $token]);

// Ping example
$result = $client->ping();
print_r($result);

// List mailbox example
$result = $client->listMailbox(
	array(
		'id'   => 123456789,
		'with' => '*'
	)
);
print_r($result);