{-# LANGUAGE DeriveGeneric #-}
{-|
Module      : Instana.SDK.Internal.AgentConnection.Json.AnnounceResponse
Description : Aeson type for the agent's announce response
-}
module Instana.SDK.Internal.AgentConnection.Json.AnnounceResponse
    ( AnnounceResponse(..)
    ) where


import           Data.Aeson                   (FromJSON)
import           Data.Text                    (Text)
import           GHC.Generics

import           Instana.SDK.Internal.Secrets (SecretsMatcher)


-- |Holds the agent's response to the announce request.
data AnnounceResponse = AnnounceResponse
  { AnnounceResponse -> Int
pid          :: Int
  , AnnounceResponse -> Text
agentUuid    :: Text
  , AnnounceResponse -> Maybe [Text]
extraHeaders :: Maybe [Text]
  , AnnounceResponse -> SecretsMatcher
secrets      :: SecretsMatcher
  } deriving (AnnounceResponse -> AnnounceResponse -> Bool
(AnnounceResponse -> AnnounceResponse -> Bool)
-> (AnnounceResponse -> AnnounceResponse -> Bool)
-> Eq AnnounceResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AnnounceResponse -> AnnounceResponse -> Bool
$c/= :: AnnounceResponse -> AnnounceResponse -> Bool
== :: AnnounceResponse -> AnnounceResponse -> Bool
$c== :: AnnounceResponse -> AnnounceResponse -> Bool
Eq, Int -> AnnounceResponse -> ShowS
[AnnounceResponse] -> ShowS
AnnounceResponse -> String
(Int -> AnnounceResponse -> ShowS)
-> (AnnounceResponse -> String)
-> ([AnnounceResponse] -> ShowS)
-> Show AnnounceResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AnnounceResponse] -> ShowS
$cshowList :: [AnnounceResponse] -> ShowS
show :: AnnounceResponse -> String
$cshow :: AnnounceResponse -> String
showsPrec :: Int -> AnnounceResponse -> ShowS
$cshowsPrec :: Int -> AnnounceResponse -> ShowS
Show, (forall x. AnnounceResponse -> Rep AnnounceResponse x)
-> (forall x. Rep AnnounceResponse x -> AnnounceResponse)
-> Generic AnnounceResponse
forall x. Rep AnnounceResponse x -> AnnounceResponse
forall x. AnnounceResponse -> Rep AnnounceResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AnnounceResponse x -> AnnounceResponse
$cfrom :: forall x. AnnounceResponse -> Rep AnnounceResponse x
Generic)

instance FromJSON AnnounceResponse