web3-0.9.0.0: Web3 API for Haskell.

CopyrightAlexander Krupenkin 2016
LicenseBSD3
Maintainermail@akru.me
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Network.Polkadot.Api.Types

Description

Polkadot JSON-RPC types.

Synopsis

Documentation

data NodeRole Source #

The role the node is running as.

Constructors

Full 
LightClient 
Authority 
Sentry 
Instances
Eq NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep NodeRole :: Type -> Type #

Methods

from :: NodeRole -> Rep NodeRole x #

to :: Rep NodeRole x -> NodeRole #

ToJSON NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep NodeRole Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep NodeRole = D1 (MetaData "NodeRole" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) ((C1 (MetaCons "Full" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "LightClient" PrefixI False) (U1 :: Type -> Type)) :+: (C1 (MetaCons "Authority" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "Sentry" PrefixI False) (U1 :: Type -> Type)))

data ChainType Source #

Type op a chain.

Constructors

Development 
Local 
Live 
Custom Text 
Instances
Eq ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep ChainType :: Type -> Type #

ToJSON ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ChainType Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ChainType = D1 (MetaData "ChainType" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) ((C1 (MetaCons "Development" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "Local" PrefixI False) (U1 :: Type -> Type)) :+: (C1 (MetaCons "Live" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "Custom" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text))))

data Health Source #

System health struct returned by the RPC

Constructors

Health 

Fields

Instances
Eq Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Methods

(==) :: Health -> Health -> Bool #

(/=) :: Health -> Health -> Bool #

Show Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep Health :: Type -> Type #

Methods

from :: Health -> Rep Health x #

to :: Rep Health x -> Health #

ToJSON Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep Health Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep Health = D1 (MetaData "Health" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "Health" PrefixI True) (S1 (MetaSel (Just "healthPeers") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int) :*: (S1 (MetaSel (Just "healthIsSyncing") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: S1 (MetaSel (Just "healthShouldHavePeers") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool))))

data PeerInfo Source #

Network Peer information.

Constructors

PeerInfo 

Fields

Instances
Eq PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep PeerInfo :: Type -> Type #

Methods

from :: PeerInfo -> Rep PeerInfo x #

to :: Rep PeerInfo x -> PeerInfo #

ToJSON PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep PeerInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep PeerInfo = D1 (MetaData "PeerInfo" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "PeerInfo" PrefixI True) ((S1 (MetaSel (Just "peerInfoPeerId") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: S1 (MetaSel (Just "peerInfoRoles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [NodeRole])) :*: (S1 (MetaSel (Just "peerInfoProtocolVersion") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int) :*: (S1 (MetaSel (Just "peerInfoBestHash") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: S1 (MetaSel (Just "peerInfoBestNumber") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int)))))

data ContractCall Source #

Executes a call to a contract.

Instances
Eq ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep ContractCall :: Type -> Type #

ToJSON ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ContractCall Source # 
Instance details

Defined in Network.Polkadot.Api.Types

data ContractExecResult Source #

A result of execution of a contract.

Constructors

SuccessExec 

Fields

ExecResultError 
Instances
Eq ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep ContractExecResult :: Type -> Type #

ToJSON ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ContractExecResult Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ContractExecResult = D1 (MetaData "ContractExecResult" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "SuccessExec" PrefixI True) (S1 (MetaSel (Just "execStatus") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Word8) :*: S1 (MetaSel (Just "execData") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe HexString))) :+: C1 (MetaCons "ExecResultError" PrefixI False) (U1 :: Type -> Type))

data ReadProof Source #

ReadProof struct returned by RPC.

Constructors

ReadProof 

Fields

Instances
Eq ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep ReadProof :: Type -> Type #

ToJSON ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ReadProof Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ReadProof = D1 (MetaData "ReadProof" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "ReadProof" PrefixI True) (S1 (MetaSel (Just "readProofAt") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 HexString) :*: S1 (MetaSel (Just "readProofProof") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [HexString])))

data RuntimeVersion Source #

Runtime version. This should not be thought of as classic Semver (majorminortiny). This triplet have different semantics and mis-interpretation could cause problems. In particular: bug fixes should result in an increment of spec_version and possibly authoring_version, absolutely not impl_version since they change the semantics of the runtime.

Constructors

RuntimeVersion 

Fields

Instances
Eq RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep RuntimeVersion :: Type -> Type #

ToJSON RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep RuntimeVersion Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep RuntimeVersion = D1 (MetaData "RuntimeVersion" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "RuntimeVersion" PrefixI True) ((S1 (MetaSel (Just "runtimeSpecName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: (S1 (MetaSel (Just "runtimeImplName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: S1 (MetaSel (Just "runtimeAuthoringVersion") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Word32))) :*: ((S1 (MetaSel (Just "runtimeSpecVersion") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Word32) :*: S1 (MetaSel (Just "runtimeImplVersion") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Word32)) :*: (S1 (MetaSel (Just "runtimeApis") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(HexString, Word32)]) :*: S1 (MetaSel (Just "runtimeTransactionVersion") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Word32)))))

type StorageKind = Word8 Source #

Type of supported offchain storages.

1: persistent storage is non-revertible and not fork-aware; 2: local storage is revertible and fork-aware.

type Weight = Word64 Source #

Numeric range of transaction weight.

data DispatchClass Source #

Generalized group of dispatch types.

Constructors

Normal 
Operational 
Mandatory 
Instances
Eq DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep DispatchClass :: Type -> Type #

ToJSON DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep DispatchClass Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep DispatchClass = D1 (MetaData "DispatchClass" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "Normal" PrefixI False) (U1 :: Type -> Type) :+: (C1 (MetaCons "Operational" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "Mandatory" PrefixI False) (U1 :: Type -> Type)))

