atlas-cardano-0.6.3: Application backend for Plutus smart contracts on Cardano
Copyright(c) 2023 GYELD GMBH
LicenseApache 2.0
Maintainer[email protected]
Stabilitydevelop
Safe HaskellSafe-Inferred
LanguageGHC2021

GeniusYield.Types.StakeKeyHash

Description

 
Synopsis

Documentation

data GYStakeKeyHash #

Instances

Instances details
FromJSON GYStakeKeyHash #
>>> Aeson.eitherDecode @GYStakeKeyHash "\"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d\""
Right (GYStakeKeyHash "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d")

Invalid characters:

>>> Aeson.eitherDecode @GYStakeKeyHash "\"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab2340386323zzz\""
Left "Error in $: RawBytesHexErrorBase16DecodeFail \"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab2340386323zzz\" \"invalid character at offset: 53\""
Instance details

Defined in GeniusYield.Types.StakeKeyHash

ToJSON GYStakeKeyHash #
>>> let Just skh = Aeson.decode @GYStakeKeyHash "\"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d\""
>>> LBS8.putStrLn $ Aeson.encode skh
"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
Instance details

Defined in GeniusYield.Types.StakeKeyHash

AsPubKeyHash GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

CanSignTx GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

IsString GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

Show GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

PrintfArg GYStakeKeyHash #
>>> Printf.printf "%s\n" $ stakeKeyHashFromApi "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d
Instance details

Defined in GeniusYield.Types.StakeKeyHash

FromField GYStakeKeyHash #
>>> Csv.runParser $ Csv.parseField @GYStakeKeyHash "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
Right (GYStakeKeyHash "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d")
>>> Csv.runParser $ Csv.parseField @GYStakeKeyHash "not a pub stake key hash"
Left "RawBytesHexErrorBase16DecodeFail \"not a pub stake key hash\" \"invalid character at offset: 0\""
Instance details

Defined in GeniusYield.Types.StakeKeyHash

ToField GYStakeKeyHash #
>>> Csv.toField @GYStakeKeyHash "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
Instance details

Defined in GeniusYield.Types.StakeKeyHash

Methods

toFieldGYStakeKeyHashField #

Eq GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

Ord GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

ToSchema GYStakeKeyHash # 
Instance details

Defined in GeniusYield.Types.StakeKeyHash

stakeKeyHashToApiGYStakeKeyHashHash StakeKey #

>>> let Just skh = Aeson.decode @GYStakeKeyHash "\"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d\""
>>> stakeKeyHashToApi skh
"7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"

stakeKeyHashFromApiHash StakeKeyGYStakeKeyHash #

>>> stakeKeyHashFromApi "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"
GYStakeKeyHash "7a77d120b9e86addc7388dbbb1bd2350490b7d140ab234038632334d"

stakeKeyHashToLedgerGYStakeKeyHashKeyHash Staking StandardCrypto #

Convert to corresponding ledger type.

stakeKeyHashFromLedgerKeyHash Staking StandardCryptoGYStakeKeyHash #

Convert from corresponding ledger type.