Safe Haskell | None |
---|---|
Language | Haskell2010 |
Network.Tendermint.Client
Contents
Synopsis
- data SignedMsgType
- type Tx = Base64String
- data Vote = Vote {}
- data Commit = Commit {
- commitBlockId :: BlockID
- commitPrecommits :: [Vote]
- type EvidenceList = WrappedVal [Evidence]
- data EvidenceData = EvidenceData {}
- data Data = Data {
- dataTxs :: WrappedVal [Tx]
- data Block = Block {}
- data BlockMeta = BlockMeta {}
- data SimpleProof = SimpleProof {}
- data TxProof = TxProof {}
- data ResultBroadcastTx = ResultBroadcastTx {}
- data ResultABCIInfo = ResultABCIInfo {}
- data ResultHealth = ResultHealth
- data ResultBroadcastTxCommit = ResultBroadcastTxCommit {}
- data RequestBroadcastTxCommit = RequestBroadcastTxCommit {}
- data RequestBroadcastTxSync = RequestBroadcastTxSync {}
- data RequestBroadcastTxAsync = RequestBroadcastTxAsync {}
- data ResultTx = ResultTx {}
- data RequestTx = RequestTx {}
- data ResultBlock = ResultBlock {}
- data RequestBlock = RequestBlock {}
- data ResultABCIQuery = ResultABCIQuery {}
- data RequestABCIQuery = RequestABCIQuery {}
- type TendermintM = ReaderT Config IO
- runTendermintM :: Config -> TendermintM a -> IO a
- defaultConfig :: ByteString -> Int -> Config
- abciQuery :: RequestABCIQuery -> TendermintM ResultABCIQuery
- block :: RequestBlock -> TendermintM ResultBlock
- tx :: RequestTx -> TendermintM ResultTx
- broadcastTxAsync :: RequestBroadcastTxAsync -> TendermintM ResultBroadcastTx
- broadcastTxSync :: RequestBroadcastTxSync -> TendermintM ResultBroadcastTx
- broadcastTxCommit :: RequestBroadcastTxCommit -> TendermintM ResultBroadcastTxCommit
- health :: TendermintM ResultHealth
- abciInfo :: TendermintM ResultABCIInfo
- defaultRPCOptions :: String -> Options
- data Config = Config {
- cBaseHTTPRequest :: Request
- withRequest :: Request -> IO ()
- withResponse :: Response -> IO ()
- data JsonRpcException
- data RpcError = RpcError {
- errCode :: !Int
- errMessage :: !Text
- errData :: !(Maybe Value)
Documentation
data SignedMsgType Source #
Constructors
PrevoteType | |
PrecommitType | |
ProposalType |
Instances
Eq SignedMsgType Source # | |
Defined in Network.Tendermint.Client Methods (==) :: SignedMsgType -> SignedMsgType -> Bool # (/=) :: SignedMsgType -> SignedMsgType -> Bool # | |
Show SignedMsgType Source # | |
Defined in Network.Tendermint.Client Methods showsPrec :: Int -> SignedMsgType -> ShowS # show :: SignedMsgType -> String # showList :: [SignedMsgType] -> ShowS # | |
Generic SignedMsgType Source # | |
Defined in Network.Tendermint.Client Associated Types type Rep SignedMsgType :: Type -> Type # | |
FromJSON SignedMsgType Source # | |
Defined in Network.Tendermint.Client | |
type Rep SignedMsgType Source # | |
Defined in Network.Tendermint.Client type Rep SignedMsgType = D1 (MetaData "SignedMsgType" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "PrevoteType" PrefixI False) (U1 :: Type -> Type) :+: (C1 (MetaCons "PrecommitType" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "ProposalType" PrefixI False) (U1 :: Type -> Type))) |
type Tx = Base64String Source #
Constructors
Vote | |
Fields |
Instances
Constructors
Commit | |
Fields
|
Instances
Eq Commit Source # | |
Show Commit Source # | |
Generic Commit Source # | |
FromJSON Commit Source # | |
Defined in Network.Tendermint.Client | |
type Rep Commit Source # | |
Defined in Network.Tendermint.Client type Rep Commit = D1 (MetaData "Commit" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "Commit" PrefixI True) (S1 (MetaSel (Just "commitBlockId") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 BlockID) :*: S1 (MetaSel (Just "commitPrecommits") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Vote]))) |
type EvidenceList = WrappedVal [Evidence] Source #
data EvidenceData Source #
Constructors
EvidenceData | |
Fields |
Instances
Eq EvidenceData Source # | |
Defined in Network.Tendermint.Client | |
Show EvidenceData Source # | |
Defined in Network.Tendermint.Client Methods showsPrec :: Int -> EvidenceData -> ShowS # show :: EvidenceData -> String # showList :: [EvidenceData] -> ShowS # | |
Generic EvidenceData Source # | |
Defined in Network.Tendermint.Client Associated Types type Rep EvidenceData :: Type -> Type # | |
FromJSON EvidenceData Source # | |
Defined in Network.Tendermint.Client | |
type Rep EvidenceData Source # | |
Defined in Network.Tendermint.Client type Rep EvidenceData = D1 (MetaData "EvidenceData" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "EvidenceData" PrefixI True) (S1 (MetaSel (Just "evidenceDataEvidence") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 EvidenceList))) |
Constructors
Data | |
Fields
|
Instances
Eq Data Source # | |
Show Data Source # | |
Generic Data Source # | |
FromJSON Data Source # | |
Defined in Network.Tendermint.Client | |
type Rep Data Source # | |
Defined in Network.Tendermint.Client type Rep Data = D1 (MetaData "Data" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "Data" PrefixI True) (S1 (MetaSel (Just "dataTxs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (WrappedVal [Tx])))) |
Constructors
Block | |
Fields |
Instances
Eq Block Source # | |
Show Block Source # | |
Generic Block Source # | |
FromJSON Block Source # | |
Defined in Network.Tendermint.Client | |
type Rep Block Source # | |
Defined in Network.Tendermint.Client type Rep Block = D1 (MetaData "Block" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "Block" PrefixI True) ((S1 (MetaSel (Just "blockHeader") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Header) :*: S1 (MetaSel (Just "blockData") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Data)) :*: (S1 (MetaSel (Just "blockEvidence") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 EvidenceData) :*: S1 (MetaSel (Just "blockLastCommit") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Commit))))) |
Constructors
BlockMeta | |
Fields |
Instances
Eq BlockMeta Source # | |
Show BlockMeta Source # | |
Generic BlockMeta Source # | |
FromJSON BlockMeta Source # | |
Defined in Network.Tendermint.Client | |
type Rep BlockMeta Source # | |
Defined in Network.Tendermint.Client type Rep BlockMeta = D1 (MetaData "BlockMeta" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "BlockMeta" PrefixI True) (S1 (MetaSel (Just "blockMetaBlockId") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 BlockID) :*: S1 (MetaSel (Just "blockMetaHeader") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Header))) |
data SimpleProof Source #
Constructors
SimpleProof | |
Fields |
Instances
Constructors
TxProof | |
Fields |
Instances
Eq TxProof Source # | |
Show TxProof Source # | |
Generic TxProof Source # | |
FromJSON TxProof Source # | |
Defined in Network.Tendermint.Client | |
type Rep TxProof Source # | |
Defined in Network.Tendermint.Client type Rep TxProof = D1 (MetaData "TxProof" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "TxProof" PrefixI True) (S1 (MetaSel (Just "txProofRootHash") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 HexString) :*: (S1 (MetaSel (Just "txProofData") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Tx) :*: S1 (MetaSel (Just "txProofProof") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 SimpleProof)))) |
data ResultBroadcastTx Source #
Constructors
ResultBroadcastTx | |
Fields |
Instances
data ResultABCIInfo Source #
Constructors
ResultABCIInfo | |
Fields |
Instances
data ResultHealth Source #
Constructors
ResultHealth |
Instances
Eq ResultHealth Source # | |
Defined in Network.Tendermint.Client | |
Show ResultHealth Source # | |
Defined in Network.Tendermint.Client Methods showsPrec :: Int -> ResultHealth -> ShowS # show :: ResultHealth -> String # showList :: [ResultHealth] -> ShowS # | |
FromJSON ResultHealth Source # | |
Defined in Network.Tendermint.Client |
data ResultBroadcastTxCommit Source #
Constructors
ResultBroadcastTxCommit | |
Instances
data RequestBroadcastTxCommit Source #
Constructors
RequestBroadcastTxCommit | |
Fields |
Instances
data RequestBroadcastTxSync Source #
Constructors
RequestBroadcastTxSync | |
Fields |
Instances
data RequestBroadcastTxAsync Source #
Constructors
RequestBroadcastTxAsync | |
Fields |
Instances
Constructors
ResultTx | |
Fields |
Instances
Constructors
RequestTx | |
Fields
|
Instances
Eq RequestTx Source # | |
Show RequestTx Source # | |
Generic RequestTx Source # | |
ToJSON RequestTx Source # | |
Defined in Network.Tendermint.Client Methods toEncoding :: RequestTx -> Encoding toJSONList :: [RequestTx] -> Value toEncodingList :: [RequestTx] -> Encoding | |
Default RequestTx Source # | |
Defined in Network.Tendermint.Client | |
type Rep RequestTx Source # | |
Defined in Network.Tendermint.Client type Rep RequestTx = D1 (MetaData "RequestTx" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "RequestTx" PrefixI True) (S1 (MetaSel (Just "requestTxHash") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Tx)) :*: S1 (MetaSel (Just "requestTxProve") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool))) |
data ResultBlock Source #
Constructors
ResultBlock | |
Fields |
Instances
Eq ResultBlock Source # | |
Defined in Network.Tendermint.Client | |
Show ResultBlock Source # | |
Defined in Network.Tendermint.Client Methods showsPrec :: Int -> ResultBlock -> ShowS # show :: ResultBlock -> String # showList :: [ResultBlock] -> ShowS # | |
Generic ResultBlock Source # | |
Defined in Network.Tendermint.Client Associated Types type Rep ResultBlock :: Type -> Type # | |
FromJSON ResultBlock Source # | |
Defined in Network.Tendermint.Client | |
type Rep ResultBlock Source # | |
Defined in Network.Tendermint.Client type Rep ResultBlock = D1 (MetaData "ResultBlock" "Network.Tendermint.Client" "hs-tendermint-client-0.1.0.0-AEFlZ8KDMlW8Spav1uWoBK" False) (C1 (MetaCons "ResultBlock" PrefixI True) (S1 (MetaSel (Just "resultBlockBlockMeta") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 BlockMeta) :*: S1 (MetaSel (Just "resultBlockBlock") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Block))) |
data RequestBlock Source #
Constructors
RequestBlock | |
Fields |
Instances
data ResultABCIQuery Source #
Constructors
ResultABCIQuery | |
Fields |
Instances
data RequestABCIQuery Source #
Constructors
RequestABCIQuery | |
Fields |
Instances
runTendermintM :: Config -> TendermintM a -> IO a Source #
Execute an RPC request with the given configuration.
Arguments
:: ByteString | Hostname or IP (e.g. "localhost", "127.0.0.1", "151.101.208.68") |
-> Int | Port |
-> Config |
defaultRPCOptions :: String -> Options Source #
ReExports
JSON-RPC client config
Constructors
Config | |
Fields
|
data JsonRpcException Source #
Constructors
ParsingException String | |
CallException RpcError |
Instances
Eq JsonRpcException Source # | |
Defined in Network.Tendermint.Client.Internal.RPCClient Methods (==) :: JsonRpcException -> JsonRpcException -> Bool # (/=) :: JsonRpcException -> JsonRpcException -> Bool # | |
Show JsonRpcException Source # | |
Defined in Network.Tendermint.Client.Internal.RPCClient Methods showsPrec :: Int -> JsonRpcException -> ShowS # show :: JsonRpcException -> String # showList :: [JsonRpcException] -> ShowS # | |
Exception JsonRpcException Source # | |
Defined in Network.Tendermint.Client.Internal.RPCClient Methods toException :: JsonRpcException -> SomeException # |
JSON-RPC error message
Instances
Eq RpcError Source # | |
Show RpcError Source # | |
FromJSON RpcError Source # | |
Defined in Network.Tendermint.Client.Internal.RPCClient | |
ToJSON RpcError Source # | |
Defined in Network.Tendermint.Client.Internal.RPCClient Methods toEncoding :: RpcError -> Encoding toJSONList :: [RpcError] -> Value toEncodingList :: [RpcError] -> Encoding |