定制 axolotesource/laravel-whatsapp-api 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

axolotesource/laravel-whatsapp-api

最新稳定版本:1.0.0

Composer 安装命令:

composer require axolotesource/laravel-whatsapp-api

包简介

This Laravel package facilitates sending WhatsApp messages seamlessly within your application. With easy integration, it empowers developers to incorporate WhatsApp messaging functionality, enhancing user engagement and communication in a straightforward manner.

README 文档

README

INSTALL

composer require axolotesource/laravel-whatsapp-api

To publish the configuration file, run the following command:

php artisan vendor:publish

When prompted to select the provider, choose Axolotesource\LaravelWhatsappApi\LaravelWhatsappApiServiceProvider.

WhatsAppMessages

Examples

templete(string $to, string $templateName = null): Template

This method allows you to send a template-type message (this is the first message that should be sent to the client). For the second parameter, it can be null, and if so, it retrieves the value from config('laravel-whatsapp-api.default_initial_template');.

$whatsappMessage = WhatsAppMessages::templete($phoneNumber)
    ->language('es_MX')
    ->addComponents([
        BodyComponent::create([
            Params::text('This is a test message')
        ]),
        ButtonComponent::create([
            Params::button('yes')
        ]),
        ButtonComponent::create([
            Params::button('no')
        ]),
        ButtonComponent::create(
            [
                Params::button("history/login?folio=123ABC")
            ],
            ButtonComponent::SUB_TYPE_URL
        ),
        ButtonComponent::create([
            Params::button('never')
        ])
    ]);
interactiveButtons(string $to): InteractiveButtons
WhatsAppMessages::interactiveButtons($phoneNumber)
    ->setHeaderImage(
        'https://url.com/test.jpg'
    )
    ->addButton('Button 1', 1)
    ->addButton('Button 2', 2)
    ->addButton('Button 3', 3)
    ->body('This is te body message')
    ->send();

Coming song more documentation....

统计信息

  • 总下载量: 168
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 5
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 3
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MTI
  • 更新时间: 2023-11-21

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固