Add nickname retrieval support: implemented NicknameMapper for database queries, updated ChatService to return player names with optional nicknames, and extended /chat/player/{uuid}/name API endpoint.
This commit is contained in:
@@ -45,8 +45,40 @@ paths:
|
||||
responses:
|
||||
"202":
|
||||
description: Accepted
|
||||
|
||||
/chat/player/{uuid}/name:
|
||||
get:
|
||||
tags:
|
||||
- chat
|
||||
summary: Gets the name, and nickname of the player associated with that uuid
|
||||
operationId: getName
|
||||
parameters:
|
||||
- name: uuid
|
||||
in: path
|
||||
required: true
|
||||
schema:
|
||||
type: string
|
||||
format: uuid
|
||||
responses:
|
||||
"200":
|
||||
description: The player's name and nickname
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/PlayerName"
|
||||
"404":
|
||||
description: Player not found
|
||||
components:
|
||||
schemas:
|
||||
PlayerName:
|
||||
type: object
|
||||
required:
|
||||
- name
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
nickname:
|
||||
type: string
|
||||
User:
|
||||
type: object
|
||||
required:
|
||||
|
||||
Reference in New Issue
Block a user