Skip to content

Commit

Permalink
Merge pull request #65 from ffakenz/client-fix-get-tx-in-cbor
Browse files Browse the repository at this point in the history
client: fix GET /txs/{hash}/cbor endpoint return type
  • Loading branch information
sorki authored Sep 25, 2024
2 parents 5053654 + c2efd09 commit 0e89ca7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
2 changes: 2 additions & 0 deletions blockfrost-api/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Version [next](https://github.com/blockfrost/blockfrost-haskell/compare/api-0.12.0.0...master) (2024-MM-DD)

* Fix return type of `/txs/:hash/cbor` endpoint from `[TransactionCBOR]` to `TransactionCBOR.`

# Version [0.12.0.0](https://github.com/blockfrost/blockfrost-haskell/compare/api-0.11.0.0...api-0.12.0.0) (2024-09-19)

* Additions
Expand Down
2 changes: 1 addition & 1 deletion blockfrost-api/src/Blockfrost/API/Cardano/Transactions.hs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ data TransactionsAPI route =
:> Description "Obtain the CBOR serialized transaction."
:> Capture "hash" TxHash
:> "cbor"
:> Get '[JSON] [TransactionCBOR]
:> Get '[JSON] TransactionCBOR
, _txMetadataCBOR
:: route
:- Summary "Transaction metadata in CBOR"
Expand Down
2 changes: 2 additions & 0 deletions blockfrost-client/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Version [next](https://github.com/blockfrost/blockfrost-haskell/compare/client-0.9.0.0...master) (2024-MM-DD)

* Fix return type of `getTxCBOR` and `_getTxCBOR'` from `[TransactionCBOR]` to `TransactionCBOR`.

# Version [0.9.0.0](https://github.com/blockfrost/blockfrost-haskell/compare/client-0.8.0.1...client-0.9.0.0) (2024-09-19)

* Additions
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,11 @@ getTxMetadataJSON_ = _txMetadataJSON . transactionsClient
getTxMetadataJSON :: MonadBlockfrost m => TxHash -> m [TransactionMetaJSON]
getTxMetadataJSON t = go (`getTxMetadataJSON_` t)

getTxCBOR_ :: MonadBlockfrost m => Project -> TxHash -> m [TransactionCBOR]
getTxCBOR_ :: MonadBlockfrost m => Project -> TxHash -> m TransactionCBOR
getTxCBOR_ = _txCBOR . transactionsClient

-- | Get transaction in CBOR
getTxCBOR :: MonadBlockfrost m => TxHash -> m [TransactionCBOR]
getTxCBOR :: MonadBlockfrost m => TxHash -> m TransactionCBOR
getTxCBOR t = go (`getTxCBOR_` t)

getTxMetadataCBOR_ :: MonadBlockfrost m => Project -> TxHash -> m [TransactionMetaCBOR]
Expand Down

0 comments on commit 0e89ca7

Please sign in to comment.