Interface MethodProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
MethodProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:45.012Z")
@Stability(Stable)
public interface MethodProps
extends software.amazon.jsii.JsiiSerializable
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.apigateway.*;
Authorizer authorizer;
Integration integration;
Model model;
RequestValidator requestValidator;
Resource resource;
MethodProps methodProps = MethodProps.builder()
.httpMethod("httpMethod")
.resource(resource)
// the properties below are optional
.integration(integration)
.options(MethodOptions.builder()
.apiKeyRequired(false)
.authorizationScopes(List.of("authorizationScopes"))
.authorizationType(AuthorizationType.NONE)
.authorizer(authorizer)
.methodResponses(List.of(MethodResponse.builder()
.statusCode("statusCode")
// the properties below are optional
.responseModels(Map.of(
"responseModelsKey", model))
.responseParameters(Map.of(
"responseParametersKey", false))
.build()))
.operationName("operationName")
.requestModels(Map.of(
"requestModelsKey", model))
.requestParameters(Map.of(
"requestParametersKey", false))
.requestValidator(requestValidator)
.requestValidatorOptions(RequestValidatorOptions.builder()
.requestValidatorName("requestValidatorName")
.validateRequestBody(false)
.validateRequestParameters(false)
.build())
.build())
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forMethodPropsstatic final classAn implementation forMethodProps -
Method Summary
Modifier and TypeMethodDescriptionstatic MethodProps.Builderbuilder()The HTTP method ("GET", "POST", "PUT", ...) that clients use to call this method.default IntegrationThe backend system that the method calls when it receives a request.default MethodOptionsMethod options.The resource this method is associated with.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getHttpMethod
The HTTP method ("GET", "POST", "PUT", ...) that clients use to call this method. -
getResource
The resource this method is associated with.For root resource methods, specify the
RestApiobject. -
getIntegration
The backend system that the method calls when it receives a request.Default: - a new `MockIntegration`.
-
getOptions
Method options.Default: - No options.
-
builder
- Returns:
- a
MethodProps.BuilderofMethodProps
-