Für Entwickler

API-Dokumentation

Mit der PABLO Listing-API meldet dein Bot seine Zahlen, und du fragst Bots und Votes ab. Alle Antworten sind JSON.

Basis-URL:https://botlist.dislook.buzz/api

Schnellstart

  1. 1Reiche deinen Bot ein und warte auf die Freischaltung.
  2. 2Öffne im Dashboard „Bot bearbeiten“ und erzeuge unter „API & Stats“ einen Token.
  3. 3Sende die Server-Anzahl beim Start und danach etwa alle 30 Minuten an den Stats-Endpunkt.
Zum Dashboard

Authentifizierung

Schreibende Endpunkte für deinen Bot brauchen den API-Token im Header Authorization – wahlweise mit oder ohne „Bearer“. Gespeichert wird nur ein Hash: Geht der Token verloren, erzeuge einfach einen neuen, der alte wird dabei ungültig.

HTTP
Authorization: bl_xxxxxxxxxxxxxxxx
# optional:
Authorization: Bearer bl_xxxxxxxxxxxxxxxx
Der Token gehört nur auf deinen Server. Niemals im Code auf GitHub oder im Client veröffentlichen.

Stats posten

POST/api/bots/:id/stats

Meldet die aktuelle Server- und Shard-Anzahl. Ein Post in den letzten 7 Tagen ist Voraussetzung für die Zertifizierung.

FeldTypBeschreibung
servers (Pflicht)integerAnzahl der Server, auf denen der Bot ist
shards (optional)integerAnzahl der Shards (mindestens 1)
Anfrage · curl
curl -X POST https://botlist.dislook.buzz/api/bots/123456789012345678/stats \
  -H "Authorization: bl_xxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{"servers": 1234, "shards": 2}'
Antwort · 200
{
  "servers": 1234,
  "shards": 2,
  "statsPostedAt": "2026-10-02T12:00:00.000Z"
}

Beispiele

JavaScript · discord.js
// discord.js v14
const { Client, GatewayIntentBits } = require("discord.js");

const client = new Client({ intents: [GatewayIntentBits.Guilds] });

async function postStats() {
  const res = await fetch("https://botlist.dislook.buzz/api/bots/" + client.user.id + "/stats", {
    method: "POST",
    headers: {
      Authorization: process.env.PABLO_LISTING_TOKEN,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      servers: client.guilds.cache.size,
      shards: client.shard?.count ?? 1,
    }),
  });
  if (!res.ok) console.warn("PABLO Listing:", (await res.json()).error);
}

client.once("ready", () => {
  postStats();
  setInterval(postStats, 30 * 60 * 1000); // 30 min
});

client.login(process.env.DISCORD_TOKEN);
Python · discord.py
# discord.py 2.x
import os, aiohttp, discord
from discord.ext import tasks

client = discord.Client(intents=discord.Intents.default())

@tasks.loop(minutes=30)
async def post_stats():
    async with aiohttp.ClientSession() as session:
        await session.post(
            f"https://botlist.dislook.buzz/api/bots/{client.user.id}/stats",
            headers={"Authorization": os.environ["PABLO_LISTING_TOKEN"]},
            json={"servers": len(client.guilds), "shards": client.shard_count or 1},
        )

@client.event
async def on_ready():
    if not post_stats.is_running():
        post_stats.start()

client.run(os.environ["DISCORD_TOKEN"])

Bots abfragen

GET/api/bots?q=&tag=&sort=votes&limit=20

Liefert alle freigeschalteten Bots. Öffentlich, keine Authentifizierung nötig.

FeldTypBeschreibung
q (optional)stringSuchbegriff (Name, Beschreibung, Tag)
tag (optional)stringName einer Kategorie
sort (optional)stringvotes, servers oder newest
limit (optional)integerMaximale Anzahl (1–100)
Antwort · 200
{
  "bots": [
    {
      "id": "123456789012345678",
      "name": "Beispiel-Bot",
      "short": "…",
      "tags": ["Moderation", "Utility"],
      "votes": 128,
      "servers": 1234,
      "shards": 2,
      "certified": true,
      "vanity": "beispiel",
      "commands": [{ "name": "/help", "description": "…" }],
      "reviews": [{ "id": 1, "author": "…", "rating": 5, "text": "…", "date": "…" }]
    }
  ]
}

Einzelner Bot

GET/api/bots/:id

Liefert einen einzelnen Bot inklusive Befehlen und Bewertungen.

FeldTypBeschreibung
id (Pflicht)stringClient-ID des Bots
Anfrage · curl
curl https://botlist.dislook.buzz/api/bots/123456789012345678

Votes prüfen

GET/api/bots/:id/vote

Zeigt den Vote-Stand. Ist ein Nutzer angemeldet, steht dabei, wann er wieder voten darf.

Antwort · 200
{
  "votes": 128,
  "loggedIn": true,
  "canVote": false,
  "nextVoteAt": "2026-10-02T22:00:00.000Z"
}

Fehler & Limits

Fehler antworten mit einem passenden HTTP-Status und einem JSON-Objekt mit „error“.

StatusBedeutung
400Ungültige Eingaben
401Token fehlt oder ist falsch
403Keine Berechtigung
404Bot nicht gefunden
429Zu früh erneut gevotet
Antwort · 401
{ "error": "Ungültiger Token." }

Nutzer können jeden Bot alle 12 Stunden voten. Für Stats-Posts reicht ein Intervall von etwa 30 Minuten.