module Stratosphere.ResourceProperties.ApiGatewayMethodResponse where
import Control.Lens
import Data.Aeson
import Data.Aeson.Types
import Data.Text
import GHC.Generics
import Stratosphere.Values
data ApiGatewayMethodResponse =
ApiGatewayMethodResponse
{ _apiGatewayMethodResponseResponseModels :: Maybe Object
, _apiGatewayMethodResponseResponseParameters :: Maybe Object
, _apiGatewayMethodResponseStatusCode :: Val Text
} deriving (Show, Generic)
instance ToJSON ApiGatewayMethodResponse where
toJSON = genericToJSON defaultOptions { fieldLabelModifier = Prelude.drop 25, omitNothingFields = True }
instance FromJSON ApiGatewayMethodResponse where
parseJSON = genericParseJSON defaultOptions { fieldLabelModifier = Prelude.drop 25, omitNothingFields = True }
apiGatewayMethodResponse
:: Val Text
-> ApiGatewayMethodResponse
apiGatewayMethodResponse statusCodearg =
ApiGatewayMethodResponse
{ _apiGatewayMethodResponseResponseModels = Nothing
, _apiGatewayMethodResponseResponseParameters = Nothing
, _apiGatewayMethodResponseStatusCode = statusCodearg
}
agmrResponseModels :: Lens' ApiGatewayMethodResponse (Maybe Object)
agmrResponseModels = lens _apiGatewayMethodResponseResponseModels (\s a -> s { _apiGatewayMethodResponseResponseModels = a })
agmrResponseParameters :: Lens' ApiGatewayMethodResponse (Maybe Object)
agmrResponseParameters = lens _apiGatewayMethodResponseResponseParameters (\s a -> s { _apiGatewayMethodResponseResponseParameters = a })
agmrStatusCode :: Lens' ApiGatewayMethodResponse (Val Text)
agmrStatusCode = lens _apiGatewayMethodResponseStatusCode (\s a -> s { _apiGatewayMethodResponseStatusCode = a })