Get this OpenAPI document
GET
/openapi.yaml
HttpRequest request = HttpRequest.newBuilder() .uri(URI.create("http://localhost:8080/openapi.yaml")) .method("GET", HttpRequest.BodyPublishers.noBody()) .build();HttpResponse<String> response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());System.out.println(response.body());const url = 'http://localhost:8080/openapi.yaml';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url http://localhost:8080/openapi.yamlResponses
Section titled “ Responses ”This OpenAPI document
Media typeapplication/yaml
string