PHPackages                             davidyou/tencent-qidian - 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. davidyou/tencent-qidian

ActiveProject[API Development](/categories/api)

davidyou/tencent-qidian
=======================

forked from TencentQidian/qidian-sdk-php.

v1.3(1y ago)138MITPHPPHP ^7.1.8 || ^8.0

Since May 17Pushed 1y ago1 watchersCompare

[ Source](https://github.com/DavidYou21st/tencent-qidian)[ Packagist](https://packagist.org/packages/davidyou/tencent-qidian)[ RSS](/packages/davidyou-tencent-qidian/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (7)Used By (0)

企点开放平台 SDK
==========

[](#企点开放平台-sdk)

安装
--

[](#安装)

composer require davidyou/tencent-qidian

使用方法
----

[](#使用方法)

```
//1.完善服务器配置
$pc = new QDMsgCrypt($token, $encodingAesKey, $appId);
$str = $pc->VerifyURL($signature, $timestamp, $nonce, $echostr, $replyEchoStr);

//2.解析xml推送内容
$pc = new QDMsgCrypt($token, $encodingAesKey, $appId);
$errCode = $pc->decryptMsg($signature, $timeStamp, $nonce, $fromXml, $msg);

//3.获取自建应用的token
$object = new SelfBuiltService($token, $encodingAesKey, $appId);
$selfBuildToken = $object->getSelfBuildToken($appId, $sid, $secret);

//4.获取ticket票据
$object = new Common($token, $encodingAesKey, $appId);
$ticketResult = $object->getTicket($encryXml, $signature, $timestamp, $nonce);

//5.根据ticket换取应用开发商token
$object = new Common($token, $encodingAesKey, $appId);
$componentAccessTokenResult = $object->getAccessToken($appId, $appSecret, $ticketValue);

//6.获取第三方应用的企业授权code，并换取企业授权token
$object = new CompanyService($token, $encodingAesKey, $appId);
$companyAccessTokenResult = $object->getCompanyAccessToken($componentAccessToken, $appId, $code);

//7.刷新企业授权token
$object = new CompanyService($token, $encodingAesKey, $appId);
$companyRefreshTokenResult = $object->getCompanyRefreshToken($componentAccessToken, $appId, $authorizerAppid, $authorizerRefreshToken, $sid);

```

更多
--

[](#更多)

查看 [Demo](https://github.com/TencentQidian/qidian-sdk-php/blob/master/demo/demo.php "Demo")

开发文档
----

[](#开发文档)

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

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 ~16 days

Total

6

Last Release

644d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f3d8dc3ddb411f66dd0ff1ca39c41e33bc2e0dc66a73be02385027b6caefe885?d=identicon)[DavidYou21st](/maintainers/DavidYou21st)

---

Top Contributors

[![DavidYou21st](https://avatars.githubusercontent.com/u/127276912?v=4)](https://github.com/DavidYou21st "DavidYou21st (5 commits)")

---

Tags

sdktencentQidian

### Embed Badge

![Health badge](/badges/davidyou-tencent-qidian/health.svg)

```
[![Health](https://phpackages.com/badges/davidyou-tencent-qidian/health.svg)](https://phpackages.com/packages/davidyou-tencent-qidian)
```

###  Alternatives

[mocking-magician/coinbase-pro-sdk

Library for coinbase pro API calls

223.2k](/packages/mocking-magician-coinbase-pro-sdk)

PHPackages © 2026

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