data RuntimeDispatchInfo Source #

Some information related to a dispatchable that can be queried from the runtime.

Constructors

RuntimeDispatchInfo 

Fields

Instances
Eq RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep RuntimeDispatchInfo :: Type -> Type #

ToJSON RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep RuntimeDispatchInfo Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep RuntimeDispatchInfo = D1 (MetaData "RuntimeDispatchInfo" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "RuntimeDispatchInfo" PrefixI True) (S1 (MetaSel (Just "dispatchWeight") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Weight) :*: (S1 (MetaSel (Just "dispatchClass") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 DispatchClass) :*: S1 (MetaSel (Just "dispatchPartialFee") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Integer))))

data ImportedAux Source #

Auxiliary data associated with an imported block result.

Constructors

ImportedAux 

Fields

Instances
Eq ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep ImportedAux :: Type -> Type #

ToJSON ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ImportedAux Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep ImportedAux = D1 (MetaData "ImportedAux" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "ImportedAux" PrefixI True) ((S1 (MetaSel (Just "auxHeaderOnly") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: (S1 (MetaSel (Just "auxClearJustificationRequests") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: S1 (MetaSel (Just "auxNeedsJustification") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool))) :*: (S1 (MetaSel (Just "auxBadJustification") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: (S1 (MetaSel (Just "auxNeedsFinalityProof") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: S1 (MetaSel (Just "auxIsNewBest") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool)))))

data CreatedBlock Source #

Instances
Eq CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep CreatedBlock :: Type -> Type #

ToJSON CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep CreatedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep CreatedBlock = D1 (MetaData "CreatedBlock" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "CreatedBlock" PrefixI True) (S1 (MetaSel (Just "createdBlockHash") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 HexString) :*: S1 (MetaSel (Just "createdBlockAux") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ImportedAux)))

data Header Source #

Abstraction over a block header for a substrate chain.

Constructors

Header 

Fields

Instances
Eq Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Methods

(==) :: Header -> Header -> Bool #

(/=) :: Header -> Header -> Bool #

Show Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep Header :: Type -> Type #

Methods

from :: Header -> Rep Header x #

to :: Rep Header x -> Header #

ToJSON Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep Header Source # 
Instance details

Defined in Network.Polkadot.Api.Types

data Block Source #

Abstraction over a substrate block.

Constructors

Block 

Fields

Instances
Eq Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Methods

(==) :: Block -> Block -> Bool #

(/=) :: Block -> Block -> Bool #

Show Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Methods

showsPrec :: Int -> Block -> ShowS #

show :: Block -> String #

showList :: [Block] -> ShowS #

Generic Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep Block :: Type -> Type #

Methods

from :: Block -> Rep Block x #

to :: Rep Block x -> Block #

ToJSON Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep Block Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep Block = D1 (MetaData "Block" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "Block" PrefixI True) (S1 (MetaSel (Just "blockHeader") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Header) :*: S1 (MetaSel (Just "blockExtrinsics") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [HexString])))

data SignedBlock Source #

Abstraction over a substrate block and justification.

Constructors

SignedBlock 

Fields

Instances
Eq SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Show SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Generic SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

Associated Types

type Rep SignedBlock :: Type -> Type #

ToJSON SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

FromJSON SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep SignedBlock Source # 
Instance details

Defined in Network.Polkadot.Api.Types

type Rep SignedBlock = D1 (MetaData "SignedBlock" "Network.Polkadot.Api.Types" "web3-0.9.0.0-6wv3rkKFlHwFfHKZvDcYhG" False) (C1 (MetaCons "SignedBlock" PrefixI True) (S1 (MetaSel (Just "signedBlock") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Block) :*: S1 (MetaSel (Just "signedJustification") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe HexString))))