{"openapi":"3.0.3","info":{"title":"Vibe API","version":"0.1.0","description":"API von Vibe Craft Studios für den Vibe Launcher und weitere Clients. Realtime-Gateway unter `/ws` (siehe docs/PROTOCOL.md)."},"servers":[{"url":"https://vibe.henny.dev"}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"},"adminCookie":{"type":"apiKey","in":"cookie","name":"vibe_admin"},"relaySecret":{"type":"http","scheme":"bearer"}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{},"retryAfter":{"type":"number"}},"required":["code","message"]}},"required":["error"]}}},"paths":{"/api/v1/meta":{"get":{"summary":"Server-Infos und aktive Features","tags":["Meta"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"version":{"type":"string"},"apiVersion":{"type":"number","enum":[1]},"motd":{"nullable":true,"type":"string"},"features":{"type":"object","properties":{"registration":{"type":"boolean"},"chat":{"type":"boolean"},"sharing":{"type":"boolean"},"hosting":{"type":"boolean"},"invites":{"type":"boolean"}},"required":["registration","chat","sharing","hosting","invites"],"additionalProperties":false},"limits":{"type":"object","properties":{"chatMessageMaxLength":{"type":"number"},"maxGroupMembers":{"type":"number"}},"required":["chatMessageMaxLength","maxGroupMembers"],"additionalProperties":false},"publicUrl":{"type":"string"}},"required":["name","version","apiVersion","motd","features","limits","publicUrl"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/v1/auth/challenge":{"post":{"summary":"Login-Challenge anfordern","description":"Liefert eine `serverId`. Der Client ruft damit Mojangs `POST https://sessionserver.mojang.com/session/minecraft/join` mit seinem Minecraft-Access-Token auf und danach `/auth/verify`. Das Minecraft-Token verlässt den Client nie.","tags":["Auth"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"serverId":{"type":"string"},"expiresAt":{"type":"string"}},"required":["serverId","expiresAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/v1/auth/verify":{"post":{"summary":"Login abschließen (Mojang hasJoined)","tags":["Auth"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"accessToken":{"type":"string"},"expiresIn":{"type":"number"},"refreshToken":{"type":"string"},"refreshExpiresAt":{"type":"string"},"sessionId":{"type":"string"},"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"},"privacy":{"type":"object","properties":{"friendRequests":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"directMessages":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"invites":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"showHosting":{"type":"boolean"}},"required":["friendRequests","directMessages","invites","showHosting"],"additionalProperties":false},"limits":{"type":"object","properties":{"maxHosts":{"type":"number"},"maxPlayersPerHost":{"nullable":true,"type":"number"},"maxPacks":{"type":"number"},"maxFriends":{"type":"number"},"maxPackOverridesMb":{"type":"number"}},"required":["maxHosts","maxPlayersPerHost","maxPacks","maxFriends","maxPackOverridesMb"],"additionalProperties":false},"presenceStatus":{"type":"string","enum":["online","away","busy","invisible"]}},"required":["id","name","skin","statusText","badge","createdAt","privacy","limits","presenceStatus"],"additionalProperties":false},"created":{"type":"boolean"}},"required":["accessToken","expiresIn","refreshToken","refreshExpiresAt","sessionId","user","created"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":25},"serverId":{"type":"string","minLength":1,"maxLength":64},"client":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":40,"description":"z. B. \"vibe-launcher\""},"version":{"type":"string","minLength":1,"maxLength":40},"platform":{"type":"string","minLength":1,"maxLength":40,"description":"z. B. \"windows\", \"macos\", \"linux\""}},"required":["name","version","platform"]}},"required":["name","serverId","client"]}}}}}},"/api/v1/auth/refresh":{"post":{"summary":"Tokens erneuern (Refresh-Token rotiert)","tags":["Auth"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"accessToken":{"type":"string"},"expiresIn":{"type":"number"},"refreshToken":{"type":"string"},"refreshExpiresAt":{"type":"string"},"sessionId":{"type":"string"}},"required":["accessToken","expiresIn","refreshToken","refreshExpiresAt","sessionId"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"refreshToken":{"type":"string","minLength":20,"maxLength":200}},"required":["refreshToken"]}}}}}},"/api/v1/auth/logout":{"post":{"summary":"Aktuelle Sitzung beenden","tags":["Auth"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/auth/sessions":{"get":{"summary":"Angemeldete Geräte","tags":["Auth"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"client":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":40,"description":"z. B. \"vibe-launcher\""},"version":{"type":"string","minLength":1,"maxLength":40},"platform":{"type":"string","minLength":1,"maxLength":40,"description":"z. B. \"windows\", \"macos\", \"linux\""}},"required":["name","version","platform"],"additionalProperties":false},"ip":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"lastUsedAt":{"type":"string"},"expiresAt":{"type":"string"},"current":{"type":"boolean"}},"required":["id","client","ip","createdAt","lastUsedAt","expiresAt","current"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/auth/sessions/{id}":{"delete":{"summary":"Gerät abmelden","tags":["Auth"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/me":{"get":{"summary":"Eigenes Profil","tags":["Profil"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"},"privacy":{"type":"object","properties":{"friendRequests":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"directMessages":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"invites":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"showHosting":{"type":"boolean"}},"required":["friendRequests","directMessages","invites","showHosting"],"additionalProperties":false},"limits":{"type":"object","properties":{"maxHosts":{"type":"number"},"maxPlayersPerHost":{"nullable":true,"type":"number"},"maxPacks":{"type":"number"},"maxFriends":{"type":"number"},"maxPackOverridesMb":{"type":"number"}},"required":["maxHosts","maxPlayersPerHost","maxPacks","maxFriends","maxPackOverridesMb"],"additionalProperties":false},"presenceStatus":{"type":"string","enum":["online","away","busy","invisible"]}},"required":["id","name","skin","statusText","badge","createdAt","privacy","limits","presenceStatus"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"patch":{"summary":"Statustext / Privatsphäre ändern","tags":["Profil"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"},"privacy":{"type":"object","properties":{"friendRequests":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"directMessages":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"invites":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"showHosting":{"type":"boolean"}},"required":["friendRequests","directMessages","invites","showHosting"],"additionalProperties":false},"limits":{"type":"object","properties":{"maxHosts":{"type":"number"},"maxPlayersPerHost":{"nullable":true,"type":"number"},"maxPacks":{"type":"number"},"maxFriends":{"type":"number"},"maxPackOverridesMb":{"type":"number"}},"required":["maxHosts","maxPlayersPerHost","maxPacks","maxFriends","maxPackOverridesMb"],"additionalProperties":false},"presenceStatus":{"type":"string","enum":["online","away","busy","invisible"]}},"required":["id","name","skin","statusText","badge","createdAt","privacy","limits","presenceStatus"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"statusText":{"nullable":true,"type":"string","maxLength":120},"privacy":{"type":"object","properties":{"friendRequests":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"directMessages":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"invites":{"type":"string","enum":["everyone","friends_of_friends","friends","nobody"]},"showHosting":{"type":"boolean"}}}}}}}}}},"/api/v1/users/search":{"get":{"summary":"Nutzer nach Minecraft-Namen suchen (Präfix)","tags":["Nutzer"],"parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":25}},{"name":"limit","in":"query","required":false,"schema":{"default":20,"type":"integer","minimum":1,"maximum":50}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"},"relationship":{"type":"string","enum":["none","friend","incoming","outgoing","blocked","blocked_by","self"]}},"required":["id","name","skin","statusText","badge","createdAt","relationship"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/users/{userId}":{"get":{"summary":"Nutzerprofil","tags":["Nutzer"],"parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"},"relationship":{"type":"string","enum":["none","friend","incoming","outgoing","blocked","blocked_by","self"]}},"required":["id","name","skin","statusText","badge","createdAt","relationship"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/friends":{"get":{"summary":"Freundesliste mit Online-Status","tags":["Freunde"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"since":{"type":"string"},"presence":{"type":"object","properties":{"userId":{"type":"string"},"status":{"type":"string","enum":["online","away","busy","offline"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"],"additionalProperties":false},"startedAt":{"nullable":true,"type":"string"}},"required":["type","joinable"],"additionalProperties":false},"updatedAt":{"type":"string"}},"required":["userId","status","activity","updatedAt"],"additionalProperties":false}},"required":["user","since","presence"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/friends/requests":{"get":{"summary":"Offene Freundschaftsanfragen (ein- und ausgehend)","tags":["Freunde"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"to":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"createdAt":{"type":"string"},"direction":{"type":"string","enum":["incoming","outgoing"]}},"required":["id","from","to","createdAt","direction"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"post":{"summary":"Freundschaftsanfrage senden (per userId oder Minecraft-Name)","description":"Hat der andere bereits eine Anfrage an mich geschickt, wird sie direkt angenommen (`status: accepted`).","tags":["Freunde"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["pending","accepted"]},"request":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"to":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"createdAt":{"type":"string"},"direction":{"type":"string","enum":["incoming","outgoing"]}},"required":["id","from","to","createdAt","direction"],"additionalProperties":false},"friend":{"nullable":true,"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"since":{"type":"string"},"presence":{"type":"object","properties":{"userId":{"type":"string"},"status":{"type":"string","enum":["online","away","busy","offline"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"],"additionalProperties":false},"startedAt":{"nullable":true,"type":"string"}},"required":["type","joinable"],"additionalProperties":false},"updatedAt":{"type":"string"}},"required":["userId","status","activity","updatedAt"],"additionalProperties":false}},"required":["user","since","presence"],"additionalProperties":false}},"required":["status","request","friend"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"userId":{"type":"string","minLength":1,"maxLength":64}},"required":["userId"]},{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":25}},"required":["name"]}]}}}}}},"/api/v1/friends/requests/{id}/accept":{"post":{"summary":"Anfrage annehmen","tags":["Freunde"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"since":{"type":"string"},"presence":{"type":"object","properties":{"userId":{"type":"string"},"status":{"type":"string","enum":["online","away","busy","offline"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"],"additionalProperties":false},"startedAt":{"nullable":true,"type":"string"}},"required":["type","joinable"],"additionalProperties":false},"updatedAt":{"type":"string"}},"required":["userId","status","activity","updatedAt"],"additionalProperties":false}},"required":["user","since","presence"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/friends/requests/{id}/decline":{"post":{"summary":"Anfrage ablehnen","tags":["Freunde"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/friends/requests/{id}":{"delete":{"summary":"Eigene Anfrage zurückziehen","tags":["Freunde"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/friends/{userId}":{"delete":{"summary":"Freund entfernen","tags":["Freunde"],"parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/blocks":{"get":{"summary":"Blockierte Nutzer","tags":["Freunde"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/blocks/{userId}":{"put":{"summary":"Nutzer blockieren (entfernt Freundschaft und Anfragen)","tags":["Freunde"],"parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"delete":{"summary":"Blockierung aufheben","tags":["Freunde"],"parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/presence":{"put":{"summary":"Status/Aktivität setzen (alternativ über das Gateway)","description":"Online ist man nur mit offener Gateway-Verbindung; ohne Verbindung wird der Status gespeichert und beim nächsten Verbinden genutzt.","tags":["Presence"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"userId":{"type":"string"},"status":{"type":"string","enum":["online","away","busy","offline"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"],"additionalProperties":false},"startedAt":{"nullable":true,"type":"string"}},"required":["type","joinable"],"additionalProperties":false},"updatedAt":{"type":"string"}},"required":["userId","status","activity","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["online","away","busy","invisible"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"]},"startedAt":{"nullable":true,"type":"string"}},"required":["type"]}}}}}}}},"/api/v1/presence/friends":{"get":{"summary":"Online-Status aller Freunde","tags":["Presence"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"userId":{"type":"string"},"status":{"type":"string","enum":["online","away","busy","offline"]},"activity":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["playing","launcher","hosting"]},"instanceId":{"nullable":true,"type":"string","maxLength":100},"instanceName":{"nullable":true,"type":"string","maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"server":{"nullable":true,"type":"string","maxLength":255},"world":{"nullable":true,"type":"string","maxLength":100},"joinable":{"default":false,"type":"boolean"},"join":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct","invite"]},"address":{"nullable":true,"type":"string","maxLength":255},"port":{"nullable":true,"type":"integer","minimum":1,"maximum":65535},"hostSessionId":{"nullable":true,"type":"string"}},"required":["type","address"],"additionalProperties":false},"startedAt":{"nullable":true,"type":"string"}},"required":["type","joinable"],"additionalProperties":false},"updatedAt":{"type":"string"}},"required":["userId","status","activity","updatedAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/notifications":{"get":{"summary":"Inbox (neueste zuerst)","tags":["Benachrichtigungen"],"parameters":[{"name":"unread","in":"query","required":false,"schema":{"default":false,"type":"boolean"}},{"name":"before","in":"query","required":false,"schema":{"description":"ISO-Zeitpunkt für Paging","type":"string","maxLength":40}},{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"notifications":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"friend_request, friend_accepted, invite, warning, sanction, pack_removed, system …"},"title":{"type":"string"},"body":{"nullable":true,"type":"string"},"data":{"nullable":true,"type":"object","additionalProperties":{}},"createdAt":{"type":"string"},"readAt":{"nullable":true,"type":"string"}},"required":["id","type","title","body","data","createdAt","readAt"],"additionalProperties":false}},"unreadCount":{"type":"number"}},"required":["notifications","unreadCount"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/notifications/read":{"post":{"summary":"Als gelesen markieren (ids oder alle)","tags":["Benachrichtigungen"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"maxItems":500,"type":"array","items":{"type":"string","maxLength":64}},"all":{"type":"boolean"}}}}}}}},"/api/v1/notifications/{id}":{"delete":{"summary":"Benachrichtigung löschen","tags":["Benachrichtigungen"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/reports":{"post":{"summary":"Nachricht, Nutzer oder Pack melden","tags":["Moderation"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"targetType":{"type":"string","enum":["message","user","pack"]},"targetId":{"type":"string","minLength":1,"maxLength":64},"reason":{"type":"string","enum":["spam","harassment","cheating","inappropriate","impersonation","malware","other"]},"details":{"type":"string","maxLength":1000}},"required":["targetType","targetId","reason"]}}}}}},"/api/v1/chats":{"get":{"summary":"Eigene Chats","tags":["Chats"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"post":{"summary":"Gruppenchat erstellen (Mitglieder müssen Freunde sein)","tags":["Chats"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":60},"memberIds":{"default":[],"maxItems":200,"type":"array","items":{"type":"string","minLength":1,"maxLength":64}}},"required":["name"]}}}}}},"/api/v1/chats/{chatId}":{"get":{"summary":"Chat-Details","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"patch":{"summary":"Gruppe umbenennen / Besitz übertragen (Besitzer)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":60},"ownerId":{"type":"string","minLength":1,"maxLength":64}}}}}}}},"/api/v1/chats/dm":{"post":{"summary":"Direktnachricht öffnen (holt bestehende oder legt an)","tags":["Chats"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"userId":{"type":"string","minLength":1,"maxLength":64}},"required":["userId"]}}}}}},"/api/v1/chats/{chatId}/members":{"post":{"summary":"Freunde zur Gruppe hinzufügen","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["dm","group"]},"name":{"nullable":true,"type":"string"},"ownerId":{"nullable":true,"type":"string"},"members":{"type":"array","items":{"type":"object","properties":{"user":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"role":{"type":"string","enum":["owner","member"]},"joinedAt":{"type":"string"},"lastReadMessageId":{"nullable":true,"type":"string"}},"required":["user","role","joinedAt","lastReadMessageId"],"additionalProperties":false}},"lastMessage":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false},"unreadCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","type","name","ownerId","members","lastMessage","unreadCount","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"userIds":{"minItems":1,"maxItems":50,"type":"array","items":{"type":"string","minLength":1,"maxLength":64}}},"required":["userIds"]}}}}}},"/api/v1/chats/{chatId}/members/{userId}":{"delete":{"summary":"Mitglied entfernen (Besitzer) bzw. Gruppe verlassen (eigene ID)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","maxLength":64}},{"name":"userId","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/chats/{chatId}/messages":{"get":{"summary":"Verlauf (neueste zuerst, Paging mit `before` = Nachrichten-ID)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}},{"name":"before","in":"query","required":false,"schema":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}},{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false}},"hasMore":{"type":"boolean"}},"required":["messages","hasMore"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"post":{"summary":"Nachricht senden","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"content":{"type":"string","minLength":1,"maxLength":10000},"nonce":{"type":"string","maxLength":64},"replyToId":{"type":"string","maxLength":64}},"required":["content"]}}}}}},"/api/v1/chats/{chatId}/messages/{messageId}":{"patch":{"summary":"Eigene Nachricht bearbeiten","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}},{"name":"messageId","in":"path","required":true,"schema":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"chatId":{"type":"string"},"authorId":{"nullable":true,"type":"string"},"kind":{"type":"string","enum":["text","system","invite"]},"content":{"type":"string"},"system":{"nullable":true,"type":"object","properties":{"event":{"type":"string","enum":["member_added","member_removed","member_left","renamed","chat_created","owner_changed"]},"actorId":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"name":{"nullable":true,"type":"string"}},"required":["event","actorId"],"additionalProperties":false},"invite":{"nullable":true,"type":"object","properties":{"inviteId":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"title":{"type":"string"},"subtitle":{"nullable":true,"type":"string"},"packCode":{"nullable":true,"type":"string"},"expiresAt":{"type":"string"}},"required":["inviteId","kind","title","subtitle","packCode","expiresAt"],"additionalProperties":false},"replyToId":{"nullable":true,"type":"string"},"nonce":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"editedAt":{"nullable":true,"type":"string"},"deleted":{"type":"boolean"}},"required":["id","chatId","authorId","kind","content","system","invite","replyToId","nonce","createdAt","editedAt","deleted"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"content":{"type":"string","minLength":1,"maxLength":10000}},"required":["content"]}}}}},"delete":{"summary":"Nachricht löschen (eigene; Gruppenbesitzer: alle)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}},{"name":"messageId","in":"path","required":true,"schema":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/chats/{chatId}/read":{"post":{"summary":"Als gelesen markieren (bis messageId, Standard: neueste)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"messageId":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}}}}}}}},"/api/v1/chats/{chatId}/typing":{"post":{"summary":"Tippen-Anzeige (ca. 8 s gültig)","tags":["Chats"],"parameters":[{"name":"chatId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/invites":{"get":{"summary":"Einladungen (eingehend/ausgehend, die letzten 7 Tage)","tags":["Einladungen"],"parameters":[{"name":"direction","in":"query","required":false,"schema":{"default":"incoming","type":"string","enum":["incoming","outgoing"]}},{"name":"pendingOnly","in":"query","required":false,"schema":{"default":false,"type":"boolean"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"toUserId":{"nullable":true,"type":"string"},"chatId":{"nullable":true,"type":"string"},"target":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"instanceName":{"nullable":true,"type":"string","maxLength":100},"packCode":{"nullable":true,"type":"string","maxLength":16}},"required":["name"],"additionalProperties":false},"message":{"nullable":true,"type":"string"},"hostSessionId":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["pending","accepted","declined","cancelled","expired"]},"myResponse":{"nullable":true,"type":"string","enum":["accepted","declined"]},"createdAt":{"type":"string"},"expiresAt":{"type":"string"}},"required":["id","kind","from","toUserId","chatId","target","message","hostSessionId","status","myResponse","createdAt","expiresAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]},"post":{"summary":"Einladung senden (an Nutzer oder in einen Chat; erzeugt Einladungskarten)","tags":["Einladungen"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"toUserId":{"nullable":true,"type":"string"},"chatId":{"nullable":true,"type":"string"},"target":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"instanceName":{"nullable":true,"type":"string","maxLength":100},"packCode":{"nullable":true,"type":"string","maxLength":16}},"required":["name"],"additionalProperties":false},"message":{"nullable":true,"type":"string"},"hostSessionId":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["pending","accepted","declined","cancelled","expired"]},"myResponse":{"nullable":true,"type":"string","enum":["accepted","declined"]},"createdAt":{"type":"string"},"expiresAt":{"type":"string"}},"required":["id","kind","from","toUserId","chatId","target","message","hostSessionId","status","myResponse","createdAt","expiresAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","enum":["world","server","party","modpack"]},"toUserIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1,"maxLength":64}},"chatId":{"type":"string","maxLength":64},"target":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"instanceName":{"nullable":true,"type":"string","maxLength":100},"packCode":{"nullable":true,"type":"string","maxLength":16}},"required":["name"]},"message":{"type":"string","maxLength":300},"hostSessionId":{"type":"string","maxLength":64},"connection":{"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct"]},"address":{"type":"string","minLength":1,"maxLength":255},"port":{"type":"integer","minimum":1,"maximum":65535}},"required":["type","address"]},"ttlMinutes":{"type":"integer","minimum":1,"maximum":10080}},"required":["kind","target"]}}}}}},"/api/v1/invites/{id}/accept":{"post":{"summary":"Einladung annehmen – liefert Verbindungsdaten","tags":["Einladungen"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"invite":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"toUserId":{"nullable":true,"type":"string"},"chatId":{"nullable":true,"type":"string"},"target":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"instanceName":{"nullable":true,"type":"string","maxLength":100},"packCode":{"nullable":true,"type":"string","maxLength":16}},"required":["name"],"additionalProperties":false},"message":{"nullable":true,"type":"string"},"hostSessionId":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["pending","accepted","declined","cancelled","expired"]},"myResponse":{"nullable":true,"type":"string","enum":["accepted","declined"]},"createdAt":{"type":"string"},"expiresAt":{"type":"string"}},"required":["id","kind","from","toUserId","chatId","target","message","hostSessionId","status","myResponse","createdAt","expiresAt"],"additionalProperties":false},"connection":{"nullable":true,"type":"object","properties":{"type":{"type":"string","enum":["relay","playit","direct"]},"address":{"type":"string"},"port":{"nullable":true,"type":"number"}},"required":["type","address","port"],"additionalProperties":false},"packCode":{"nullable":true,"type":"string"}},"required":["invite","connection","packCode"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/invites/{id}/decline":{"post":{"summary":"Einladung ablehnen","tags":["Einladungen"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["world","server","party","modpack"]},"from":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"toUserId":{"nullable":true,"type":"string"},"chatId":{"nullable":true,"type":"string"},"target":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"mcVersion":{"nullable":true,"type":"string","maxLength":40},"loader":{"nullable":true,"type":"string","maxLength":40},"instanceName":{"nullable":true,"type":"string","maxLength":100},"packCode":{"nullable":true,"type":"string","maxLength":16}},"required":["name"],"additionalProperties":false},"message":{"nullable":true,"type":"string"},"hostSessionId":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["pending","accepted","declined","cancelled","expired"]},"myResponse":{"nullable":true,"type":"string","enum":["accepted","declined"]},"createdAt":{"type":"string"},"expiresAt":{"type":"string"}},"required":["id","kind","from","toUserId","chatId","target","message","hostSessionId","status","myResponse","createdAt","expiresAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/invites/{id}":{"delete":{"summary":"Eigene Einladung zurückziehen","tags":["Einladungen"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/packs":{"post":{"summary":"Modpack teilen (multipart: manifest, overrides?, icon?, visibility, description?, changelog?)","tags":["Modpacks"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"visibility":{"default":"unlisted","type":"string","enum":["public","unlisted","friends"]},"changelog":{"type":"string","maxLength":5000},"description":{"type":"string","maxLength":5000},"manifest":{"type":"string","description":"vlpack.json als Text"},"overrides":{},"icon":{}},"required":["manifest"]}}}}},"get":{"summary":"Öffentliche Packs durchsuchen","tags":["Modpacks"],"parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":100}},{"name":"mcVersion","in":"query","required":false,"schema":{"type":"string","maxLength":40}},{"name":"loader","in":"query","required":false,"schema":{"type":"string","maxLength":20}},{"name":"sort","in":"query","required":false,"schema":{"default":"downloads","type":"string","enum":["downloads","updated"]}},{"name":"limit","in":"query","required":false,"schema":{"default":24,"type":"integer","minimum":1,"maximum":50}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":10000}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{},{"bearer":[]}]}},"/api/v1/packs/{code}/versions":{"post":{"summary":"Neue Version hochladen (multipart wie beim Erstellen)","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"manifest":{"type":"string"},"overrides":{},"icon":{},"changelog":{"type":"string"}},"required":["manifest"]}}}}},"get":{"summary":"Versionen eines Packs","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{},{"bearer":[]}]}},"/api/v1/packs/mine":{"get":{"summary":"Eigene geteilte Packs","tags":["Modpacks"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/users/{userId}/packs":{"get":{"summary":"Geteilte Packs eines Nutzers (für mich sichtbar)","tags":["Modpacks"],"parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/packs/{code}":{"get":{"summary":"Pack-Infos per Share-Code","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{},{"bearer":[]}]},"patch":{"summary":"Pack bearbeiten (Name, Beschreibung, Sichtbarkeit)","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"description":{"nullable":true,"type":"string","maxLength":5000},"visibility":{"type":"string","enum":["public","unlisted","friends"]}}}}}}},"delete":{"summary":"Pack löschen","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/packs/{code}/download":{"get":{"summary":"Manifest zum Installieren holen (zählt Downloads)","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}},{"name":"version","in":"query","required":false,"schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"pack":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"url":{"type":"string","description":"https://…/p/<code>"},"deepLink":{"type":"string","description":"vibelauncher://pack/<code>"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"owner":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"visibility":{"type":"string","enum":["public","unlisted","friends"]},"mcVersion":{"type":"string"},"loader":{"type":"string"},"iconUrl":{"nullable":true,"type":"string"},"downloads":{"type":"number"},"latestVersion":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"status":{"type":"string","enum":["active","hidden","removed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","code","url","deepLink","name","description","owner","visibility","mcVersion","loader","iconUrl","downloads","latestVersion","status","createdAt","updatedAt"],"additionalProperties":false},"version":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"string"},"changelog":{"nullable":true,"type":"string"},"mcVersion":{"type":"string"},"loader":{"type":"string"},"loaderVersion":{"nullable":true,"type":"string"},"fileCount":{"type":"number"},"overrides":{"nullable":true,"type":"object","properties":{"size":{"type":"number"},"sha256":{"type":"string"},"url":{"type":"string"}},"required":["size","sha256","url"],"additionalProperties":false},"createdAt":{"type":"string"}},"required":["id","version","changelog","mcVersion","loader","loaderVersion","fileCount","overrides","createdAt"],"additionalProperties":false},"manifest":{"type":"object","properties":{"format_version":{"type":"number","enum":[1]},"name":{"type":"string","minLength":1,"maxLength":100},"version":{"nullable":true,"type":"string","maxLength":40},"author":{"nullable":true,"type":"string","maxLength":100},"description":{"nullable":true,"type":"string","maxLength":5000},"mc_version":{"type":"string","minLength":1,"maxLength":40},"loader":{"type":"object","properties":{"kind":{"type":"string","enum":["vanilla","fabric","quilt","forge","neoforge"]},"version":{"nullable":true,"type":"string","maxLength":60}},"required":["kind"],"additionalProperties":false},"icon":{"nullable":true,"type":"string","maxLength":256},"files":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"path":{"type":"string","minLength":1,"maxLength":512},"source":{"anyOf":[{"type":"string","enum":["modrinth","curseforge","url"]},{"type":"string","pattern":"^store:[A-Za-z0-9._-]{1,64}$"}]},"project_id":{"nullable":true,"type":"string","maxLength":100},"version_id":{"nullable":true,"type":"string","maxLength":100},"file_id":{"nullable":true,"type":"string","maxLength":100},"url":{"type":"string","maxLength":2048,"format":"uri"},"sha1":{"nullable":true,"type":"string","pattern":"^[0-9a-fA-F]{40}$"},"size":{"nullable":true,"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["path","source","url"],"additionalProperties":false}}},"required":["format_version","name","mc_version","loader","files"],"additionalProperties":{}}},"required":["pack","version","manifest"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{},{"bearer":[]}]}},"/api/v1/packs/{code}/versions/{versionId}/overrides.zip":{"get":{"summary":"Overrides-ZIP herunterladen","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}},{"name":"versionId","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{},{"bearer":[]}]}},"/api/v1/packs/{code}/icon":{"get":{"summary":"Pack-Icon","tags":["Modpacks"],"parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string","minLength":4,"maxLength":16}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/v1/hosting/sessions":{"get":{"summary":"Eigene laufende Host-Sessions","tags":["Hosting"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"host":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"kind":{"type":"string","enum":["world","server"]},"client":{"type":"string","enum":["mod","launcher"]},"slot":{"type":"number"},"address":{"nullable":true,"type":"string"},"mcVersion":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["authorized","online","ended"]},"players":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"uuid":{"nullable":true,"type":"string"},"joinedAt":{"type":"string"}},"required":["name","uuid","joinedAt"],"additionalProperties":false}},"maxPlayers":{"nullable":true,"type":"number"},"startedAt":{"type":"string"},"onlineAt":{"nullable":true,"type":"string"},"endedAt":{"nullable":true,"type":"string"},"endReason":{"nullable":true,"type":"string"}},"required":["id","host","kind","client","slot","address","mcVersion","status","players","maxPlayers","startedAt","onlineAt","endedAt","endReason"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/hosting/friends":{"get":{"summary":"Joinbare Sessions von Freunden","tags":["Hosting"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"host":{"type":"object","properties":{"id":{"type":"string","description":"Minecraft-UUID"},"name":{"type":"string"},"skin":{"type":"object","properties":{"url":{"nullable":true,"type":"string"},"model":{"type":"string","enum":["classic","slim"]},"capeUrl":{"nullable":true,"type":"string"}},"required":["url","model","capeUrl"],"additionalProperties":false},"statusText":{"nullable":true,"type":"string"},"badge":{"type":"string","enum":["user","supporter","staff"]},"createdAt":{"type":"string"}},"required":["id","name","skin","statusText","badge","createdAt"],"additionalProperties":false},"kind":{"type":"string","enum":["world","server"]},"client":{"type":"string","enum":["mod","launcher"]},"slot":{"type":"number"},"address":{"nullable":true,"type":"string"},"mcVersion":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["authorized","online","ended"]},"players":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"uuid":{"nullable":true,"type":"string"},"joinedAt":{"type":"string"}},"required":["name","uuid","joinedAt"],"additionalProperties":false}},"maxPlayers":{"nullable":true,"type":"number"},"startedAt":{"type":"string"},"onlineAt":{"nullable":true,"type":"string"},"endedAt":{"nullable":true,"type":"string"},"endReason":{"nullable":true,"type":"string"}},"required":["id","host","kind","client","slot","address","mcVersion","status","players","maxPlayers","startedAt","onlineAt","endedAt","endReason"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/api/v1/hosting/limits":{"get":{"summary":"Eigene Hosting-Limits","tags":["Hosting"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"enabled":{"type":"boolean"},"maxHosts":{"type":"number"},"maxPlayersPerHost":{"nullable":true,"type":"number"},"active":{"type":"number"}},"required":["enabled","maxHosts","maxPlayersPerHost","active"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"bearer":[]}]}},"/internal/relay/v1/authorize":{"post":{"summary":"Darf dieser Account hosten?","tags":["Relay (intern)"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"allow":{"type":"boolean","enum":[true]},"maxHosts":{"type":"number"},"maxPlayers":{"nullable":true,"type":"number"},"ttl":{"type":"number"}},"required":["allow","maxHosts","maxPlayers","ttl"],"additionalProperties":false},{"type":"object","properties":{"allow":{"type":"boolean","enum":[false]},"code":{"type":"string","enum":["limit","banned","disabled"]},"message":{"type":"string"}},"required":["allow","code","message"],"additionalProperties":false}]}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"relaySecret":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"uuid":{"type":"string","minLength":32,"maxLength":36},"name":{"type":"string","minLength":1,"maxLength":25},"ip":{"type":"string","maxLength":64},"client":{"type":"string","enum":["mod","launcher"]},"kind":{"type":"string","enum":["world","server"]},"slot":{"type":"integer","minimum":0,"maximum":1000000},"mc":{"type":"string","maxLength":40},"version":{"type":"string","maxLength":40},"active":{"type":"integer","minimum":0,"maximum":1000}},"required":["uuid","name","ip","client","kind","slot","active"]}}}}}},"/internal/relay/v1/events":{"post":{"summary":"Ereignisse vom Relay (online/offline/Spieler)","tags":["Relay (intern)"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"relaySecret":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"events":{"maxItems":1000,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["host_online","host_offline","player_join","player_leave","blocked"]},"uuid":{"type":"string","minLength":32,"maxLength":36},"slot":{"type":"integer","minimum":0,"maximum":9007199254740991},"address":{"nullable":true,"type":"string","maxLength":255},"at":{"anyOf":[{"type":"string"},{"type":"number"}]},"player":{"nullable":true,"type":"object","properties":{"name":{"type":"string","maxLength":25},"uuid":{"nullable":true,"type":"string","maxLength":36}},"required":["name"]},"ip":{"nullable":true,"type":"string","maxLength":64},"reason":{"nullable":true,"type":"string","maxLength":40}},"required":["type","uuid","slot","at"]}}},"required":["events"]}}}}}},"/internal/relay/v1/commands":{"get":{"summary":"Offene Befehle für diesen Worker","tags":["Relay (intern)"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"commands":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["kick_host","ban_uuid","unban_uuid","config"]},"uuid":{"type":"string"},"slot":{"nullable":true,"type":"number"},"message":{"type":"string"},"config":{"type":"object","additionalProperties":{}}},"required":["id","type"],"additionalProperties":false}}},"required":["commands"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"relaySecret":[]}]}},"/internal/relay/v1/commands/ack":{"post":{"summary":"Befehle bestätigen","tags":["Relay (intern)"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"relaySecret":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"maxItems":1000,"type":"array","items":{"type":"string","maxLength":64}}},"required":["ids"]}}}}}},"/internal/relay/v1/heartbeat":{"post":{"summary":"Worker-Status melden, aktuelle Konfiguration abholen","tags":["Relay (intern)"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"config":{"type":"object","properties":{"maxHostsPerAccount":{"type":"number"},"maxPlayers":{"nullable":true,"type":"number"},"failMode":{"type":"string","enum":["open","closed"]}},"required":["maxHostsPerAccount","maxPlayers","failMode"],"additionalProperties":false}},"required":["config"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"relaySecret":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"version":{"type":"string","maxLength":40},"hosts":{"type":"integer","minimum":0,"maximum":9007199254740991},"players":{"type":"integer","minimum":0,"maximum":9007199254740991},"uptime":{"type":"number","minimum":0}},"required":["version","hosts","players","uptime"]}}}}}},"/admin/api/auth/login":{"post":{"summary":"Admin-Login Schritt 1 (Passwort)","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"step":{"type":"string","enum":["totp"]},"ticket":{"type":"string"}},"required":["step","ticket"],"additionalProperties":false},{"type":"object","properties":{"step":{"type":"string","enum":["totp_setup"]},"ticket":{"type":"string"},"secret":{"type":"string"},"otpauthUrl":{"type":"string"}},"required":["step","ticket","secret","otpauthUrl"],"additionalProperties":false}]}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","minLength":1,"maxLength":64},"password":{"type":"string","minLength":1,"maxLength":256}},"required":["username","password"]}}}}}},"/admin/api/auth/totp":{"post":{"summary":"Admin-Login Schritt 2 (TOTP-Code bzw. Einrichtung bestätigen)","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"admin":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"},"role":{"type":"string","enum":["owner","admin","moderator"]},"totpEnabled":{"type":"boolean"},"disabled":{"type":"boolean"},"createdAt":{"type":"string"},"lastLoginAt":{"nullable":true,"type":"string"}},"required":["id","username","role","totpEnabled","disabled","createdAt","lastLoginAt"],"additionalProperties":false},"csrfToken":{"type":"string"}},"required":["admin","csrfToken"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ticket":{"type":"string","minLength":10,"maxLength":2048},"code":{"type":"string","pattern":"^\\d{6}$"}},"required":["ticket","code"]}}}}}},"/admin/api/auth/me":{"get":{"summary":"Aktuelles Admin-Konto + CSRF-Token","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"admin":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"},"role":{"type":"string","enum":["owner","admin","moderator"]},"totpEnabled":{"type":"boolean"},"disabled":{"type":"boolean"},"createdAt":{"type":"string"},"lastLoginAt":{"nullable":true,"type":"string"}},"required":["id","username","role","totpEnabled","disabled","createdAt","lastLoginAt"],"additionalProperties":false},"csrfToken":{"type":"string"}},"required":["admin","csrfToken"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/auth/logout":{"post":{"summary":"Admin-Logout","tags":["Admin"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/auth/password":{"post":{"summary":"Eigenes Passwort ändern","tags":["Admin"],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"currentPassword":{"type":"string","minLength":1,"maxLength":256},"newPassword":{"type":"string","minLength":12,"maxLength":256}},"required":["currentPassword","newPassword"]}}}}}},"/admin/api/stats":{"get":{"summary":"Dashboard-Kennzahlen","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"online":{"type":"number"},"connections":{"type":"number"},"activeHosts":{"type":"number"},"playersInHosts":{"type":"number"},"messages24h":{"type":"number"},"users":{"type":"number"},"newUsers24h":{"type":"number"},"openReports":{"type":"number"},"packs":{"type":"number"},"workersOnline":{"type":"number"},"signups":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"count":{"type":"number"}},"required":["day","count"],"additionalProperties":false}},"logins":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"count":{"type":"number"}},"required":["day","count"],"additionalProperties":false}}},"required":["online","connections","activeHosts","playersInHosts","messages24h","users","newUsers24h","openReports","packs","workersOnline","signups","logins"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/users":{"get":{"summary":"Nutzer suchen","tags":["Admin"],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":200}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":100000}},{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":64}},{"name":"filter","in":"query","required":false,"schema":{"default":"all","type":"string","enum":["all","online","banned","muted"]}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/users/{id}":{"get":{"summary":"Nutzer-Details","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]},"patch":{"summary":"Badge, Limits-Override, Statustext","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"badge":{"type":"string","enum":["user","supporter","staff"]},"limits":{"type":"object","properties":{"maxHosts":{"nullable":true,"type":"integer","minimum":0,"maximum":50},"maxPlayersPerHost":{"nullable":true,"type":"integer","minimum":1,"maximum":500},"maxPacks":{"nullable":true,"type":"integer","minimum":0,"maximum":1000},"maxFriends":{"nullable":true,"type":"integer","minimum":1,"maximum":5000},"maxPackOverridesMb":{"nullable":true,"type":"integer","minimum":1,"maximum":4096}}},"statusText":{"nullable":true,"type":"string","maxLength":120}}}}}}}},"/admin/api/users/{id}/sanctions":{"post":{"summary":"Sanktion verhängen (Ban/Mute/Warnung)","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string","enum":["ban","mute","warning"]},"reason":{"type":"string","minLength":1,"maxLength":500},"durationMinutes":{"nullable":true,"type":"integer","minimum":1,"maximum":5256000},"reportId":{"type":"string","maxLength":64}},"required":["type","reason"]}}}}}},"/admin/api/sanctions/{id}":{"delete":{"summary":"Sanktion aufheben","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/users/{id}/sessions/{sid}":{"delete":{"summary":"Gerät abmelden","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","maxLength":64}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/users/{id}/logout":{"post":{"summary":"Alle Geräte abmelden","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/hosting/sessions":{"get":{"summary":"Host-Sessions","tags":["Admin"],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":200}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":100000}},{"name":"status","in":"query","required":false,"schema":{"default":"live","type":"string","enum":["live","recent"]}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/hosting/sessions/{id}/end":{"post":{"summary":"Host-Session beenden","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"reason":{"default":"Von der Moderation beendet","type":"string","minLength":1,"maxLength":200}}}}}}}},"/admin/api/relay/workers":{"get":{"summary":"Relay-Worker","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"region":{"nullable":true,"type":"string"},"secretPrefix":{"type":"string"},"disabled":{"type":"boolean"},"online":{"type":"boolean"},"version":{"nullable":true,"type":"string"},"hosts":{"type":"number"},"players":{"type":"number"},"uptime":{"nullable":true,"type":"number"},"lastHeartbeatAt":{"nullable":true,"type":"string"},"lastIp":{"nullable":true,"type":"string"},"relayId":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"pendingCommands":{"type":"number"}},"required":["id","name","region","secretPrefix","disabled","online","version","hosts","players","uptime","lastHeartbeatAt","lastIp","relayId","createdAt","pendingCommands"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]},"post":{"summary":"Relay-Worker anlegen (Secret wird nur einmal angezeigt)","tags":["Admin"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"worker":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"region":{"nullable":true,"type":"string"},"secretPrefix":{"type":"string"},"disabled":{"type":"boolean"},"online":{"type":"boolean"},"version":{"nullable":true,"type":"string"},"hosts":{"type":"number"},"players":{"type":"number"},"uptime":{"nullable":true,"type":"number"},"lastHeartbeatAt":{"nullable":true,"type":"string"},"lastIp":{"nullable":true,"type":"string"},"relayId":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"pendingCommands":{"type":"number"}},"required":["id","name","region","secretPrefix","disabled","online","version","hosts","players","uptime","lastHeartbeatAt","lastIp","relayId","createdAt","pendingCommands"],"additionalProperties":false},"secret":{"type":"string"}},"required":["worker","secret"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":60},"region":{"type":"string","maxLength":40}},"required":["name"]}}}}}},"/admin/api/relay/workers/{id}/rotate":{"post":{"summary":"Secret rotieren (altes wird sofort ungültig)","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"worker":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"region":{"nullable":true,"type":"string"},"secretPrefix":{"type":"string"},"disabled":{"type":"boolean"},"online":{"type":"boolean"},"version":{"nullable":true,"type":"string"},"hosts":{"type":"number"},"players":{"type":"number"},"uptime":{"nullable":true,"type":"number"},"lastHeartbeatAt":{"nullable":true,"type":"string"},"lastIp":{"nullable":true,"type":"string"},"relayId":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"pendingCommands":{"type":"number"}},"required":["id","name","region","secretPrefix","disabled","online","version","hosts","players","uptime","lastHeartbeatAt","lastIp","relayId","createdAt","pendingCommands"],"additionalProperties":false},"secret":{"type":"string"}},"required":["worker","secret"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/relay/workers/{id}":{"patch":{"summary":"Worker umbenennen/deaktivieren","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"region":{"nullable":true,"type":"string"},"secretPrefix":{"type":"string"},"disabled":{"type":"boolean"},"online":{"type":"boolean"},"version":{"nullable":true,"type":"string"},"hosts":{"type":"number"},"players":{"type":"number"},"uptime":{"nullable":true,"type":"number"},"lastHeartbeatAt":{"nullable":true,"type":"string"},"lastIp":{"nullable":true,"type":"string"},"relayId":{"nullable":true,"type":"string"},"createdAt":{"type":"string"},"pendingCommands":{"type":"number"}},"required":["id","name","region","secretPrefix","disabled","online","version","hosts","players","uptime","lastHeartbeatAt","lastIp","relayId","createdAt","pendingCommands"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":60},"disabled":{"type":"boolean"}}}}}}},"delete":{"summary":"Worker löschen","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/packs":{"get":{"summary":"Geteilte Packs","tags":["Admin"],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":200}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":100000}},{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":100}},{"name":"status","in":"query","required":false,"schema":{"default":"all","type":"string","enum":["all","active","hidden","removed"]}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/packs/{id}":{"patch":{"summary":"Pack moderieren (Status)","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["active","hidden","removed"]},"note":{"type":"string","maxLength":500}},"required":["status"]}}}}},"delete":{"summary":"Pack endgültig löschen","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/reports":{"get":{"summary":"Meldungen","tags":["Admin"],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":200}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":100000}},{"name":"status","in":"query","required":false,"schema":{"default":"open","type":"string","enum":["open","resolved","dismissed","all"]}},{"name":"type","in":"query","required":false,"schema":{"default":"all","type":"string","enum":["message","user","pack","all"]}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/reports/{id}/resolve":{"post":{"summary":"Meldung abschließen","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["resolved","dismissed"]},"note":{"type":"string","maxLength":1000},"removeContent":{"type":"boolean"}},"required":["status"]}}}}}},"/admin/api/messages/{id}":{"delete":{"summary":"Nachricht löschen (Moderation)","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/settings":{"get":{"summary":"Limits & Feature-Flags","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"settings":{"type":"object","properties":{"registrationOpen":{"default":true,"type":"boolean"},"chatEnabled":{"default":true,"type":"boolean"},"sharingEnabled":{"default":true,"type":"boolean"},"hostingEnabled":{"default":true,"type":"boolean"},"invitesEnabled":{"default":true,"type":"boolean"},"motd":{"default":null,"nullable":true,"type":"string","maxLength":500},"maxHostsPerUser":{"default":2,"type":"integer","minimum":0,"maximum":50},"maxPlayersPerHost":{"default":null,"nullable":true,"type":"integer","minimum":1,"maximum":500},"hostAuthTtlSeconds":{"default":60,"type":"integer","minimum":0,"maximum":3600},"relayFailMode":{"default":"open","type":"string","enum":["open","closed"]},"maxFriends":{"default":500,"type":"integer","minimum":1,"maximum":5000},"maxPendingRequests":{"default":100,"type":"integer","minimum":1,"maximum":1000},"maxPacksPerUser":{"default":25,"type":"integer","minimum":0,"maximum":1000},"maxPackVersions":{"default":50,"type":"integer","minimum":1,"maximum":500},"maxPackOverridesMb":{"default":100,"type":"integer","minimum":1,"maximum":4096},"maxManifestKb":{"default":1024,"type":"integer","minimum":16,"maximum":8192},"chatMessageMaxLength":{"default":2000,"type":"integer","minimum":1,"maximum":10000},"chatRatePerMinute":{"default":30,"type":"integer","minimum":1,"maximum":600},"maxGroupMembers":{"default":50,"type":"integer","minimum":2,"maximum":500},"maxGroupsPerUser":{"default":100,"type":"integer","minimum":1,"maximum":1000},"inviteTtlMinutes":{"default":60,"type":"integer","minimum":1,"maximum":10080},"invitesPerHour":{"default":60,"type":"integer","minimum":1,"maximum":1000}},"required":["registrationOpen","chatEnabled","sharingEnabled","hostingEnabled","invitesEnabled","motd","maxHostsPerUser","maxPlayersPerHost","hostAuthTtlSeconds","relayFailMode","maxFriends","maxPendingRequests","maxPacksPerUser","maxPackVersions","maxPackOverridesMb","maxManifestKb","chatMessageMaxLength","chatRatePerMinute","maxGroupMembers","maxGroupsPerUser","inviteTtlMinutes","invitesPerHour"],"additionalProperties":false},"defaults":{"type":"object","properties":{"registrationOpen":{"default":true,"type":"boolean"},"chatEnabled":{"default":true,"type":"boolean"},"sharingEnabled":{"default":true,"type":"boolean"},"hostingEnabled":{"default":true,"type":"boolean"},"invitesEnabled":{"default":true,"type":"boolean"},"motd":{"default":null,"nullable":true,"type":"string","maxLength":500},"maxHostsPerUser":{"default":2,"type":"integer","minimum":0,"maximum":50},"maxPlayersPerHost":{"default":null,"nullable":true,"type":"integer","minimum":1,"maximum":500},"hostAuthTtlSeconds":{"default":60,"type":"integer","minimum":0,"maximum":3600},"relayFailMode":{"default":"open","type":"string","enum":["open","closed"]},"maxFriends":{"default":500,"type":"integer","minimum":1,"maximum":5000},"maxPendingRequests":{"default":100,"type":"integer","minimum":1,"maximum":1000},"maxPacksPerUser":{"default":25,"type":"integer","minimum":0,"maximum":1000},"maxPackVersions":{"default":50,"type":"integer","minimum":1,"maximum":500},"maxPackOverridesMb":{"default":100,"type":"integer","minimum":1,"maximum":4096},"maxManifestKb":{"default":1024,"type":"integer","minimum":16,"maximum":8192},"chatMessageMaxLength":{"default":2000,"type":"integer","minimum":1,"maximum":10000},"chatRatePerMinute":{"default":30,"type":"integer","minimum":1,"maximum":600},"maxGroupMembers":{"default":50,"type":"integer","minimum":2,"maximum":500},"maxGroupsPerUser":{"default":100,"type":"integer","minimum":1,"maximum":1000},"inviteTtlMinutes":{"default":60,"type":"integer","minimum":1,"maximum":10080},"invitesPerHour":{"default":60,"type":"integer","minimum":1,"maximum":1000}},"required":["registrationOpen","chatEnabled","sharingEnabled","hostingEnabled","invitesEnabled","motd","maxHostsPerUser","maxPlayersPerHost","hostAuthTtlSeconds","relayFailMode","maxFriends","maxPendingRequests","maxPacksPerUser","maxPackVersions","maxPackOverridesMb","maxManifestKb","chatMessageMaxLength","chatRatePerMinute","maxGroupMembers","maxGroupsPerUser","inviteTtlMinutes","invitesPerHour"],"additionalProperties":false}},"required":["settings","defaults"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]},"patch":{"summary":"Einstellungen ändern","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"registrationOpen":{"default":true,"type":"boolean"},"chatEnabled":{"default":true,"type":"boolean"},"sharingEnabled":{"default":true,"type":"boolean"},"hostingEnabled":{"default":true,"type":"boolean"},"invitesEnabled":{"default":true,"type":"boolean"},"motd":{"default":null,"nullable":true,"type":"string","maxLength":500},"maxHostsPerUser":{"default":2,"type":"integer","minimum":0,"maximum":50},"maxPlayersPerHost":{"default":null,"nullable":true,"type":"integer","minimum":1,"maximum":500},"hostAuthTtlSeconds":{"default":60,"type":"integer","minimum":0,"maximum":3600},"relayFailMode":{"default":"open","type":"string","enum":["open","closed"]},"maxFriends":{"default":500,"type":"integer","minimum":1,"maximum":5000},"maxPendingRequests":{"default":100,"type":"integer","minimum":1,"maximum":1000},"maxPacksPerUser":{"default":25,"type":"integer","minimum":0,"maximum":1000},"maxPackVersions":{"default":50,"type":"integer","minimum":1,"maximum":500},"maxPackOverridesMb":{"default":100,"type":"integer","minimum":1,"maximum":4096},"maxManifestKb":{"default":1024,"type":"integer","minimum":16,"maximum":8192},"chatMessageMaxLength":{"default":2000,"type":"integer","minimum":1,"maximum":10000},"chatRatePerMinute":{"default":30,"type":"integer","minimum":1,"maximum":600},"maxGroupMembers":{"default":50,"type":"integer","minimum":2,"maximum":500},"maxGroupsPerUser":{"default":100,"type":"integer","minimum":1,"maximum":1000},"inviteTtlMinutes":{"default":60,"type":"integer","minimum":1,"maximum":10080},"invitesPerHour":{"default":60,"type":"integer","minimum":1,"maximum":1000}},"required":["registrationOpen","chatEnabled","sharingEnabled","hostingEnabled","invitesEnabled","motd","maxHostsPerUser","maxPlayersPerHost","hostAuthTtlSeconds","relayFailMode","maxFriends","maxPendingRequests","maxPacksPerUser","maxPackVersions","maxPackOverridesMb","maxManifestKb","chatMessageMaxLength","chatRatePerMinute","maxGroupMembers","maxGroupsPerUser","inviteTtlMinutes","invitesPerHour"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"registrationOpen":{"type":"boolean"},"chatEnabled":{"type":"boolean"},"sharingEnabled":{"type":"boolean"},"hostingEnabled":{"type":"boolean"},"invitesEnabled":{"type":"boolean"},"motd":{"nullable":true,"type":"string","maxLength":500},"maxHostsPerUser":{"type":"integer","minimum":0,"maximum":50},"maxPlayersPerHost":{"nullable":true,"type":"integer","minimum":1,"maximum":500},"hostAuthTtlSeconds":{"type":"integer","minimum":0,"maximum":3600},"relayFailMode":{"type":"string","enum":["open","closed"]},"maxFriends":{"type":"integer","minimum":1,"maximum":5000},"maxPendingRequests":{"type":"integer","minimum":1,"maximum":1000},"maxPacksPerUser":{"type":"integer","minimum":0,"maximum":1000},"maxPackVersions":{"type":"integer","minimum":1,"maximum":500},"maxPackOverridesMb":{"type":"integer","minimum":1,"maximum":4096},"maxManifestKb":{"type":"integer","minimum":16,"maximum":8192},"chatMessageMaxLength":{"type":"integer","minimum":1,"maximum":10000},"chatRatePerMinute":{"type":"integer","minimum":1,"maximum":600},"maxGroupMembers":{"type":"integer","minimum":2,"maximum":500},"maxGroupsPerUser":{"type":"integer","minimum":1,"maximum":1000},"inviteTtlMinutes":{"type":"integer","minimum":1,"maximum":10080},"invitesPerHour":{"type":"integer","minimum":1,"maximum":1000}}}}}}}},"/admin/api/audit":{"get":{"summary":"Audit-Log","tags":["Admin"],"parameters":[{"name":"before","in":"query","required":false,"schema":{"type":"integer","minimum":0,"exclusiveMinimum":true,"maximum":9007199254740991}},{"name":"limit","in":"query","required":false,"schema":{"default":100,"type":"integer","minimum":1,"maximum":200}},{"name":"action","in":"query","required":false,"schema":{"type":"string","maxLength":64}},{"name":"targetId","in":"query","required":false,"schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"admin":{"nullable":true,"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"],"additionalProperties":false},"action":{"type":"string"},"targetType":{"nullable":true,"type":"string"},"targetId":{"nullable":true,"type":"string"},"data":{},"ip":{"nullable":true,"type":"string"},"createdAt":{"type":"string"}},"required":["id","admin","action","targetType","targetId","data","ip","createdAt"],"additionalProperties":false}},"hasMore":{"type":"boolean"}},"required":["entries","hasMore"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}},"/admin/api/admins":{"get":{"summary":"Admin-Konten","tags":["Admin"],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"},"role":{"type":"string","enum":["owner","admin","moderator"]},"totpEnabled":{"type":"boolean"},"disabled":{"type":"boolean"},"createdAt":{"type":"string"},"lastLoginAt":{"nullable":true,"type":"string"}},"required":["id","username","role","totpEnabled","disabled","createdAt","lastLoginAt"],"additionalProperties":false}}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]},"post":{"summary":"Admin anlegen","tags":["Admin"],"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"},"role":{"type":"string","enum":["owner","admin","moderator"]},"totpEnabled":{"type":"boolean"},"disabled":{"type":"boolean"},"createdAt":{"type":"string"},"lastLoginAt":{"nullable":true,"type":"string"}},"required":["id","username","role","totpEnabled","disabled","createdAt","lastLoginAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","minLength":3,"maxLength":64,"pattern":"^[A-Za-z0-9_.-]+$"},"password":{"type":"string","minLength":12,"maxLength":256},"role":{"type":"string","enum":["owner","admin","moderator"]}},"required":["username","password","role"]}}}}}},"/admin/api/admins/{id}":{"patch":{"summary":"Admin ändern (Rolle, sperren, Passwort, TOTP zurücksetzen)","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"},"role":{"type":"string","enum":["owner","admin","moderator"]},"totpEnabled":{"type":"boolean"},"disabled":{"type":"boolean"},"createdAt":{"type":"string"},"lastLoginAt":{"nullable":true,"type":"string"}},"required":["id","username","role","totpEnabled","disabled","createdAt","lastLoginAt"],"additionalProperties":false}}}},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"role":{"type":"string","enum":["owner","admin","moderator"]},"disabled":{"type":"boolean"},"password":{"type":"string","minLength":12,"maxLength":256},"resetTotp":{"type":"boolean"}}}}}}},"delete":{"summary":"Admin löschen","tags":["Admin"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":64}}],"responses":{"204":{"description":"OK"},"default":{"description":"Fehler","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"adminCookie":[]}]}}}}