Server Ping
Pingt konfigurierte oder beliebige Server per TCP, ICMP oder HTTP(S).
GET
/v1/ping
ping
Authentifizierung
Berechtigung ping für konfigurierte Server.
Berechtigung ping.custom zusätzlich für ?host= (beliebige Hosts).
Parameter
| Parameter | Typ | Pflicht | Beschreibung |
id | integer |
optional |
ID eines konfigurierten Servers |
host | string |
optional |
Beliebiger Host / IP (erfordert ping.custom) |
port | integer |
optional |
Port (Standard: 80) |
type | string |
optional |
tcp | icmp | http | https (Standard: tcp) |
Ohne Parameter werden alle aktiven konfigurierten Server gepingt.
Beispiel-Requests
# Alle Server pingen
curl -H "X-API-Key: apk_dein_key" \
https://api.ferrixx.de/v1/ping
# Server per ID pingen
curl -H "X-API-Key: apk_dein_key" \
"https://api.ferrixx.de/v1/ping?id=1"
# Custom Host pingen (ping.custom)
curl -H "X-API-Key: apk_dein_key" \
"https://api.ferrixx.de/v1/ping?host=example.com&port=443&type=https"
Beispiel-Antwort (alle Server)
{
"success": true,
"message": "OK",
"data": [
{
"status": "online",
"latency_ms": 3,
"type": "tcp",
"host": "192.168.1.10",
"port": 80,
"server": {
"id": 1,
"name": "Webserver 01",
"host": "192.168.1.10",
"port": 80,
"type": "tcp"
}
},
{
"status": "offline",
"latency_ms": null,
"type": "tcp",
"host": "192.168.1.20",
"port": 22,
"message": "Connection refused",
"server": {
"id": 2,
"name": "Backup Server",
"host": "192.168.1.20",
"port": 22,
"type": "tcp"
}
}
],
"timestamp": "2026-06-01T12:00:00+00:00"
}
Ping-Typen
| Typ | Methode | Beschreibung |
tcp | fsockopen() | TCP-Verbindung aufbauen (Standard, schnell) |
icmp | ping -c 1 | ICMP-Ping (klassisches Ping) |
http | HTTP HEAD | HTTP-Erreichbarkeit prüfen |
https | HTTPS HEAD | HTTPS-Erreichbarkeit prüfen |