Skip to content

Monitorowanie użycia

System monitorowania SGS Hub pozwala śledzić wykorzystanie API, zasobów i aktywność konta.

Dashboard przeglądu

Wellness → Overview

Główny dashboard pokazuje kluczowe metryki na pierwszy rzut oka.

Quick Stats

4 główne karty:

API Usage (30 days):

  • Total requests: 45,280
  • Success rate: 98.2%
  • Avg response time: 245ms
  • Trend: ↑ +15% vs poprzedni miesiąc

Resource Usage:

  • Servers: 3/3 (100% wykorzystania)
  • Mods: 48/50 (96%)
  • Backups: 25/30 (83%)
  • Storage: 78.5/100 GB (78.5%)

Rate Limits:

  • Current: 87/100 requests this minute
  • Peak today: 100/100 (limit reached at 14:35)
  • Throttled requests: 12 (0.03%)

Account Activity:

  • Last login: 2 hours ago
  • Active sessions: 2 (Web, Mobile)
  • API keys active: 3
  • Failed auth attempts: 0

Wykresy trendu

7-dniowy wykres API usage:

  • Oś X: Dni tygodnia
  • Oś Y: Liczba requestów
  • Linie: Success (zielona), Failed (czerwona), Rate limited (żółta)

30-dniowy wykres resource usage:

  • Storage over time
  • Mod count trend
  • Backup count trend

API Usage Monitoring

Szczegółowe metryki

Wellness → Monitoring → API Usage

Timeframes:

  • Last 24 hours
  • Last 7 days
  • Last 30 days
  • Custom range

Metryki:

Requests:

  • Total: 45,280
  • Success (2xx): 44,470 (98.2%)
  • Client errors (4xx): 650 (1.4%)
  • Server errors (5xx): 160 (0.4%)

By HTTP Method:

  • GET: 38,500 (85%)
  • POST: 4,200 (9%)
  • PATCH: 2,100 (5%)
  • DELETE: 480 (1%)

By Endpoint:

EndpointRequestsSuccess %Avg Time
GET /api/servers15,20099.5%180ms
GET /api/servers/:id12,50099.1%150ms
POST /api/servers/:id/power3,80097.2%420ms
GET /api/mods5,20099.8%95ms
POST /api/backups2,10096.5%1,850ms

Response Times:

  • Avg: 245ms
  • P50 (median): 180ms
  • P95: 650ms
  • P99: 1,200ms
  • Max: 5,500ms

Rate Limiting:

  • Throttled requests: 12
  • Times hit limit: 3
  • Longest throttle: 45 seconds

By API Key

Filtrowanie według API key:

  1. Dropdown: Select API key
  2. Zobacz użycie tylko tego klucza

Discord Bot (sgsh_abc123...):

  • Requests (30d): 38,200
  • Endpoints używane: 5
  • Errors: 45 (0.12%)
  • Last used: 2 min ago
  • Top endpoint: GET /api/servers/status

Monitoring Script (sgsh_xyz789...):

  • Requests (30d): 7,080
  • Endpoints używane: 2
  • Errors: 0 (0%)
  • Last used: 1 hour ago
  • Top endpoint: GET /api/servers

Wykres żądań

Timeline chart:

  • Hover over point = tooltip z szczegółami
  • Click = drill down do konkretnej godziny
  • Color-coded by status (green/yellow/red)

Przykład tooltip:

2025-10-26 14:00 - 15:00
Total requests: 1,250
Success: 1,238 (99.0%)
Failed: 12 (1.0%)
Rate limited: 0

Top client: Discord Bot (980 requests)
Top endpoint: GET /api/servers (450 requests)

Rate Limit Monitoring

Real-time status

Wellness → Monitoring → Rate Limits

Current minute:

┌─────────────────────────────────────┐
│ Current Requests: 87 / 100          │
│                                     │
│ ████████████████████████░░░░        │
│                                     │
│ Reset in: 18 seconds                │
│ Trend: ↑ Increasing                 │
└─────────────────────────────────────┘

Live feed: Ostatnie 20 requestów w real-time:

14:35:42 GET  /api/servers       200 OK    145ms [Discord Bot]
14:35:41 GET  /api/servers/abc1  200 OK    120ms [Discord Bot]
14:35:40 POST /api/servers/abc1  202 OK    380ms [Web App]
14:35:38 GET  /api/mods          200 OK     85ms [Mobile App]
...

Auto-refresh: Co 5 sekund

Historyczne przekroczenia

Rate limit violations (last 30 days):

Date/TimeAPI KeyRequestsThrottledDuration
2025-10-26 14:35Discord Bot1252545s
2025-10-25 09:12Monitoring1101012s
2025-10-23 16:48Discord Bot10558s

Details:

  • Kliknij row = drill down do szczegółów
  • Zobacz które endpointy były throttled
  • Zobacz response times podczas throttle

Alerting

Skonfiguruj alerty gdy zbliżasz się do limitu.

Settings:

  • Alert at 80% of rate limit
  • Alert at 95% of rate limit
  • Alert when limit exceeded

