Copyright | (c) 2023 GYELD GMBH |
---|---|
License | Apache 2.0 |
Maintainer | support@geniusyield.co |
Stability | develop |
Safe Haskell | None |
Language | GHC2021 |
GeniusYield.Types.TxBody
Description
Synopsis
- data GYTxBody
- txBodyFromApi :: TxBody ApiEra -> GYTxBody
- txBodyToApi :: GYTxBody -> TxBody ApiEra
- signGYTxBody :: ToShelleyWitnessSigningKey a => GYTxBody -> [a] -> GYTx
- signGYTxBody' :: GYTxBody -> [GYSomeSigningKey] -> GYTx
- signTx :: ToShelleyWitnessSigningKey a => GYTxBody -> [a] -> GYTx
- unsignedTx :: GYTxBody -> GYTx
- makeSignedTransaction :: GYTxWitness -> GYTxBody -> GYTx
- makeSignedTransaction' :: [KeyWitness ApiEra] -> TxBody ApiEra -> GYTx
- appendWitnessGYTx :: GYTxWitness -> GYTx -> GYTx
- signGYTx :: ToShelleyWitnessSigningKey a => GYTx -> [a] -> GYTx
- signGYTx' :: GYTx -> [GYSomeSigningKey] -> GYTx
- txBodyFromHex :: String -> Maybe GYTxBody
- txBodyFromHexBS :: ByteString -> Either String GYTxBody
- txBodyFromCBOR :: ByteString -> Either String GYTxBody
- txBodyToHex :: GYTxBody -> String
- txBodyToHexBS :: GYTxBody -> ByteString
- txBodyFee :: GYTxBody -> Integer
- txBodyFeeValue :: GYTxBody -> GYValue
- txBodyUTxOs :: GYTxBody -> GYUTxOs
- txBodyUTxOsWithDatums :: GYTxBody -> [(GYUTxO, Maybe GYDatum)]
- txBodyTxIns :: GYTxBody -> [GYTxOutRef]
- txBodyTxInsReference :: GYTxBody -> [GYTxOutRef]
- txBodyTxId :: GYTxBody -> GYTxId
- txBodyToApiTxBodyContent :: GYTxBody -> TxBodyContent ViewTx ApiEra
- txBodyReqSignatories :: GYTxBody -> Set GYPubKeyHash
- txBodyMintValue :: GYTxBody -> GYValue
- txBodyValidityRange :: GYTxBody -> (Maybe GYSlot, Maybe GYSlot)
- txBodyCollateral :: GYTxBody -> Set GYTxOutRef
- txBodyCollateralReturnOutput :: GYTxBody -> TxReturnCollateral CtxTx ApiEra
- txBodyCollateralReturnOutputValue :: GYTxBody -> GYValue
- txBodyTotalCollateralLovelace :: GYTxBody -> Natural
- getTxBody :: GYTx -> GYTxBody
Transaction body
Transaction body: the part which is then signed.
Instances
Conversions
txBodyFromApi :: TxBody ApiEra -> GYTxBody #
txBodyToApi :: GYTxBody -> TxBody ApiEra #
Transaction creation
signGYTxBody :: ToShelleyWitnessSigningKey a => GYTxBody -> [a] -> GYTx #
Sign a transaction body with (potentially) multiple keys.
signGYTxBody' :: GYTxBody -> [GYSomeSigningKey] -> GYTx #
Sign a transaction body with (potentially) multiple keys of potentially different nature.
signTx :: ToShelleyWitnessSigningKey a => GYTxBody -> [a] -> GYTx #
Deprecated: Use signGYTxBody.
unsignedTx :: GYTxBody -> GYTx #
Create an unsigned transaction from the body.
makeSignedTransaction :: GYTxWitness -> GYTxBody -> GYTx #
Make a signed transaction given the transaction body & list of key witnesses, represented in GYTxWitness
.
makeSignedTransaction' :: [KeyWitness ApiEra] -> TxBody ApiEra -> GYTx #
Make a signed transaction given the transaction body & list of key witnesses.
appendWitnessGYTx :: GYTxWitness -> GYTx -> GYTx #
Add a key witness(s) to a transaction, represented in GYTxWitness
, which might already have previous key witnesses.
signGYTx :: ToShelleyWitnessSigningKey a => GYTx -> [a] -> GYTx #
Sign a transaction with (potentially) multiple keys and add your witness(s) among previous key witnesses, if any.
signGYTx' :: GYTx -> [GYSomeSigningKey] -> GYTx #
Sign a transaction with (potentially) multiple keys of potentially different nature and add your witness(s) among previous key witnesses, if any.
Functions
txBodyFromHex :: String -> Maybe GYTxBody #
txBodyToHex :: GYTxBody -> String #
txBodyToHexBS :: GYTxBody -> ByteString #
txBodyFeeValue :: GYTxBody -> GYValue #
Return the fees as GYValue
.
txBodyUTxOs :: GYTxBody -> GYUTxOs #
Return utxos created by tx (body).
txBodyTxIns :: GYTxBody -> [GYTxOutRef] #
Returns the GYTxOutRef
consumed by the tx.
txBodyTxInsReference :: GYTxBody -> [GYTxOutRef] #
Returns the GYTxOutRef
for the reference inputs present in the tx.
txBodyReqSignatories :: GYTxBody -> Set GYPubKeyHash #
Returns the required signatories of the given GYTxBody
.
txBodyValidityRange :: GYTxBody -> (Maybe GYSlot, Maybe GYSlot) #
Returns the validity range of the given GYTxBody
.
txBodyCollateral :: GYTxBody -> Set GYTxOutRef #
Returns the set of GYTxOutRef
used as collateral in the given GYTxBody
.
txBodyTotalCollateralLovelace :: GYTxBody -> Natural #
Returns the total collateral for the given transaction body.