PHPackages                             gogo/laravel-getui - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. gogo/laravel-getui

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

gogo/laravel-getui
==================

一个适用于laravel和lumen框架的个推push推送服务包

00PHP

Since Apr 27Pushed 3y ago1 watchersCompare

[ Source](https://github.com/gaogan779322720/gg-getui)[ Packagist](https://packagist.org/packages/gogo/laravel-getui)[ RSS](/packages/gogo-laravel-getui/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel Or Lumen GeTui
======================

[](#laravel-or-lumen-getui)

基于 [个推官方SDK](http://docs.getui.com/getui/server/php/start/) for Laravel.

---

[![](https://camo.githubusercontent.com/07e615ecfdcaaa9dfa7aaf6db7dada92f41f4bf088eb7ed7aa5280761a9f703c/68747470733a2f2f7472617669732d63692e6f72672f476f676f2f6c61726176656c2d67657475692e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Gogo/laravel-getui)[![](https://camo.githubusercontent.com/342d42ae8f50067d93f4bd234bbde2accf9ea7c8166869fb35a0732d152bc062/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f476f676f2f6c61726176656c2d67657475692e737667)](https://packagist.org/packages/Gogo/laravel-getui)[![](https://camo.githubusercontent.com/c1dae8ac3adc250ca0c1c013ae086e337c6140f18b2c9f36977603f9bc5d3a19/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f476f676f2f6c61726176656c2d67657475692e737667)](https://packagist.org/packages/stichoza/Gogo/laravel-getui)

安装
--

[](#安装)

```
$ composer require Gogo/laravel-getui -v
```

### Laravel

[](#laravel)

```
// config/app.php

    'providers' => [
        //...
        Gogo\GeTui\GeTuiServiceProvider::class,    //This is default in laravel 5.5
    ],
```

And publish the config file:

```
$ php artisan vendor:publish --provider=Gogo\\GeTui\\GeTuiServiceProvider
```

if you want to use facade mode, you can register a facade name what you want to use, for example `GeTui`:

```
// config/app.php

    'aliases' => [
        'GeTui' => Gogo\GeTui\Facade\GeTui::class,   //This is default in laravel 5.5
    ],
```

### lumen

[](#lumen)

- 在 bootstrap/app.php 中 82 行左右：

```
$app->register(Gogo\GeTui\GeTuiServiceProvider::class);

```

将 `vendor/Gogo/laravel-getui/src/config/getui.php` 拷贝到项目根目录`/config`目录下，并将文件名改成`getui.php`。

### configuration

[](#configuration)

```
// config/getui.php
   // APP_EVN     你的项目当前环境 测试、生产
    'app_env' => env('APP_ENV') == 'production' ? 'production' : 'development',

    // The default default_client name which configured in `development` or `production` section
    //默认推送的客户端
    'default_client' => 'client_1',

    'development' => [
        'client_1' => [
            'gt_appid' => 'WAqyXNcLpS8OLg4jBywS48',
            'gt_appkey' => 'FkxUuibQsT75FX5Tt5jteA',
            'gt_appsecret' => 'jWtd0iUzdmAvVPhKorrtW1',
            'gt_mastersecret' => '4uCfJsfME99oaF5sT1ZjO',
            'gt_domainurl' => 'http://sdk.open.api.igexin.com/apiex.htm',
        ],
        'client_2' => [
            'gt_appid' => 'SeldZ6X0Iq8hpj5rGvqAk8',
            'gt_appkey' => '93MPU2THwl9okpeNf4lNI4',
            'gt_appsecret' => 'kzZuSXVMm29M7owpvId979',
            'gt_mastersecret' => '0QCmCdVZSi8lcyMFXLB4e',
            'gt_domainurl' => 'http://sdk.open.api.igexin.com/apiex.htm',
        ],

        // other client_3   ......
    ],
    'production' => [
        'client_1' => [
            'gt_appid' => '6V95sH0t3W6Du1MTiU3679',
            'gt_appkey' => 'n6q8NSAshP77ImKxdhuHV6',
            'gt_appsecret' => '01hGwR1Jdl6vuwBcnvfyD3',
            'gt_mastersecret' => 'daw4hbkFj4Ah3kBlPFfIh2',
            'gt_domainurl' => 'http://sdk.open.api.igexin.com/apiex.htm',
        ],
        'client_2' => [
            'gt_appid' => 'iB7DfaXV6bAf8zlJ0L59A8',
            'gt_appkey' => 'DKKp54s2knA2MaeGBXuF01',
            'gt_appsecret' => 'exTKWC0M1K6O2Bgig5RiC8',
            'gt_mastersecret' => '0cojzBC7yB86mhOiOVHBuA',
            'gt_domainurl' => 'http://sdk.open.api.igexin.com/apiex.htm',
        ],

        // other client_3   ......

    ],

```

Usage
-----

[](#usage)

Gateway instance:

```
use GeTui;
//针对单个或者多个用户推送
GeTui::push($deviceId, $data,true) //Using default default_client   推送给默认的客户端
GeTui::toClient('CLIENT NAME')->push($deviceId, $data)  // CLIENT NAME is key name of `development` or `production`  configuration.  //自定义发送的客户端

// 针对整个app所有人推送
GeTui::pushToApp($data,true) ////Using default default_client
GeTui::toClient('CLIENT NAME')->pushToApp($data)  // GATEWAY NAME is key name of `development` or `production`  configuration.
```

Example:

```
    $deviceId = 'a1f3e7c11ca97924be6f291f2c09714b';
   // 多个push对象device_id 用数组传入
//   $deviceId = [
//            'a1f3e7c11ca97924be6f291f2c09714b',
//            'ea34a4715b08b1b8d77aabf36c977cba',
//           ];

   $data = [
                'url' => 'http://test.4d4k.com/push',
                'type' => '点击查看\(^o^)/~',
                'title' => '23232323fdf',
                'content' => '今天天气真好',
                'id' => '3a92y3GR1neZ',
                'merchant_name' => '泽明科技',
                'big_cat' => '电视机',
                'full_address' => '北京市海淀区五道口清华大学',
            ];

$res = \GeTui::push($deviceId, $data,true); //Using default default_client

print_r($res);
```

License
-------

[](#license)

MIT

###  Health Score

13

—

LowBetter than 1% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity22

Early-stage or recently created project

 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.

### Community

Maintainers

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

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

---

Top Contributors

[![gaogan779322720](https://avatars.githubusercontent.com/u/25579125?v=4)](https://github.com/gaogan779322720 "gaogan779322720 (7 commits)")

### Embed Badge

![Health badge](/badges/gogo-laravel-getui/health.svg)

```
[![Health](https://phpackages.com/badges/gogo-laravel-getui/health.svg)](https://phpackages.com/packages/gogo-laravel-getui)
```

###  Alternatives

[tijsverkoyen/css-to-inline-styles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

5.8k505.3M227](/packages/tijsverkoyen-css-to-inline-styles)[minishlink/web-push

Web Push library for PHP

1.9k12.0M53](/packages/minishlink-web-push)[laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

2587.7M12](/packages/laravel-notification-channels-twilio)[spatie/url-signer

Generate a url with an expiration date and signature to prevent unauthorized access

4422.3M16](/packages/spatie-url-signer)[mattketmo/email-checker

Throwaway email detection library

2742.0M5](/packages/mattketmo-email-checker)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2371.3M11](/packages/laravel-notification-channels-discord)

PHPackages © 2026

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