PHPackages                             jean553/wechat-bundle - 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. jean553/wechat-bundle

ActiveSymfony-bundle

jean553/wechat-bundle
=====================

Wechat authentication/profile management bundle

v0.5.0(11y ago)149[3 issues](https://github.com/jean553/WechatBundle/issues)MITPHPPHP &gt;=5.3.2

Since May 2Pushed 11y ago1 watchersCompare

[ Source](https://github.com/jean553/WechatBundle)[ Packagist](https://packagist.org/packages/jean553/wechat-bundle)[ Docs](https://github.com/jean553/WechatBundle)[ RSS](/packages/jean553-wechat-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (7)Versions (2)Used By (0)

[![Build Status](https://camo.githubusercontent.com/1501c35fbaed3e40010bc1f8895695316bfde1d3c46499e454d8874422c67127/68747470733a2f2f7472617669732d63692e6f72672f6a65616e3535332f57656368617442756e646c652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/jean553/WechatBundle)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/95b781ffd50d3c6e934d6f799e177b446b5ea522cd1044d2ab64ff9ad0402e23/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6a65616e3535332f57656368617442756e646c652f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/jean553/WechatBundle/?branch=master)[![Code Coverage](https://camo.githubusercontent.com/db2e307dc17c67b936be95de1d55a25195722d1301afe0cdfaa6330e65cbb7ee/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6a65616e3535332f57656368617442756e646c652f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/jean553/WechatBundle/?branch=master)

MIT License

WechatBundle
============

[](#wechatbundle)

PHP Bundle for WeChat. By developing applications, it is often required to call WeChat services ( like get all connected user information, authorize an user to connect... etc... ). The goal of this bundle is to group them all.

The latest version of the bundle can handle :

- get all the necessary token for both of Oauth2 and Wechat JS API communication
- authorize an user to connect by checking Wechat account
- get current connected user WeChat information ( nichname, location, image... )

Note : if you want be able to handle WeChat wall/friends sharing features, please use my other JavaScript project WechatJS with the current bundle.

Note : bundle development ongoing tasks are all availables in this Github issues section.

Installation
------------

[](#installation)

The latest version of the bundle can be downloaded through Composer :

```
"require": {
    "jean553/wechat-bundle": "dev-master"
}

```

Use
---

[](#use)

Use the bundle in your project :

```
use jean553\WechatBundle\Services\WechatService;

```

Connect to the WeChat authentication service OAuth2. Use your application id ( appid ) and secret passphrase ( secret ) available on your WeChat Public Account (  ).

```
$wechatService = new WechatService();

$authentication = $wechatService->authorize(
    $appid,
    $secret
);

if(!$authentication) {
    return new Response('WeChat connection error.');
}

```

Get the current user information.

```
$user = $wechatService->getUserInformation();

```

$user is an array which contains the following items :

- openid : user WeChat openid
- nickname : WeChat nickname of the user
- sex
- language
- city
- province
- country
- headimgurl : absolute path of the user profile picture
- privilege

Run the tests
-------------

[](#run-the-tests)

```
bin/phpunit jean553/WechatBundle

```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity48

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

Unknown

Total

1

Last Release

4034d ago

### Community

Maintainers

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

---

Top Contributors

[![jean553](https://avatars.githubusercontent.com/u/8011398?v=4)](https://github.com/jean553 "jean553 (37 commits)")

---

Tags

symfonyoauth2wechat

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/jean553-wechat-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/jean553-wechat-bundle/health.svg)](https://phpackages.com/packages/jean553-wechat-bundle)
```

PHPackages © 2026

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