PHPackages                             ahmetonurslmz/php-webhook - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. ahmetonurslmz/php-webhook

ActiveLibrary[HTTP &amp; Networking](/categories/http)

ahmetonurslmz/php-webhook
=========================

The package enables developers to send request to discord webhook in order to create message and send it discord channel.

v0.1(5y ago)01.4kMITPHP

Since Oct 19Pushed 5y ago1 watchersCompare

[ Source](https://github.com/ahmetonurslmz/php-webhook)[ Packagist](https://packagist.org/packages/ahmetonurslmz/php-webhook)[ Docs](https://ahmetonursolmaz.com.tr)[ RSS](/packages/ahmetonurslmz-php-webhook/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

PHP Webhook
===========

[](#php-webhook)

The package enables developers to send request to discord webhook in order to create message and send it discord channel.

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

[](#installation)

Use the package manager [composer](https://packagist.org/packages/ahmetonurslmz/php-webhook) to install **PHP Webhook**.

```
composer require ahmetonurslmz/php-webhook
```

Basic Usage
-----------

[](#basic-usage)

### Discord Webhook

[](#discord-webhook)

```
require __DIR__.'/vendor/autoload.php'; // You must include autoload register.

use PhpWebhook\Providers\Discord;

$discordWebhook = new Discord(); // initializes discord instance
$discordWebhook->setMessage('Hello World!');
$discordWebhook->setToken(YOUR_DISCORD_CHANNEL_TOKEN); // Discord token exists in your webhook URL.
$discordWebhook->request();
```

Discord Integrations
--------------------

[](#discord-integrations)

### Get Token

[](#get-token)

When you copy a discord webhook URL, you obtain a link like this.

```
https://discord.com/api/webhooks/765243409241604116/cN5-Tv-j2Zo1fp8B_TmVkbfRTVcFmz3m_PEsAPsqJyUZXQ2j8RrXcRhLFJ68Tpv6o1nU
```

Token which exists in the webhook URL:

```
765243409241604116/cN5-Tv-j2Zo1fp8B_TmVkbfRTVcFmz3m_PEsAPsqJyUZXQ2j8RrXcRhLFJ68Tpv6o1nU
```

Setting Message
---------------

[](#setting-message)

You can set a message which you will send with two different ways.

#### Only message content

[](#only-message-content)

You can only set a message with setMessage method.

```
$discordWebhook->setMessage("Hello world!");
```

#### Everything of message

[](#everything-of-message)

You can change all details of message (username, user logo, embedded message etc.) with setData method. Example data format is [here](https://gist.github.com/Birdie0/78ee79402a4301b1faf412ab5f1cdcf9#example-for-a-webhook)

```
$discordWebhook->setData(array(
  "username" => "Webhook",
  "avatar_url" => "https://i.imgur.com/4M34hi2.png",
  "content" => "Text message. Up to 2000 characters.",
  ));
```

Contributing
------------

[](#contributing)

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License
-------

[](#license)

[MIT](https://choosealicense.com/licenses/mit/)

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 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.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

2036d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/94c5e9a067819cecb002ef080f14413dfcd6735ddaa7b48be7acbe69b74a9895?d=identicon)[ahmetonurslmz](/maintainers/ahmetonurslmz)

---

Top Contributors

[![ahmetonurslmz](https://avatars.githubusercontent.com/u/31781134?v=4)](https://github.com/ahmetonurslmz "ahmetonurslmz (12 commits)")

---

Tags

webhookdiscorddiscord channel

### Embed Badge

![Health badge](/badges/ahmetonurslmz-php-webhook/health.svg)

```
[![Health](https://phpackages.com/badges/ahmetonurslmz-php-webhook/health.svg)](https://phpackages.com/packages/ahmetonurslmz-php-webhook)
```

###  Alternatives

[shopify/shopify-api

Shopify API Library for PHP

4634.8M16](/packages/shopify-shopify-api)[symfony/webhook

Eases sending and consuming webhooks

573.0M35](/packages/symfony-webhook)[renoki-co/laravel-aws-webhooks

Easy webhook handler for Laravel to catch AWS SNS notifications for various services.

73248.5k](/packages/renoki-co-laravel-aws-webhooks)[skrepr/teams-connector

A simple PHP package for sending messages to Microsoft Teams

239.6k1](/packages/skrepr-teams-connector)[akhan619/laravel-ses-tracking

A Laravel artisan based package to create the AWS (SES + SNS) infrastructure to receive email event notifications with Http/Https endpoint.

149.9k](/packages/akhan619-laravel-ses-tracking)

PHPackages © 2026

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