← Скрипты и библиотеки
XenoX352/discord-webhook-open.mp
Discord Webhook connects with gamemode using the open source pawnraknet api
Библиотека★ 3обновлён июнь 2026 г.MITPawn
Открыть на GitHubREADME.md
About
Discord Webhook is a lightweight Pawn include that lets your SA:MP or open.mp server send beautifully formatted embed messages directly to a Discord channel.
Powered by the Pawn Requests plugin, it offers a clean and straightforward API with zero bloat.
Whether you need to log admin actions, announce server events, or display player statistics, this system gets the job done with minimal configuration.
Features
- Rich embed messages – title, description, colour, fields, footer.
- Customisable bot username and avatar per request.
- Inline fields for compact information display.
- Lightweight and fast – no extra dependencies besides Requests.
- Compatible with SA:MP 0.3.7 and open.mp.
- Clean, well‑documented code that’s easy to extend.
Requirements
- Pawn Requests plugin (download)
- SA:MP server 0.3.7+ or open.mp
- Basic Pawn scripting knowledge
Installation
SA:MP (0.3.7 / 0.3.DL)
- Download the latest Pawn Requests plugin.
- Place
requests.dll(Windows) orrequests.so(Linux) into your server’splugins/folder. - Place
requests.incinto yourpawno/include/folder. - Add
requeststo thepluginsline inserver.cfg. - Copy
discord-webhook.incinto yourpawno/include/folder.
open.mp
- Download the latest Pawn Requests plugin.
- Place
requests.dll/requests.sointo your server’splugins/folder. - Place
requests.incinto yourqawno/include/folder. - Add
requeststo thelegacy_pluginsarray inconfig.json. - Copy
discord-webhook.incinto yourqawno/include/folder.
Quick Start
Include the library in your script and send an embed with one line:
#include <discord-webhook>
public OnGameModeInit()
{
SendDiscordEmbed(
"https://discord.com/api/webhooks/1234567890/abcdef",
"My SA:MP Bot",
"https://i.imgur.com/myavatar.png",
"Server Started",
"The server is now online!",
0x00FF00,
"Info|Everything is running smoothly",
"My SA:MP Server"
);
return 1;
}
Страница собрана из того, что GitHub публикует о репозитории. samp.directory не хранит этот код. Сообщить о проблеме с этой записью