packages feed

blockfrost-client 0.3.0.0 → 0.3.1.0

raw patch · 4 files changed

+23/−2 lines, 4 filesdep ~blockfrost-apiPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: blockfrost-api

API changes (from Hackage documentation)

+ Blockfrost.Client: getBlockAffectedAddresses :: MonadBlockfrost m => Either Integer BlockHash -> m [(Address, [TxHash])]
+ Blockfrost.Client: getBlockAffectedAddresses' :: MonadBlockfrost m => Either Integer BlockHash -> Paged -> m [(Address, [TxHash])]
+ Blockfrost.Client.Cardano.Blocks: getBlockAffectedAddresses :: MonadBlockfrost m => Either Integer BlockHash -> m [(Address, [TxHash])]
+ Blockfrost.Client.Cardano.Blocks: getBlockAffectedAddresses' :: MonadBlockfrost m => Either Integer BlockHash -> Paged -> m [(Address, [TxHash])]

Files

CHANGELOG.md view
@@ -1,3 +1,8 @@+# Version [0.3.1.0](https://github.com/blockfrost/blockfrost-haskell/compare/v0.3.0.0...v0.3.1.0) (2022-02-17)++* Additions+  * `getBlockAffectedAddresses` for `/blocks/${hash_or_number}/addresses` endpoint (Affected addresses in a block)+ # Version [0.3.0.0](https://github.com/blockfrost/blockfrost-haskell/compare/v0.2.1.0...v0.3.0.0) (2022-02-07)  * Changes
blockfrost-client.cabal view
@@ -1,6 +1,6 @@ cabal-version:       2.2 name:                blockfrost-client-version:             0.3.0.0+version:             0.3.1.0 synopsis:            blockfrost.io basic client description:         Simple Blockfrost clients for use with transformers or mtl homepage:            https://github.com/blockfrost/blockfrost-haskell@@ -64,7 +64,7 @@                       , Blockfrost.Client.IPFS                       , Blockfrost.Client.NutLink    build-depends:       base >= 4.7 && < 5-                      , blockfrost-api ^>= 0.3+                      , blockfrost-api ^>= 0.3.1                       , blockfrost-client-core                       , bytestring                       , directory
src/Blockfrost/Client.hs view
@@ -67,6 +67,8 @@   , getPreviousBlocks'   , getBlockTxs   , getBlockTxs'+  , getBlockAffectedAddresses'+  , getBlockAffectedAddresses     -- Cardano - Epochs   , getLatestEpoch   , getLatestEpochProtocolParams
src/Blockfrost/Client/Cardano/Blocks.hs view
@@ -13,6 +13,8 @@   , getPreviousBlocks'   , getBlockTxs   , getBlockTxs'+  , getBlockAffectedAddresses'+  , getBlockAffectedAddresses   ) where  import Blockfrost.API@@ -96,3 +98,15 @@ -- | Return the transactions within the block. getBlockTxs :: MonadBlockfrost m => Either Integer BlockHash -> m [TxHash] getBlockTxs a = getBlockTxs' a def def++getBlockAffectedAddresses_ :: MonadBlockfrost m => Project -> Either Integer BlockHash -> Paged -> m [(Address, [TxHash])]+getBlockAffectedAddresses_ = _blockAffectedAddresses . blocksClient++-- | Return list of addresses affected in the specified block with additional information, sorted by the bech32 address, ascending.+-- Allows custom paging using @Paged@.+getBlockAffectedAddresses' :: MonadBlockfrost m => Either Integer BlockHash -> Paged -> m [(Address, [TxHash])]+getBlockAffectedAddresses' a pg = go (\p -> getBlockAffectedAddresses_ p a pg)++-- | Return list of addresses affected in the specified block with additional information, sorted by the bech32 address, ascending.+getBlockAffectedAddresses :: MonadBlockfrost m => Either Integer BlockHash -> m [(Address, [TxHash])]+getBlockAffectedAddresses a = getBlockAffectedAddresses' a def