drmaxis/deploybot 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

drmaxis/deploybot

Composer 安装命令:

composer require drmaxis/deploybot

包简介

Reusable Slack + Discord bot for Laravel

README 文档

README

Packagist Version Tests License

A Slack + Discord bot framework for Laravel. Drop it in, register your slash commands, ship.

Install

composer require drmaxis/deploybot
php artisan vendor:publish --tag=deploybot-config
php artisan vendor:publish --tag=deploybot-migrations
php artisan vendor:publish --tag=deploybot-routes
php artisan migrate

Configure

# .env
DEPLOYBOT_SLACK_SIGNING_SECRET=
DEPLOYBOT_SLACK_BOT_TOKEN=

# optional — one per logical channel
DEPLOYBOT_DISCORD_WEBHOOK_RELEASES=
DEPLOYBOT_DISCORD_WEBHOOK_INCIDENTS=

Register a command

use DrMaxis\Deploybot\Commands\CommandContext;
use DrMaxis\Deploybot\Commands\CommandInterface;
use DrMaxis\Deploybot\Commands\CommandResponse;

class PingCommand implements CommandInterface
{
    public static function name(): string { return 'ping'; }
    public static function description(): string { return 'Reply with pong.'; }
    public static function requiresAdmin(): bool { return false; }

    public function handle(CommandContext $ctx): CommandResponse
    {
        return CommandResponse::message('pong');
    }
}

Register from a service provider:

public function boot(CommandRegistry $registry): void
{
    $registry->register(PingCommand::class);
}

Point your Slack app's slash command at https://your-app.example/deploybot/slack/command. The built-in help command lists every registered command.

What's in the box

  • HMAC signature verification (constant-time, with timestamp-skew replay guard)
  • Slash-command dispatcher with admin allowlisting
  • Slack Web API client (chat.postMessage, chat.postEphemeral)
  • Discord webhook client (multi-purpose routing)
  • Channel-subscription model for broadcasting events
  • Block Kit response envelope types
  • Auto-discovered service provider · Laravel 12 / 13

Contributing

See CONTRIBUTING.md.

Security

Report privately via GitHub security advisories. See SECURITY.md.

License

MIT

统计信息

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

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-06-30