Logging & Integration
Application event logs, Discord webhooks, Seller API logging, and panel Event Logs — configure in Settings and view under the Event Logs tab.
Panel path
Select an application → Settings → App Config → Logging & Integration card. View logs under sidebar Event Logs.
Client logs (SDK)
Send messages from your app with API type log or SDK log(). They appear in Panel → Event Logs → Application Logs.
$app->log('User opened menu', gethostname());
// JS: await auth.Log('User opened menu');Optional parameter pcuser stores the Windows username or machine label. Enable Log IP Address in Logging settings to attach client IP to each row.
API reference: Send Log
Discord Alerts
Open the app → sidebar Discord Alerts. Add a custom webhook: name + Discord webhook URL + enabled, then toggle Events on that card. The URL stays on the server (Panel / Seller API). Client SDKs never embed the URL — they call login / log / alert / screenshot and the server routes each event only to webhooks that have that event enabled.
| Panel op | ทำอะไร |
|---|---|
discord_channels | โหลด webhooks + event catalog (auto-migrate การ์ดเก่า → custom) |
discord_webhook_add | สร้าง webhook (name, url) |
discord_webhook_update | แก้ชื่อ / URL / enabled |
discord_webhook_delete | ลบ webhook |
discord_screenshot_all | เปิด/ปิดแนบ screenshot ทุก alert |
test_discord_channel | ยิง test embed |
Seller API — Discord Alerts
Same apps.discord_channels store as the Panel. Legacy fetchwebhooks / addwebhook (client raw POST table) is a different system.
| Seller type | ทำอะไร |
|---|---|
fetchdiscord | list custom webhooks + catalog |
adddiscord | สร้าง webhook (name, url) |
editdiscord | แก้ name / url / enabled |
deldiscord | ลบตาม id |
testdiscord | ยิง test embed |
discordshotall | เปิด/ปิด screenshot-all |
Reference: fetchdiscord · adddiscord · All Seller Endpoints
adddiscord พร้อม eventsRouting model
แต่ละ custom webhook ส่งเฉพาะ event ที่ติ๊กไว้ · คนละ webhook URL = คนละห้อง Discord
- Authentication (
login,register,license, …) → ห้อง login - Security (
ban,login_fail,hash_reject, …) → ห้อง security - Captures (
log,screenshot,sdk_alert) → ห้อง captures - กลุ่มอื่น: Licenses · Admin · System · Operations (ถ้ามีสิทธิ์)
Webhook ใหม่ค่าเริ่มต้นเปิดทุก event · กด None แล้วติ๊กเฉพาะกลุ่มที่ต้องการ · หรือกดตัวเลขข้างชื่อกลุ่มเพื่อเปิด/ปิดทั้งกลุ่ม
เนื้อหา custom alert ตั้งจาก SDK ด้วย Alert(title, status, detail, category, action)
Legacy single discord_webhook + webhook_events still works until channels are saved (auto-migrated into auth).
SDK — ไม่มี Discord URL
ฝั่ง client เลือกข้อความ / status / category เอง — Discord webhook URL อยู่บน Panel หรือ Seller API เท่านั้น (RE ของ binary จะไม่เจอ URL)
// 1) Panel Discord Alerts OR Seller API adddiscord — name + webhook URL + enabled
// 2) Client SDK — never put Discord URL in the binary
cfg.capA = true; // master
app.SetCapT({"login", "license", "alert"}); // default — ไม่ยิงบน init/check
// app.SetCapT({"login"});
// app.AddCapT("init");
// app.ClrCapT();
app.Login(user, pass, hwid);
app.Alert("Payment cleared", "ok", "order #1042", "Billing", "payok");
app.Alert("License gate", "fail", "hwid mismatch", "Security", "hwidfail");
app.Log("Opened menu", "", "info", "ui");
app.LogError("License gate blocked", "license");client.CapA = true;
client.SetCapT("login", "license", "alert");
// client.SetCapT("login");
// client.AddCapT("check");
await client.InitAsync(exeMd5);
await client.LicenseAsync(key, hwid);
await client.AlertAsync("Payment cleared", "ok", "order #1042", "Billing", "payok");// URL is never in the SDK — configure via Panel or Seller adddiscord / editdiscord
$app->Alert('Payment cleared', 'ok', 'order #1042', 'Billing', 'payok');
$app->Log('Opened menu', gethostname(), 'info', 'ui');
$app->LogError('Payment failed', 'billing');
$app->Screenshot($jpegBytesOrBase64, 'optional note');Alert: title (required), status = ok · fail · warn · info, optional detail / category / action. Rate limit ~2s. Stored in Event Logs as [alert] ….
Log level: info · warn · error · debug. tag: อัลฟานิวเมอริก.
Screenshot capture
Authenticated clients upload a screen capture. Enabled custom webhooks with a valid URL receive it.
type=screenshot
image=<base64 PNG/JPEG/WEBP, max ~1.5MB>
note=optional labelAlert API:
type=alert
title=required (max 120)
status=ok|fail|warn|info
detail=optional (max 500)
category=optional (default SDK)
action=optional slugSDK: C++ / C# V2 auto-attach ตาม SetCapT (default login · license · alert · สัญลักษณ์ทึบใน binary). PHP/JS Screenshot() รับ image bytes หรือ base64. Rate limit: 1 per user / 10 seconds.
Cap timing (SDK)
Toggle บน Panel = hint ฝั่งเซิร์ฟเวอร์ · จังหวะยิงจริงตั้งใน SDK ด้วยชื่อทึบ (RE อ่านยาก):
| API | หมายถึง |
|---|---|
CapA / SetCapA | master on/off |
CapT / SetCapT / AddCapT / ClrCapT | เลือก API type ที่แนบ frame |
Server rule: ถ้า client ส่ง field แนบภาพที่ถูกต้อง จะติด embed นั้นเสมอ (ไม่สน toggle).
type=login|license|alert|…
screenshot=<base64 PNG/JPEG/WEBP, max ~1.5MB>Mime is sniffed from the bytes. Over ~1.5MB is dropped silently.
Default types: login · license · alert · init · screenshot — ไม่ยิงบน check / opsack จนกว่าจะ AddCapT.
cfg.capA = true;
cfg.capT = {"login", "license"};
app.AddCapT("alert");
app.ClrCapT();client.CapA = true;
client.SetCapT("login", "license");
client.AddCapT("alert");
client.ClrCapT();System Log embed fields
Each Discord alert is a System Log embed. Core fields: Actor · IP · Category · Application · Detail · Action · License Key (ถ้ามี) · HWID · ExeMD5 · PC Spec · Time.
| Source | Fields | Notes |
|---|---|---|
| Client SDK | pcuser, hostname, os, platform, cpu, gpu, ram, board/motherboard, hash (ExeMD5), screenshot |
SDK ส่งบน login / license / init ตามภาษา · Server รวม cpu+gpu+ram+Motherboard+os เป็นฟิลด์เดียว PC Spec (code block) |
| PC Spec (Discord) |
CPU: …GPU: …RAM: …Motherboard: …OS: …
|
แสดงเมื่อมีอย่างน้อยหนึ่งค่า · Motherboard มาจาก BaseBoard serial (fallback Product/BIOS/UUID) · ลำดับอยู่หลัง ExeMD5 ก่อน Time · ดูพรีวิวที่ Panel → Discord Alerts |
| Server enrich | country, city, isp, ip_flags, session, subscription, expiry, days_left, hwid_status, panel, masked key, fail_reason |
DiscordAlertEnrich บน login / license / fail / ops |
cpu · gpu · ram · os อัตโนมัติเมื่อรันบน Windows (WMI/wmic) · ภาษาอื่นส่งเท่าที่มีบนแพลตฟอร์มApplication log storage
| Toggle / field | DB field | Effect |
|---|---|---|
| Log IP Address | log_ip | Stores client_ip on each log API row |
| Retention (days) | log_retention_days | Auto-delete older logs (1–90 days, default 7) on panel fetch |
Event Logs tab
Two views — same toolbar pattern as Files / Web Loader:
- Application Logs — SDK
log()messages with user, PC name, optional IP, timestamp - Seller Logs — Seller API requests when logging is enabled for the app
Features: search, export TSV, bulk delete, clear all, pagination. Yellow notice reminds you of the 255-char limit and retention policy.
Seller API logging
Enable Seller Logging in Logging & Integration (or toggle on Event Logs → Seller Logs). Successful Seller API calls that target the app are recorded with action name and IP.
Requires Seller API request to include app id or name so LibreAuth knows which application to attribute.
Seller API docs: Getting Started
webhook_events JSON
Discord event toggles are stored in apps.webhook_events as JSON:
{"login":true,"register":true,"ban":true,"license":true,"forgot":true,"log":false}Defaults when unset: login/register/ban/license/forgot on, client log off.