I defined a rest endpoint with multiple tenant
@RequestScoped
@Path("/api/v1/calendar/{tenant}")
public class CalendarEndpoint {
@Inject
CalendarRepository repository;
@POST
@Path("appointments")
@PermitAll
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
@Operation(summary = "Termine laden", description = "Lädt für einen bestimmten Zeitraum die Termine")
@APIResponses(value = {
@APIResponse(responseCode = "200", description = "Termine erfolgreich geladen", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ArrayList.class))),
@APIResponse(responseCode = "403", description = "Authentifizierung nicht erfolgreich", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ExceptionHandler.ErrorResponseBody.class))) })
public List<RWeek> getAppointments(RAppointmentDates dates) {
return repository.findByDateRange(dates);
}
}
How I can define the “tenant” Parameter in the Swagger UI? This parameter is not visible.
Swagger UI
A @PathParameter on the method definition has no effect.
New contributor
Demmtop is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.