PHPackages                             avto-dev/huawei-push-kit - 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. avto-dev/huawei-push-kit

ActiveLibrary

avto-dev/huawei-push-kit
========================

Simple Huawei Push in PHP

v0.3.0(8mo ago)01.9k↓87.7%3MITPHPPHP ^8.3CI passing

Since Dec 2Pushed 8mo agoCompare

[ Source](https://github.com/avto-dev/huawei-push-kit)[ Packagist](https://packagist.org/packages/avto-dev/huawei-push-kit)[ RSS](/packages/avto-dev-huawei-push-kit/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)Dependencies (5)Versions (7)Used By (0)

Huawei Push Kit PHP
===================

[](#huawei-push-kit-php)

Important

This is a replacement for a `afiqiqmal/huawei-push` package that is currently not being updated.

### Installation

[](#installation)

```
composer require avto-dev/huawei-push-kit
```

### Usage

[](#usage)

#### Get Access Token

[](#get-access-token)

References : [Huawei OAuth](https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides-V5/open-platform-oauth-0000001053629189-V5#EN-US_TOPIC_0000001053629189__section12493191334711)

```
$access = HuaweiPushKit::make([
    'app_id' => 'YOUR APP ID',
    'client_secret' => 'YOUR CLIENT SECRET'
])
    ->getAccessToken();

//Laravel
$access = HuaweiPushKit::make(config('huawei'))->getAccessToken();
$access = app(HuaweiPushKit::class)->getAccessToken();
```

Response

```
{
    "access_token": "ACCESS TOKEN",
    "expires_in": 3600,
    "token_type": "Bearer"
}
```

#### Push Message

[](#push-message)

References : [Huawei Push Kit](https://developer.huawei.com/consumer/en/doc/development/HMSCore-References-V5/https-send-api-0000001050986197-V5#EN-US_TOPIC_0000001050986197__p2559323141314)

```
$response = HuaweiPushKit::make([])
    ->withAccessToken('ACCESS TOKEN')
    ->push(
        NotificationPayload::make()
            ->setValidateOnly(false)
            ->setMessage(
                Message::make()
                    ->setNotification(
                        Notification::make()
                            ->setTitle("Testing Title")
                            ->setBody("Body")
                            ->setImage("https://seeklogo.com/images/L/laravel-logo-41EC1D4C3F-seeklogo.com.png")
                    )
                    ->setAndroid(
                        Config::make() // AndroidConfig
                            ->setUrgency(2)
                            ->setCategory(1)
                            ->setTimeToLive(3360)
                            ->setTags('TrumpIsDown')
                            ->isStaging(true)
                            ->setNotification(
                                AndroidNotification::make() // Notification
                                    ->setClickAction(
                                        ClickAction::make()
                                        ->setType(1)
                                        ->setIntent("pushscheme://com.huawei.hms.hmsdemo/deeplink?#Intent;i.isFeed=1;S.feedDocId=0LauP4X6;end")
                                        ->setUrl('https://www.google.com')
                                    )
                                    ->setImage('https://seeklogo.com/images/L/laravel-logo-41EC1D4C3F-seeklogo.com.png')
                                    ->setIcon('/raw/ic_launcher2')
                                    ->setColor('#FFFFFF')
                                    ->setSound('/raw/shake')
                                    ->setDefaultSound(false)
                                    ->setPriority(3)
                                    ->setChannelId("HMSTestDemo")
                                    ->setAutoClear(100000) // ms
                                    ->setSummary("Summary")
                                    ->setStyle(0)
                                    ->setNotifyId(123456)

                                    ->setButtons([
                                        Button::make()->setName("Home")->setActionType(0)
                                    ])
                            )
                    )
                    ->setTopic("Topic")
            )
    );
```

Response

```
{
    "code": "80000000",
    "msg": "Success",
    "requestId": "160502268063038626000406"
}
```

### TODO

[](#todo)

- WebPUSH
- APNS

License
-------

[](#license)

Licensed under the [MIT license](http://opensource.org/licenses/MIT)

[![](https://camo.githubusercontent.com/fae49c14c08b15cedc0f829bf690717f2edabe33f88a6c67f6f8f7225702abc6/68747470733a2f2f692e696d6775722e636f6d2f5932677172326a2e706e67)](https://www.paypal.com/paypalme/mhi9388?locale.x=en_US)

###  Health Score

42

—

FairBetter than 89% of packages

Maintenance65

Regular maintenance activity

Popularity23

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% 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 ~343 days

Total

5

Last Release

246d ago

PHP version history (2 changes)v0.1.0PHP ^7.2|^8.0

v0.2.0PHP ^8.3

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/6119929?v=4)[Eldario](/maintainers/eldario)[@eldario](https://github.com/eldario)

---

Top Contributors

[![afiqiqmal](https://avatars.githubusercontent.com/u/9051312?v=4)](https://github.com/afiqiqmal "afiqiqmal (18 commits)")[![gomzyakov](https://avatars.githubusercontent.com/u/1460709?v=4)](https://github.com/gomzyakov "gomzyakov (3 commits)")[![eldario](https://avatars.githubusercontent.com/u/6119929?v=4)](https://github.com/eldario "eldario (2 commits)")[![IlyaKislitsin](https://avatars.githubusercontent.com/u/26906044?v=4)](https://github.com/IlyaKislitsin "IlyaKislitsin (1 commits)")

---

Tags

huaweihuawei-mobile-serviceshuawei-pushhuawei-push-kitpush-kit

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/avto-dev-huawei-push-kit/health.svg)

```
[![Health](https://phpackages.com/badges/avto-dev-huawei-push-kit/health.svg)](https://phpackages.com/packages/avto-dev-huawei-push-kit)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M2.6k](/packages/craftcms-cms)[spatie/crawler

Crawl all internal links found on a website

2.8k16.3M52](/packages/spatie-crawler)[laravel/valet

A more enjoyable local development experience for Mac.

2.6k911.9k13](/packages/laravel-valet)[illuminate/http

The Illuminate Http package.

11936.0M5.0k](/packages/illuminate-http)[laravel-zero/framework

The Laravel Zero Framework.

3371.4M368](/packages/laravel-zero-framework)[neuron-core/neuron-ai

The PHP Agentic Framework.

1.8k245.3k20](/packages/neuron-core-neuron-ai)

PHPackages © 2026

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