INNER CODE UNIT · Go

corsOptionsGatewayMethod

mweagle/Sparta · apigateway.go:166

func corsOptionsGatewayMethod(api *API, restAPIID string, resourceID string) *gofapig.Method {
	methodResponse := gofapig.Method_MethodResponse{
		StatusCode:         "200",
		ResponseParameters: corsMethodResponseParams(api),
	}

	integrationResponse := gofapig.Method_IntegrationResponse{
		ResponseTemplates: map[string]string{
			"application/*": "",
			"text/*":        "",
		},
		StatusCode:         "200",
		ResponseParameters: corsIntegrationResponseParams(api),
	}

	methodIntegrationIntegrationResponseList := []gofapig.Method_IntegrationResponse{}
	methodIntegrationIntegrationResponseList = append(methodIntegrationIntegrationResponseList,
		integrationResponse)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…