PHPackages                             wangchengtao/tianque - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. wangchengtao/tianque

ActiveLibrary[API Development](/categories/api)

wangchengtao/tianque
====================

天阙开放平台 SDK

1.0.12(1mo ago)0301MITPHPPHP &gt;=7.4CI passing

Since Apr 14Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/wangchengtao/tianque)[ Packagist](https://packagist.org/packages/wangchengtao/tianque)[ RSS](/packages/wangchengtao-tianque/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (6)Versions (14)Used By (1)

概要
--

[](#概要)

天阙开放平台 SDK

主要目的
----

[](#主要目的)

1. 集成 Composer
2. 编码风格遵循 PSR-12
3. 单元测试
4. 框架集成
5. 补充 PHPDoc

Version Guidance
----------------

[](#version-guidance)

- php &gt;=7.4

安装
--

[](#安装)

```
composer require wangchengtao/tianque
```

For laravel 6+

```
composer require wangchengtao/laravel-tianque
```

如何使用
----

[](#如何使用)

- Notes: More Usages please refer to test cases

```
use Summer\TianQue\Kernel\AopClient;
use Summer\TianQue\Kernel\Config;
use Summer\TianQue\Kernel\AopFactory;
use Summer\TianQue\Kernel\RequestFactory;
use Summer\TianQue\Request\Merchant\QueryApplyInfoRequest;

$config = new Config(
    'https://openapi-test.tianquetech.com',
    'your orgId',
    'your privateKey',
    '天阙平台公钥',
);

$client = new AopClient($config);

// or get client by factory
//$config = [
//   'domain' => 'https://openapi-test.tianquetech.com',
//   'org_id' => 'your orgId',
//   'private_key' => 'your privateKey',
//   'public_key' => '天阙平台公钥',
//];
//$client = AopFactory::client($config);

// 自定义 reqId 须实现 GeneratorInterface 接口
//$client->setGenerator(CustomRandomGenerator::class);

$request = new QueryApplyInfoRequest();
$request->setId('123');

// or init through __construct
//$request = new QueryApplyInfoRequest(['id' => '123']);

// or use factory
//$request = RequestFactory::create('POST', '/merchant/specialApplication/queryApplyInfo', [
//   'id' => '123',
//]);

$res = $client->execute($request);

var_dump($res->getCode());
var_dump($res->getRespData());
```

测试
--

[](#测试)

- `./vendor/bin/phpunit`

扩展
--

[](#扩展)

1. 添加更多请求对象 须继承 `Summer\TianQue\Request\Request`, 推荐使用工厂创建请求对象

###  Health Score

41

—

FairBetter than 88% of packages

Maintenance96

Actively maintained with recent releases

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~28 days

Recently: every ~84 days

Total

13

Last Release

53d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2401b92a15ab0ec8abf74a063fd79206aa50dc5ff912c653171127474bcd78d0?d=identicon)[wangchengtao](/maintainers/wangchengtao)

---

Top Contributors

[![wangchengtao](https://avatars.githubusercontent.com/u/14216412?v=4)](https://github.com/wangchengtao "wangchengtao (34 commits)")

---

Tags

sdktianque

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/wangchengtao-tianque/health.svg)

```
[![Health](https://phpackages.com/badges/wangchengtao-tianque/health.svg)](https://phpackages.com/packages/wangchengtao-tianque)
```

###  Alternatives

[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k7.6M74](/packages/openai-php-laravel)[saloonphp/saloon

Build beautiful API integrations and SDKs with Saloon

2.4k9.6M467](/packages/saloonphp-saloon)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[php-opencloud/openstack

PHP SDK for OpenStack APIs. Supports BlockStorage, Compute, Identity, Images, Networking and Metric Gnocchi

2292.2M23](/packages/php-opencloud-openstack)[mailchimp/transactional

458.9M16](/packages/mailchimp-transactional)[resend/resend-php

Resend PHP library.

564.7M21](/packages/resend-resend-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
