PHPackages                             fuyuan9/laravel-chatwork-notification-channel - 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. fuyuan9/laravel-chatwork-notification-channel

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

fuyuan9/laravel-chatwork-notification-channel
=============================================

A Laravel notification channel for Chatwork using Chatwork API.

00PHP

Since Dec 14Pushed 1y ago1 watchersCompare

[ Source](https://github.com/fuyuan9/laravel-chatwork-notification-channel)[ Packagist](https://packagist.org/packages/fuyuan9/laravel-chatwork-notification-channel)[ RSS](/packages/fuyuan9-laravel-chatwork-notification-channel/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel Chatwork Notification Channel
=====================================

[](#laravel-chatwork-notification-channel)

A Laravel notification channel to send messages to the Japanese chat service **Chatwork** using the [Chatwork API](https://github.com/polidog/php-chatwork-api).

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

[](#installation)

You can install the package via Composer:

```
composer require fuyuan9/laravel-chatwork-notification-channel
```

Requirements
------------

[](#requirements)

- PHP &gt;= 8.0
- Laravel &gt;= 9.0
- Chatwork API token (provided by Chatwork)

Configuration
-------------

[](#configuration)

1. Add your Chatwork API token to the `.env` file:

```
CHATWORK_API_TOKEN=your-api-token-here
```

2. The package will automatically register the `ChatworkServiceProvider` to inject the Chatwork API client.

Usage
-----

[](#usage)

To send a notification using this package, you need to:

1. Define a `toChatwork` method in your `Notification` class.
2. Specify the Chatwork room ID in your notifiable entity using `routeNotificationFor('chatwork')`.

### Example Notification

[](#example-notification)

Here’s an example of how to define a notification:

```