Notification methods:

  • 🔔 Dashboard notification
  • 📧 Email
  • 💬 Discord webhook (jeśli skonfigurowany)
  • 📱 Push notification (mobile app)

Przykład alertu:

⚠️ Rate Limit Alert

Your API key "Discord Bot" has reached 95% of rate limit.

Current: 95/100 requests this minute
Action: Optimize requests or upgrade plan

[View Details] [Upgrade Plan]

Session History

Active sessions

Wellness → Monitoring → Sessions → Active

Lista aktywnych sesji:

Device/AppLocationIP AddressStartedLast Active
💻 Chrome on WindowsWarsaw, PL203.0.113.502h ago2 min ago
📱 Mobile App (iOS)Warsaw, PL203.0.113.511 day ago30 min ago

Actions:

  • Revoke session - Wyloguj urządzenie
  • Revoke all others - Wyloguj wszystko oprócz obecnej sesji

Use case: Jeśli widzisz nieznane sesje - natychmiast revoke i zmień hasło.

Session history

Wellness → Monitoring → Sessions → History

Ostatnie 100 sesji:

| Date/Time | Device | Location | IP | Duration | Status | |-----------|--------|----------|----|---------

|--------| | 2025-10-26 12:00 | Chrome | Warsaw | 203.0.113.50 | 2h | Active | | 2025-10-25 14:30 | Mobile | Warsaw | 203.0.113.51 | 1h 30m | Ended | | 2025-10-24 09:15 | Firefox | Berlin | 198.51.100.1 | 45m | Ended |

Filtry:

  • By device type (Web / Mobile / API)
  • By status (Active / Ended / Revoked)
  • By date range

Failed login attempts

Security monitoring.

Wellness → Monitoring → Sessions → Failed Logins

Ostatnie nieudane próby:

Date/TimeUsername/EmailIP AddressReason
2025-10-26 03:15admin192.0.2.100Wrong password
2025-10-25 12:30user@example.com192.0.2.101Account locked

Suspicious activity

Jeśli widzisz wiele failed logins z różnych IP:

  1. Natychmiast zmień hasło
  2. Włącz 2FA (Settings → Security)
  3. Sprawdź czy konto nie jest skompromitowane
  4. Skontaktuj się z supportem jeśli podejrzewasz atak

Resource Usage Monitoring

By plan limits

Wellness → Monitoring → Resources

Widgets dla każdego zasobu:

Servers: 3/3 (100%)

████████████████████████████████ 100%

Used: 3 servers
Limit: 3 servers (Pro plan)
Status: At limit

[Upgrade to Enterprise for 10 servers]

Mods: 48/50 (96%)

█████████████████████████████░░ 96%

Used: 48 mods
Limit: 50 mods (Pro plan)
Remaining: 2 mods
Status: Near limit (warning at 90%)

Storage: 78.5/100 GB (78.5%)

█████████████████████████░░░░░░░ 78.5%

Used: 78.5 GB
Limit: 100 GB (Pro plan)
Breakdown:
  - Game files: 45 GB
  - Mods: 15 GB
  - Backups: 12 GB
  - Saves: 6.5 GB

[Manage Storage]

Backups: 25/30 (83%)

██████████████████████████░░░░░ 83%

Used: 25 backups
Limit: 30 backups (Pro plan)
Breakdown:
  - Thin: 20
  - Full: 5

Oldest: 45 days ago
[Cleanup Old Backups]

30-dniowy wykres resource usage:

Zobaczysz jak użycie zmieniało się over time:

  • Storage trend (czy rośnie?)
  • Mod count (instalujesz więcej czy usuwasz?)
  • Backup count (czy czyścisz stare?)

Use case: Predict kiedy osiągniesz limit i będziesz musiał upgrade plan.

Predictions

SGS Hub używa machine learning aby przewidzieć wykorzystanie zasobów.

Przykład:

📊 Storage Prediction

Current: 78.5 GB / 100 GB
Trend: +2.5 GB/week
Prediction: You will reach 100% in ~8 weeks (Dec 21, 2025)

Recommendation: Consider upgrading to Enterprise (200 GB) or cleaning up old files.

[Upgrade Plan] [Manage Files]

Performance Analytics

API Performance

Wellness → Monitoring → Performance

Response time percentiles:

PercentileTimeStatus
P50 (Median)180ms🟢 Good
P75320ms🟢 Good
P90550ms🟡 Fair
P95650ms🟡 Fair
P991,200ms🔴 Slow

Breakdown by endpoint:

  • Fast endpoints (<200ms): GET /api/servers, GET /api/mods
  • Medium endpoints (200-500ms): POST /api/power, PATCH /api/servers
  • Slow endpoints (>500ms): POST /api/backups, GET /api/analytics

Slowest requests (last 24h):

TimeEndpointDurationStatusAPI Key
14:35POST /api/backups5,500ms200Web App
12:20GET /api/analytics3,200ms200Mobile
09:15POST /api/mods/install2,800ms202Discord Bot

