public CreateRouteRequest withApiKeyRequired(Boolean apiKeyRequired) {
        setApiKeyRequired(apiKeyRequired);
        return this;
    }
<p>
Specifies whether an API key is required for the route. Supported only for WebSocket APIs.
</p>

@param apiKeyRequired
       Specifies whether an API key is required for the route. Supported only for WebSocket APIs.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-apigatewayv2/src/main/java/com/amazonaws/services/apigatewayv2/model/CreateRouteRequest.java