module Network.AWS.OpsWorks.DescribeMyUserProfile
(
DescribeMyUserProfile
, describeMyUserProfile
, DescribeMyUserProfileResponse
, describeMyUserProfileResponse
, dmuprUserProfile
) where
import Network.AWS.Prelude
import Network.AWS.Request.JSON
import Network.AWS.OpsWorks.Types
import qualified GHC.Exts
data DescribeMyUserProfile = DescribeMyUserProfile
deriving (Eq, Ord, Show, Generic)
describeMyUserProfile :: DescribeMyUserProfile
describeMyUserProfile = DescribeMyUserProfile
newtype DescribeMyUserProfileResponse = DescribeMyUserProfileResponse
{ _dmuprUserProfile :: Maybe SelfUserProfile
} deriving (Eq, Show)
describeMyUserProfileResponse :: DescribeMyUserProfileResponse
describeMyUserProfileResponse = DescribeMyUserProfileResponse
{ _dmuprUserProfile = Nothing
}
dmuprUserProfile :: Lens' DescribeMyUserProfileResponse (Maybe SelfUserProfile)
dmuprUserProfile = lens _dmuprUserProfile (\s a -> s { _dmuprUserProfile = a })
instance ToPath DescribeMyUserProfile where
toPath = const "/"
instance ToQuery DescribeMyUserProfile where
toQuery = const mempty
instance ToHeaders DescribeMyUserProfile
instance ToJSON DescribeMyUserProfile where
toJSON = const (toJSON Empty)
instance AWSRequest DescribeMyUserProfile where
type Sv DescribeMyUserProfile = OpsWorks
type Rs DescribeMyUserProfile = DescribeMyUserProfileResponse
request = post "DescribeMyUserProfile"
response = jsonResponse
instance FromJSON DescribeMyUserProfileResponse where
parseJSON = withObject "DescribeMyUserProfileResponse" $ \o -> DescribeMyUserProfileResponse
<$> o .:? "UserProfile"