Recommendations:

  • Cache frequently accessed endpoints
  • Use pagination for large responses
  • Avoid polling - use webhooks when available

Server Performance

Dla Twoich serwerów:

Average metrics (last 30 days):

ServerUptimeAvg CPUAvg RAMPlayers (avg)
Apex Island99.5%45%5.2 GB35
Warriors Cluster98.2%38%4.8 GB28
Test Server92.1%25%2.1 GB5

Trend analysis:

  • CPU trend: ↑ +5% (increasing load)
  • RAM trend: → Stable
  • Uptime trend: ↓ -1.2% (more crashes lately)

Alerts:

  • Test Server uptime <95% (threshold: 95%)
  • Apex Island RAM usage approaching limit

Exporting Data

Export options

Wellness → Monitoring → Export

Wybierz co exportować:

  • ☐ API usage logs
  • ☐ Resource usage history
  • ☐ Session history
  • ☐ Performance metrics
  • ☐ Rate limit violations

Format:

  • CSV (Excel-friendly)
  • JSON (programmatic use)
  • PDF (report for stakeholders)

Time range:

  • Last 7 days
  • Last 30 days
  • Last 90 days
  • Custom range
  • All time

Kliknij Export:

⏳ Generating export...

Your export is ready!
File: sgshub-monitoring-2025-10-26.csv
Size: 2.5 MB

[Download] [Email to me]

Use cases

Auditing: Export session history dla security audit.

Billing: Export API usage do verify invoice charges.

Analysis: Export performance metrics do Excel dla detailed analysis.

Compliance: Export all data dla GDPR/compliance requirements.

Alerting & Notifications

Alert rules

Settings → Notifications → Monitoring Alerts

Dostępne alerty:

API Usage:

  • ☑ Daily request count exceeds X
  • ☑ Error rate exceeds Y%
  • ☑ Response time exceeds Zms

Rate Limits:

  • ☑ Approaching rate limit (80%)
  • ☑ Rate limit exceeded
  • ☐ Multiple throttles in short time

Resources:

  • ☑ Storage >90%
  • ☑ Approaching plan limits (any resource >90%)
  • ☐ Server uptime <95%

Security:

  • ☑ Multiple failed login attempts (>5 in 10 min)
  • ☑ New session from unknown location
  • ☑ API key used from unexpected IP

Delivery methods: Wybierz jak otrzymać alerty:

  • ☑ Email
  • ☑ Dashboard notification
  • ☐ SMS (Enterprise only)
  • ☐ Discord webhook
  • ☐ Slack webhook

Frequency:

  • Immediate (real-time)
  • Digest (once per hour)
  • Daily summary (once per day)

Alert history

Wellness → Monitoring → Alerts

Ostatnie alerty:

Date/TimeTypeSeverityMessageStatus
2025-10-26 14:35Rate LimitWarningExceeded limit: Discord BotAcknowledged
2025-10-25 09:00StorageWarningStorage at 91%Acknowledged
2025-10-24 12:30SecurityCritical10 failed loginsResolved

Actions:

  • Acknowledge - Potwierdzasz że widziałeś alert
  • Resolve - Problem został rozwiązany
  • Mute for 24h - Temporarily disable similar alerts

Best Practices

Monitoring

  • Sprawdzaj dashboard regularnie - Min. raz w tygodniu
  • Konfiguruj alerty - Nie czekaj aż coś się zepsuje
  • Monitor API keys osobno - Track usage per key
  • Export data monthly - Dla audytu i analysys
  • Review failed attempts - Security first
  • Watch trends - Przewiduj problemy zanim wystąpią

Performance

  • Cache aggressively - Zmniejsz API calls
  • Optimize slow endpoints - Focus na P95/P99
  • Use pagination - Nie pobieraj wszystkiego naraz
  • Implement retry logic - Z exponential backoff
  • Monitor rate limits - Stay below 80% normalnie

Security

  • Review sessions weekly - Revoke unknown
  • Enable 2FA - Extra protection
  • Rotate API keys quarterly - Every 90 days
  • Use IP whitelisting - When possible
  • Investigate failed logins - Don't ignore

Troubleshooting

Metryki nie aktualizują się

Problem: Dashboard shows old data

Rozwiązanie:

  • Odśwież stronę (Ctrl+F5)
  • Sprawdź czy time range jest poprawny
  • Jeśli >24h stare - skontaktuj się z supportem

Export fails

Problem: Export button nie działa lub file corrupt

Rozwiązanie:

  • Zmniejsz time range (może za dużo danych)
  • Spróbuj inny format (CSV zamiast JSON)
  • Wyłącz adblocker (może blokować download)

Alerts nie przychodzą

Problem: Nie otrzymujesz alertów pomimo konfiguracji

Sprawdź:

  • Settings → Notifications → Czy włączone?
  • Email settings → Czy email verified?
  • Spam folder → Może tam trafiają?
  • Alert rules → Czy thresholdy są realistic?

Następne kroki

Dokumentacja SGS Hub