package gov.usgs.cida.wqp.springinit;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import io.swagger.v3.oas.models.Components;
import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;

@Configuration
public class OpenApiConfig {

	@Bean
	public OpenAPI customOpenAPI() {
		return new OpenAPI()
				.components(new Components())
				.info(new Info().title("Water Quality Portal Data API").description(
						"Documentation for the Water Quality Portal Data Download API"));

	}

}

@@ -32,16 +32,79 @@
 ginit;%0A%0A
+import org.springframework.beans.factory.annotation.Autowired;%0A
 import o
@@ -209,16 +209,71 @@
 ation;%0A%0A
+import gov.usgs.cida.wqp.service.ConfigurationService;%0A
 import i
@@ -396,116 +396,296 @@
 fo;%0A
-%0A@Configuration%0Apublic class OpenApiConfig %7B%0A%0A%09@Bean%0A%09public OpenAPI customOpenAPI() %7B%0A%09%09return new OpenAPI(
+import io.swagger.v3.oas.models.servers.Server;%0A%0A@Configuration%0Apublic class OpenApiConfig %7B%0A%0A%09@Autowired%0A%09ConfigurationService configurationService;%0A%0A%09@Bean%0A%09public OpenAPI customOpenAPI() %7B%0A%09%09return new OpenAPI()%0A%09%09%09%09.addServersItem(new Server().url(configurationService.getMyUrlBase())
 )%0A%09%09

Fix openapi server