Add participant creation functionality to event API, including backend service and database integration. Update frontend to support participant registration and enhance UI for displaying registered players.
This commit is contained in:
@@ -195,6 +195,43 @@ paths:
|
||||
type: array
|
||||
items:
|
||||
$ref: "#/components/schemas/EventRegistration"
|
||||
/api/events/{eventId}/participants:
|
||||
post:
|
||||
tags: [Events]
|
||||
operationId: createGuestParticipant
|
||||
parameters:
|
||||
- $ref: "#/components/parameters/EventId"
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
required: [displayName, ratings, status]
|
||||
properties:
|
||||
displayName:
|
||||
type: string
|
||||
minLength: 1
|
||||
ratings:
|
||||
$ref: "#/components/schemas/Ratings"
|
||||
status:
|
||||
type: string
|
||||
enum: [Going, Maybe, NotGoing]
|
||||
responses:
|
||||
"201":
|
||||
description: Guest participant created and registered
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
required: [player, rsvp]
|
||||
properties:
|
||||
player:
|
||||
$ref: "#/components/schemas/Player"
|
||||
rsvp:
|
||||
$ref: "#/components/schemas/EventRegistration"
|
||||
"403":
|
||||
$ref: "#/components/responses/Forbidden"
|
||||
/api/events/{eventId}/rsvps/{playerId}:
|
||||
put:
|
||||
tags: [Events]
|
||||
|
||||
Reference in New Issue
Block a user