aws-sdk-managedblockchainquery 1.1.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9f1363e25be9892ba143546c77ebdeb974841e249dfbe7228295604e950f5af5
4
- data.tar.gz: a69e0a8116fd96ec0d05d835c88c816eceead0f65f4fb82c68c125f624c35069
3
+ metadata.gz: 7ce14982bc6fcdfc1ee6dc35ed5be59495f82ba30c70b1e9de642e6ae4604b8d
4
+ data.tar.gz: 7eda799777beb7ffe0089687d672045c96a056e3a3e63beba3dbee024db35251
5
5
  SHA512:
6
- metadata.gz: 16fece41be5c4a8001985d1c55e788478175bbeac9d69bba88e5d90047d3277c30566736a00306632e1050b834c2cb8429a7c86a7d1dea601a2538265d9ef26d
7
- data.tar.gz: 9cc970c22b740d6ceea448a3d853b371013d1e2d4ea3c2e999048def1fc9e0419828470f4e2ca62168b832aaa02562a420af26e64b86a66b85239bbd467c2530
6
+ metadata.gz: d58faf6a35ea0c4fd6a774cb7cf071641024f2e3259d1d213600401c08fcd1a5f9d0a9a4cc24ad33f6bc78f820965623d8b11a64bf6399d675cb8195504b0deb
7
+ data.tar.gz: 1108e36a1d64d85fb40318f11c6cb0fc5b68e14972bef129c8d6c0ecc8314ef69fdbba62f4c23e08aa9037156dbfefffc2ae3c075cec017f53bfd23b15ceda79
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.2.0 (2023-10-16)
5
+ ------------------
6
+
7
+ * Feature - This release introduces two new APIs: GetAssetContract and ListAssetContracts. This release also adds support for Bitcoin Testnet.
8
+
4
9
  1.1.0 (2023-09-27)
5
10
  ------------------
6
11
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.0
1
+ 1.2.0
@@ -389,7 +389,7 @@ module Aws::ManagedBlockchainQuery
389
389
  # @!group API Operations
390
390
 
391
391
  # Gets the token balance for a batch of tokens by using the
392
- # `GetTokenBalance` action for every token in the request.
392
+ # `BatchGetTokenBalance` action for every token in the request.
393
393
  #
394
394
  # <note markdown="1"> Only the native tokens BTC,ETH, and the ERC-20, ERC-721, and ERC 1155
395
395
  # token standards are supported.
@@ -397,8 +397,8 @@ module Aws::ManagedBlockchainQuery
397
397
  # </note>
398
398
  #
399
399
  # @option params [Array<Types::BatchGetTokenBalanceInputItem>] :get_token_balance_inputs
400
- # An array of `GetTokenBalanceInput` objects whose balance is being
401
- # requested.
400
+ # An array of `BatchGetTokenBalanceInputItem` objects whose balance is
401
+ # being requested.
402
402
  #
403
403
  # @return [Types::BatchGetTokenBalanceOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
404
404
  #
@@ -411,7 +411,7 @@ module Aws::ManagedBlockchainQuery
411
411
  # get_token_balance_inputs: [
412
412
  # {
413
413
  # token_identifier: { # required
414
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
414
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
415
415
  # contract_address: "ChainAddress",
416
416
  # token_id: "QueryTokenId",
417
417
  # },
@@ -429,14 +429,14 @@ module Aws::ManagedBlockchainQuery
429
429
  #
430
430
  # resp.token_balances #=> Array
431
431
  # resp.token_balances[0].owner_identifier.address #=> String
432
- # resp.token_balances[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
432
+ # resp.token_balances[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
433
433
  # resp.token_balances[0].token_identifier.contract_address #=> String
434
434
  # resp.token_balances[0].token_identifier.token_id #=> String
435
435
  # resp.token_balances[0].balance #=> String
436
436
  # resp.token_balances[0].at_blockchain_instant.time #=> Time
437
437
  # resp.token_balances[0].last_updated_time.time #=> Time
438
438
  # resp.errors #=> Array
439
- # resp.errors[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
439
+ # resp.errors[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
440
440
  # resp.errors[0].token_identifier.contract_address #=> String
441
441
  # resp.errors[0].token_identifier.token_id #=> String
442
442
  # resp.errors[0].owner_identifier.address #=> String
@@ -454,6 +454,55 @@ module Aws::ManagedBlockchainQuery
454
454
  req.send_request(options)
455
455
  end
456
456
 
457
+ # Gets the information about a specific contract deployed on the
458
+ # blockchain.
459
+ #
460
+ # <note markdown="1"> * The Bitcoin blockchain networks do not support this operation.
461
+ #
462
+ # * Metadata is currently only available for some `ERC-20` contracts.
463
+ # Metadata will be available for additional contracts in the future.
464
+ #
465
+ # </note>
466
+ #
467
+ # @option params [required, Types::ContractIdentifier] :contract_identifier
468
+ # Contains the blockchain address and network information about the
469
+ # contract.
470
+ #
471
+ # @return [Types::GetAssetContractOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
472
+ #
473
+ # * {Types::GetAssetContractOutput#contract_identifier #contract_identifier} => Types::ContractIdentifier
474
+ # * {Types::GetAssetContractOutput#token_standard #token_standard} => String
475
+ # * {Types::GetAssetContractOutput#deployer_address #deployer_address} => String
476
+ # * {Types::GetAssetContractOutput#metadata #metadata} => Types::ContractMetadata
477
+ #
478
+ # @example Request syntax with placeholder values
479
+ #
480
+ # resp = client.get_asset_contract({
481
+ # contract_identifier: { # required
482
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
483
+ # contract_address: "ChainAddress", # required
484
+ # },
485
+ # })
486
+ #
487
+ # @example Response structure
488
+ #
489
+ # resp.contract_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
490
+ # resp.contract_identifier.contract_address #=> String
491
+ # resp.token_standard #=> String, one of "ERC20", "ERC721", "ERC1155"
492
+ # resp.deployer_address #=> String
493
+ # resp.metadata.name #=> String
494
+ # resp.metadata.symbol #=> String
495
+ # resp.metadata.decimals #=> Integer
496
+ #
497
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/GetAssetContract AWS API Documentation
498
+ #
499
+ # @overload get_asset_contract(params = {})
500
+ # @param [Hash] params ({})
501
+ def get_asset_contract(params = {}, options = {})
502
+ req = build_request(:get_asset_contract, params)
503
+ req.send_request(options)
504
+ end
505
+
457
506
  # Gets the balance of a specific token, including native tokens, for a
458
507
  # given address (wallet or contract) on the blockchain.
459
508
  #
@@ -489,7 +538,7 @@ module Aws::ManagedBlockchainQuery
489
538
  #
490
539
  # resp = client.get_token_balance({
491
540
  # token_identifier: { # required
492
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
541
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
493
542
  # contract_address: "ChainAddress",
494
543
  # token_id: "QueryTokenId",
495
544
  # },
@@ -504,7 +553,7 @@ module Aws::ManagedBlockchainQuery
504
553
  # @example Response structure
505
554
  #
506
555
  # resp.owner_identifier.address #=> String
507
- # resp.token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
556
+ # resp.token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
508
557
  # resp.token_identifier.contract_address #=> String
509
558
  # resp.token_identifier.token_id #=> String
510
559
  # resp.balance #=> String
@@ -537,12 +586,12 @@ module Aws::ManagedBlockchainQuery
537
586
  #
538
587
  # resp = client.get_transaction({
539
588
  # transaction_hash: "QueryTransactionHash", # required
540
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
589
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
541
590
  # })
542
591
  #
543
592
  # @example Response structure
544
593
  #
545
- # resp.transaction.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
594
+ # resp.transaction.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
546
595
  # resp.transaction.block_hash #=> String
547
596
  # resp.transaction.transaction_hash #=> String
548
597
  # resp.transaction.block_number #=> String
@@ -571,9 +620,61 @@ module Aws::ManagedBlockchainQuery
571
620
  req.send_request(options)
572
621
  end
573
622
 
574
- # This action returns the following for a given a blockchain network:
623
+ # Lists all the contracts for a given contract type deployed by an
624
+ # address (either a contract address or a wallet address).
625
+ #
626
+ # The Bitcoin blockchain networks do not support this operation.
627
+ #
628
+ # @option params [required, Types::ContractFilter] :contract_filter
629
+ # Contains the filter parameter for the request.
630
+ #
631
+ # @option params [String] :next_token
632
+ # The pagination token that indicates the next set of results to
633
+ # retrieve.
634
+ #
635
+ # @option params [Integer] :max_results
636
+ # The maximum number of contracts to list.
637
+ #
638
+ # @return [Types::ListAssetContractsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
639
+ #
640
+ # * {Types::ListAssetContractsOutput#contracts #contracts} => Array&lt;Types::AssetContract&gt;
641
+ # * {Types::ListAssetContractsOutput#next_token #next_token} => String
642
+ #
643
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
644
+ #
645
+ # @example Request syntax with placeholder values
646
+ #
647
+ # resp = client.list_asset_contracts({
648
+ # contract_filter: { # required
649
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
650
+ # token_standard: "ERC20", # required, accepts ERC20, ERC721, ERC1155
651
+ # deployer_address: "ChainAddress", # required
652
+ # },
653
+ # next_token: "NextToken",
654
+ # max_results: 1,
655
+ # })
656
+ #
657
+ # @example Response structure
658
+ #
659
+ # resp.contracts #=> Array
660
+ # resp.contracts[0].contract_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
661
+ # resp.contracts[0].contract_identifier.contract_address #=> String
662
+ # resp.contracts[0].token_standard #=> String, one of "ERC20", "ERC721", "ERC1155"
663
+ # resp.contracts[0].deployer_address #=> String
664
+ # resp.next_token #=> String
665
+ #
666
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ListAssetContracts AWS API Documentation
667
+ #
668
+ # @overload list_asset_contracts(params = {})
669
+ # @param [Hash] params ({})
670
+ def list_asset_contracts(params = {}, options = {})
671
+ req = build_request(:list_asset_contracts, params)
672
+ req.send_request(options)
673
+ end
674
+
675
+ # This action returns the following for a given blockchain network:
575
676
  #
576
- # * Lists all token balances owned by an address (either a contact
677
+ # * Lists all token balances owned by an address (either a contract
577
678
  # address or a wallet address).
578
679
  #
579
680
  # * Lists all token balances for all tokens created by a contract.
@@ -592,7 +693,7 @@ module Aws::ManagedBlockchainQuery
592
693
  #
593
694
  # @option params [required, Types::TokenFilter] :token_filter
594
695
  # The contract address or a token identifier on the blockchain network
595
- # by which to filter the request. You must specify the contractAddress
696
+ # by which to filter the request. You must specify the `contractAddress`
596
697
  # property of this container when listing tokens minted by a contract.
597
698
  #
598
699
  # <note markdown="1"> You must always specify the network property of this container when
@@ -621,7 +722,7 @@ module Aws::ManagedBlockchainQuery
621
722
  # address: "ChainAddress", # required
622
723
  # },
623
724
  # token_filter: { # required
624
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
725
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
625
726
  # contract_address: "ChainAddress",
626
727
  # token_id: "QueryTokenId",
627
728
  # },
@@ -633,7 +734,7 @@ module Aws::ManagedBlockchainQuery
633
734
  #
634
735
  # resp.token_balances #=> Array
635
736
  # resp.token_balances[0].owner_identifier.address #=> String
636
- # resp.token_balances[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
737
+ # resp.token_balances[0].token_identifier.network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
637
738
  # resp.token_balances[0].token_identifier.contract_address #=> String
638
739
  # resp.token_balances[0].token_identifier.token_id #=> String
639
740
  # resp.token_balances[0].balance #=> String
@@ -687,7 +788,7 @@ module Aws::ManagedBlockchainQuery
687
788
  #
688
789
  # resp = client.list_transaction_events({
689
790
  # transaction_hash: "QueryTransactionHash", # required
690
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
791
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
691
792
  # next_token: "NextToken",
692
793
  # max_results: 1,
693
794
  # })
@@ -695,7 +796,7 @@ module Aws::ManagedBlockchainQuery
695
796
  # @example Response structure
696
797
  #
697
798
  # resp.events #=> Array
698
- # resp.events[0].network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
799
+ # resp.events[0].network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
699
800
  # resp.events[0].transaction_hash #=> String
700
801
  # resp.events[0].event_type #=> String, one of "ERC20_TRANSFER", "ERC20_MINT", "ERC20_BURN", "ERC20_DEPOSIT", "ERC20_WITHDRAWAL", "ERC721_TRANSFER", "ERC1155_TRANSFER", "BITCOIN_VIN", "BITCOIN_VOUT", "INTERNAL_ETH_TRANSFER", "ETH_TRANSFER"
701
802
  # resp.events[0].from #=> String
@@ -764,7 +865,7 @@ module Aws::ManagedBlockchainQuery
764
865
  #
765
866
  # resp = client.list_transactions({
766
867
  # address: "ChainAddress", # required
767
- # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET
868
+ # network: "ETHEREUM_MAINNET", # required, accepts ETHEREUM_MAINNET, BITCOIN_MAINNET, BITCOIN_TESTNET
768
869
  # from_blockchain_instant: {
769
870
  # time: Time.now,
770
871
  # },
@@ -783,7 +884,7 @@ module Aws::ManagedBlockchainQuery
783
884
  #
784
885
  # resp.transactions #=> Array
785
886
  # resp.transactions[0].transaction_hash #=> String
786
- # resp.transactions[0].network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET"
887
+ # resp.transactions[0].network #=> String, one of "ETHEREUM_MAINNET", "BITCOIN_MAINNET", "BITCOIN_TESTNET"
787
888
  # resp.transactions[0].transaction_timestamp #=> Time
788
889
  # resp.next_token #=> String
789
890
  #
@@ -809,7 +910,7 @@ module Aws::ManagedBlockchainQuery
809
910
  params: params,
810
911
  config: config)
811
912
  context[:gem_name] = 'aws-sdk-managedblockchainquery'
812
- context[:gem_version] = '1.1.0'
913
+ context[:gem_version] = '1.2.0'
813
914
  Seahorse::Client::Request.new(handlers, context)
814
915
  end
815
916
 
@@ -14,6 +14,8 @@ module Aws::ManagedBlockchainQuery
14
14
  include Seahorse::Model
15
15
 
16
16
  AccessDeniedException = Shapes::StructureShape.new(name: 'AccessDeniedException')
17
+ AssetContract = Shapes::StructureShape.new(name: 'AssetContract')
18
+ AssetContractList = Shapes::ListShape.new(name: 'AssetContractList')
17
19
  BatchGetTokenBalanceErrorItem = Shapes::StructureShape.new(name: 'BatchGetTokenBalanceErrorItem')
18
20
  BatchGetTokenBalanceErrors = Shapes::ListShape.new(name: 'BatchGetTokenBalanceErrors')
19
21
  BatchGetTokenBalanceInput = Shapes::StructureShape.new(name: 'BatchGetTokenBalanceInput')
@@ -24,8 +26,13 @@ module Aws::ManagedBlockchainQuery
24
26
  BlockHash = Shapes::StringShape.new(name: 'BlockHash')
25
27
  BlockchainInstant = Shapes::StructureShape.new(name: 'BlockchainInstant')
26
28
  ChainAddress = Shapes::StringShape.new(name: 'ChainAddress')
29
+ ContractFilter = Shapes::StructureShape.new(name: 'ContractFilter')
30
+ ContractIdentifier = Shapes::StructureShape.new(name: 'ContractIdentifier')
31
+ ContractMetadata = Shapes::StructureShape.new(name: 'ContractMetadata')
27
32
  ErrorType = Shapes::StringShape.new(name: 'ErrorType')
28
33
  ExceptionMessage = Shapes::StringShape.new(name: 'ExceptionMessage')
34
+ GetAssetContractInput = Shapes::StructureShape.new(name: 'GetAssetContractInput')
35
+ GetAssetContractOutput = Shapes::StructureShape.new(name: 'GetAssetContractOutput')
29
36
  GetTokenBalanceInput = Shapes::StructureShape.new(name: 'GetTokenBalanceInput')
30
37
  GetTokenBalanceInputList = Shapes::ListShape.new(name: 'GetTokenBalanceInputList')
31
38
  GetTokenBalanceOutput = Shapes::StructureShape.new(name: 'GetTokenBalanceOutput')
@@ -33,6 +40,9 @@ module Aws::ManagedBlockchainQuery
33
40
  GetTransactionOutput = Shapes::StructureShape.new(name: 'GetTransactionOutput')
34
41
  Integer = Shapes::IntegerShape.new(name: 'Integer')
35
42
  InternalServerException = Shapes::StructureShape.new(name: 'InternalServerException')
43
+ ListAssetContractsInput = Shapes::StructureShape.new(name: 'ListAssetContractsInput')
44
+ ListAssetContractsInputMaxResultsInteger = Shapes::IntegerShape.new(name: 'ListAssetContractsInputMaxResultsInteger')
45
+ ListAssetContractsOutput = Shapes::StructureShape.new(name: 'ListAssetContractsOutput')
36
46
  ListTokenBalancesInput = Shapes::StructureShape.new(name: 'ListTokenBalancesInput')
37
47
  ListTokenBalancesInputMaxResultsInteger = Shapes::IntegerShape.new(name: 'ListTokenBalancesInputMaxResultsInteger')
38
48
  ListTokenBalancesOutput = Shapes::StructureShape.new(name: 'ListTokenBalancesOutput')
@@ -50,6 +60,7 @@ module Aws::ManagedBlockchainQuery
50
60
  OwnerIdentifier = Shapes::StructureShape.new(name: 'OwnerIdentifier')
51
61
  QueryNetwork = Shapes::StringShape.new(name: 'QueryNetwork')
52
62
  QueryTokenId = Shapes::StringShape.new(name: 'QueryTokenId')
63
+ QueryTokenStandard = Shapes::StringShape.new(name: 'QueryTokenStandard')
53
64
  QueryTransactionEventType = Shapes::StringShape.new(name: 'QueryTransactionEventType')
54
65
  QueryTransactionHash = Shapes::StringShape.new(name: 'QueryTransactionHash')
55
66
  QueryTransactionStatus = Shapes::StringShape.new(name: 'QueryTransactionStatus')
@@ -80,6 +91,13 @@ module Aws::ManagedBlockchainQuery
80
91
  AccessDeniedException.add_member(:message, Shapes::ShapeRef.new(shape: ExceptionMessage, required: true, location_name: "message"))
81
92
  AccessDeniedException.struct_class = Types::AccessDeniedException
82
93
 
94
+ AssetContract.add_member(:contract_identifier, Shapes::ShapeRef.new(shape: ContractIdentifier, required: true, location_name: "contractIdentifier"))
95
+ AssetContract.add_member(:token_standard, Shapes::ShapeRef.new(shape: QueryTokenStandard, required: true, location_name: "tokenStandard"))
96
+ AssetContract.add_member(:deployer_address, Shapes::ShapeRef.new(shape: ChainAddress, required: true, location_name: "deployerAddress"))
97
+ AssetContract.struct_class = Types::AssetContract
98
+
99
+ AssetContractList.member = Shapes::ShapeRef.new(shape: AssetContract)
100
+
83
101
  BatchGetTokenBalanceErrorItem.add_member(:token_identifier, Shapes::ShapeRef.new(shape: TokenIdentifier, location_name: "tokenIdentifier"))
84
102
  BatchGetTokenBalanceErrorItem.add_member(:owner_identifier, Shapes::ShapeRef.new(shape: OwnerIdentifier, location_name: "ownerIdentifier"))
85
103
  BatchGetTokenBalanceErrorItem.add_member(:at_blockchain_instant, Shapes::ShapeRef.new(shape: BlockchainInstant, location_name: "atBlockchainInstant"))
@@ -114,6 +132,29 @@ module Aws::ManagedBlockchainQuery
114
132
  BlockchainInstant.add_member(:time, Shapes::ShapeRef.new(shape: Timestamp, location_name: "time"))
115
133
  BlockchainInstant.struct_class = Types::BlockchainInstant
116
134
 
135
+ ContractFilter.add_member(:network, Shapes::ShapeRef.new(shape: QueryNetwork, required: true, location_name: "network"))
136
+ ContractFilter.add_member(:token_standard, Shapes::ShapeRef.new(shape: QueryTokenStandard, required: true, location_name: "tokenStandard"))
137
+ ContractFilter.add_member(:deployer_address, Shapes::ShapeRef.new(shape: ChainAddress, required: true, location_name: "deployerAddress"))
138
+ ContractFilter.struct_class = Types::ContractFilter
139
+
140
+ ContractIdentifier.add_member(:network, Shapes::ShapeRef.new(shape: QueryNetwork, required: true, location_name: "network"))
141
+ ContractIdentifier.add_member(:contract_address, Shapes::ShapeRef.new(shape: ChainAddress, required: true, location_name: "contractAddress"))
142
+ ContractIdentifier.struct_class = Types::ContractIdentifier
143
+
144
+ ContractMetadata.add_member(:name, Shapes::ShapeRef.new(shape: String, location_name: "name"))
145
+ ContractMetadata.add_member(:symbol, Shapes::ShapeRef.new(shape: String, location_name: "symbol"))
146
+ ContractMetadata.add_member(:decimals, Shapes::ShapeRef.new(shape: Integer, location_name: "decimals"))
147
+ ContractMetadata.struct_class = Types::ContractMetadata
148
+
149
+ GetAssetContractInput.add_member(:contract_identifier, Shapes::ShapeRef.new(shape: ContractIdentifier, required: true, location_name: "contractIdentifier"))
150
+ GetAssetContractInput.struct_class = Types::GetAssetContractInput
151
+
152
+ GetAssetContractOutput.add_member(:contract_identifier, Shapes::ShapeRef.new(shape: ContractIdentifier, required: true, location_name: "contractIdentifier"))
153
+ GetAssetContractOutput.add_member(:token_standard, Shapes::ShapeRef.new(shape: QueryTokenStandard, required: true, location_name: "tokenStandard"))
154
+ GetAssetContractOutput.add_member(:deployer_address, Shapes::ShapeRef.new(shape: ChainAddress, required: true, location_name: "deployerAddress"))
155
+ GetAssetContractOutput.add_member(:metadata, Shapes::ShapeRef.new(shape: ContractMetadata, location_name: "metadata"))
156
+ GetAssetContractOutput.struct_class = Types::GetAssetContractOutput
157
+
117
158
  GetTokenBalanceInput.add_member(:token_identifier, Shapes::ShapeRef.new(shape: TokenIdentifier, required: true, location_name: "tokenIdentifier"))
118
159
  GetTokenBalanceInput.add_member(:owner_identifier, Shapes::ShapeRef.new(shape: OwnerIdentifier, required: true, location_name: "ownerIdentifier"))
119
160
  GetTokenBalanceInput.add_member(:at_blockchain_instant, Shapes::ShapeRef.new(shape: BlockchainInstant, location_name: "atBlockchainInstant"))
@@ -139,6 +180,15 @@ module Aws::ManagedBlockchainQuery
139
180
  InternalServerException.add_member(:retry_after_seconds, Shapes::ShapeRef.new(shape: Integer, location: "header", location_name: "Retry-After"))
140
181
  InternalServerException.struct_class = Types::InternalServerException
141
182
 
183
+ ListAssetContractsInput.add_member(:contract_filter, Shapes::ShapeRef.new(shape: ContractFilter, required: true, location_name: "contractFilter"))
184
+ ListAssetContractsInput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
185
+ ListAssetContractsInput.add_member(:max_results, Shapes::ShapeRef.new(shape: ListAssetContractsInputMaxResultsInteger, location_name: "maxResults"))
186
+ ListAssetContractsInput.struct_class = Types::ListAssetContractsInput
187
+
188
+ ListAssetContractsOutput.add_member(:contracts, Shapes::ShapeRef.new(shape: AssetContractList, required: true, location_name: "contracts"))
189
+ ListAssetContractsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
190
+ ListAssetContractsOutput.struct_class = Types::ListAssetContractsOutput
191
+
142
192
  ListTokenBalancesInput.add_member(:owner_filter, Shapes::ShapeRef.new(shape: OwnerFilter, location_name: "ownerFilter"))
143
193
  ListTokenBalancesInput.add_member(:token_filter, Shapes::ShapeRef.new(shape: TokenFilter, required: true, location_name: "tokenFilter"))
144
194
  ListTokenBalancesInput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
@@ -305,6 +355,20 @@ module Aws::ManagedBlockchainQuery
305
355
  o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
306
356
  end)
307
357
 
358
+ api.add_operation(:get_asset_contract, Seahorse::Model::Operation.new.tap do |o|
359
+ o.name = "GetAssetContract"
360
+ o.http_method = "POST"
361
+ o.http_request_uri = "/get-asset-contract"
362
+ o.input = Shapes::ShapeRef.new(shape: GetAssetContractInput)
363
+ o.output = Shapes::ShapeRef.new(shape: GetAssetContractOutput)
364
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
365
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
366
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
367
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
368
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
369
+ o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
370
+ end)
371
+
308
372
  api.add_operation(:get_token_balance, Seahorse::Model::Operation.new.tap do |o|
309
373
  o.name = "GetTokenBalance"
310
374
  o.http_method = "POST"
@@ -333,6 +397,25 @@ module Aws::ManagedBlockchainQuery
333
397
  o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
334
398
  end)
335
399
 
400
+ api.add_operation(:list_asset_contracts, Seahorse::Model::Operation.new.tap do |o|
401
+ o.name = "ListAssetContracts"
402
+ o.http_method = "POST"
403
+ o.http_request_uri = "/list-asset-contracts"
404
+ o.input = Shapes::ShapeRef.new(shape: ListAssetContractsInput)
405
+ o.output = Shapes::ShapeRef.new(shape: ListAssetContractsOutput)
406
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
407
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
408
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
409
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
410
+ o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
411
+ o[:pager] = Aws::Pager.new(
412
+ limit_key: "max_results",
413
+ tokens: {
414
+ "next_token" => "next_token"
415
+ }
416
+ )
417
+ end)
418
+
336
419
  api.add_operation(:list_token_balances, Seahorse::Model::Operation.new.tap do |o|
337
420
  o.name = "ListTokenBalances"
338
421
  o.http_method = "POST"
@@ -26,6 +26,20 @@ module Aws::ManagedBlockchainQuery
26
26
  end
27
27
  end
28
28
 
29
+ class GetAssetContract
30
+ def self.build(context)
31
+ unless context.config.regional_endpoint
32
+ endpoint = context.config.endpoint.to_s
33
+ end
34
+ Aws::ManagedBlockchainQuery::EndpointParameters.new(
35
+ region: context.config.region,
36
+ use_dual_stack: context.config.use_dualstack_endpoint,
37
+ use_fips: context.config.use_fips_endpoint,
38
+ endpoint: endpoint,
39
+ )
40
+ end
41
+ end
42
+
29
43
  class GetTokenBalance
30
44
  def self.build(context)
31
45
  unless context.config.regional_endpoint
@@ -54,6 +68,20 @@ module Aws::ManagedBlockchainQuery
54
68
  end
55
69
  end
56
70
 
71
+ class ListAssetContracts
72
+ def self.build(context)
73
+ unless context.config.regional_endpoint
74
+ endpoint = context.config.endpoint.to_s
75
+ end
76
+ Aws::ManagedBlockchainQuery::EndpointParameters.new(
77
+ region: context.config.region,
78
+ use_dual_stack: context.config.use_dualstack_endpoint,
79
+ use_fips: context.config.use_fips_endpoint,
80
+ endpoint: endpoint,
81
+ )
82
+ end
83
+ end
84
+
57
85
  class ListTokenBalances
58
86
  def self.build(context)
59
87
  unless context.config.regional_endpoint
@@ -58,10 +58,14 @@ module Aws::ManagedBlockchainQuery
58
58
  case context.operation_name
59
59
  when :batch_get_token_balance
60
60
  Aws::ManagedBlockchainQuery::Endpoints::BatchGetTokenBalance.build(context)
61
+ when :get_asset_contract
62
+ Aws::ManagedBlockchainQuery::Endpoints::GetAssetContract.build(context)
61
63
  when :get_token_balance
62
64
  Aws::ManagedBlockchainQuery::Endpoints::GetTokenBalance.build(context)
63
65
  when :get_transaction
64
66
  Aws::ManagedBlockchainQuery::Endpoints::GetTransaction.build(context)
67
+ when :list_asset_contracts
68
+ Aws::ManagedBlockchainQuery::Endpoints::ListAssetContracts.build(context)
65
69
  when :list_token_balances
66
70
  Aws::ManagedBlockchainQuery::Endpoints::ListTokenBalances.build(context)
67
71
  when :list_transaction_events
@@ -24,6 +24,31 @@ module Aws::ManagedBlockchainQuery
24
24
  include Aws::Structure
25
25
  end
26
26
 
27
+ # This container contains information about an contract.
28
+ #
29
+ # @!attribute [rw] contract_identifier
30
+ # The container for the contract identifier containing its blockchain
31
+ # network and address.
32
+ # @return [Types::ContractIdentifier]
33
+ #
34
+ # @!attribute [rw] token_standard
35
+ # The token standard of the contract.
36
+ # @return [String]
37
+ #
38
+ # @!attribute [rw] deployer_address
39
+ # The address of the contract deployer.
40
+ # @return [String]
41
+ #
42
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/AssetContract AWS API Documentation
43
+ #
44
+ class AssetContract < Struct.new(
45
+ :contract_identifier,
46
+ :token_standard,
47
+ :deployer_address)
48
+ SENSITIVE = []
49
+ include Aws::Structure
50
+ end
51
+
27
52
  # Error generated from a failed `BatchGetTokenBalance` request.
28
53
  #
29
54
  # @!attribute [rw] token_identifier
@@ -70,8 +95,8 @@ module Aws::ManagedBlockchainQuery
70
95
  end
71
96
 
72
97
  # @!attribute [rw] get_token_balance_inputs
73
- # An array of `GetTokenBalanceInput` objects whose balance is being
74
- # requested.
98
+ # An array of `BatchGetTokenBalanceInputItem` objects whose balance is
99
+ # being requested.
75
100
  # @return [Array<Types::BatchGetTokenBalanceInputItem>]
76
101
  #
77
102
  # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/BatchGetTokenBalanceInput AWS API Documentation
@@ -189,6 +214,115 @@ module Aws::ManagedBlockchainQuery
189
214
  include Aws::Structure
190
215
  end
191
216
 
217
+ # The contract or wallet address by which to filter the request.
218
+ #
219
+ # @!attribute [rw] network
220
+ # The blockchain network of the contract.
221
+ # @return [String]
222
+ #
223
+ # @!attribute [rw] token_standard
224
+ # The container for the token standard.
225
+ # @return [String]
226
+ #
227
+ # @!attribute [rw] deployer_address
228
+ # The network address of the deployer.
229
+ # @return [String]
230
+ #
231
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ContractFilter AWS API Documentation
232
+ #
233
+ class ContractFilter < Struct.new(
234
+ :network,
235
+ :token_standard,
236
+ :deployer_address)
237
+ SENSITIVE = []
238
+ include Aws::Structure
239
+ end
240
+
241
+ # Container for the blockchain address and network information about a
242
+ # contract.
243
+ #
244
+ # @!attribute [rw] network
245
+ # The blockchain network of the contract.
246
+ # @return [String]
247
+ #
248
+ # @!attribute [rw] contract_address
249
+ # Container for the blockchain address about a contract.
250
+ # @return [String]
251
+ #
252
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ContractIdentifier AWS API Documentation
253
+ #
254
+ class ContractIdentifier < Struct.new(
255
+ :network,
256
+ :contract_address)
257
+ SENSITIVE = []
258
+ include Aws::Structure
259
+ end
260
+
261
+ # The metadata of the contract.
262
+ #
263
+ # @!attribute [rw] name
264
+ # The name of the token contract.
265
+ # @return [String]
266
+ #
267
+ # @!attribute [rw] symbol
268
+ # The symbol of the token contract.
269
+ # @return [String]
270
+ #
271
+ # @!attribute [rw] decimals
272
+ # The decimals used by the token contract.
273
+ # @return [Integer]
274
+ #
275
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ContractMetadata AWS API Documentation
276
+ #
277
+ class ContractMetadata < Struct.new(
278
+ :name,
279
+ :symbol,
280
+ :decimals)
281
+ SENSITIVE = []
282
+ include Aws::Structure
283
+ end
284
+
285
+ # @!attribute [rw] contract_identifier
286
+ # Contains the blockchain address and network information about the
287
+ # contract.
288
+ # @return [Types::ContractIdentifier]
289
+ #
290
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/GetAssetContractInput AWS API Documentation
291
+ #
292
+ class GetAssetContractInput < Struct.new(
293
+ :contract_identifier)
294
+ SENSITIVE = []
295
+ include Aws::Structure
296
+ end
297
+
298
+ # @!attribute [rw] contract_identifier
299
+ # Contains the blockchain address and network information about the
300
+ # contract.
301
+ # @return [Types::ContractIdentifier]
302
+ #
303
+ # @!attribute [rw] token_standard
304
+ # The token standard of the contract requested.
305
+ # @return [String]
306
+ #
307
+ # @!attribute [rw] deployer_address
308
+ # The address of the deployer of contract.
309
+ # @return [String]
310
+ #
311
+ # @!attribute [rw] metadata
312
+ # The metadata of the contract.
313
+ # @return [Types::ContractMetadata]
314
+ #
315
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/GetAssetContractOutput AWS API Documentation
316
+ #
317
+ class GetAssetContractOutput < Struct.new(
318
+ :contract_identifier,
319
+ :token_standard,
320
+ :deployer_address,
321
+ :metadata)
322
+ SENSITIVE = []
323
+ include Aws::Structure
324
+ end
325
+
192
326
  # @!attribute [rw] token_identifier
193
327
  # The container for the identifier for the token, including the unique
194
328
  # token ID and its blockchain network.
@@ -305,6 +439,48 @@ module Aws::ManagedBlockchainQuery
305
439
  include Aws::Structure
306
440
  end
307
441
 
442
+ # @!attribute [rw] contract_filter
443
+ # Contains the filter parameter for the request.
444
+ # @return [Types::ContractFilter]
445
+ #
446
+ # @!attribute [rw] next_token
447
+ # The pagination token that indicates the next set of results to
448
+ # retrieve.
449
+ # @return [String]
450
+ #
451
+ # @!attribute [rw] max_results
452
+ # The maximum number of contracts to list.
453
+ # @return [Integer]
454
+ #
455
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ListAssetContractsInput AWS API Documentation
456
+ #
457
+ class ListAssetContractsInput < Struct.new(
458
+ :contract_filter,
459
+ :next_token,
460
+ :max_results)
461
+ SENSITIVE = []
462
+ include Aws::Structure
463
+ end
464
+
465
+ # @!attribute [rw] contracts
466
+ # An array of contract objects that contain the properties for each
467
+ # contract.
468
+ # @return [Array<Types::AssetContract>]
469
+ #
470
+ # @!attribute [rw] next_token
471
+ # The pagination token that indicates the next set of results to
472
+ # retrieve.
473
+ # @return [String]
474
+ #
475
+ # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/ListAssetContractsOutput AWS API Documentation
476
+ #
477
+ class ListAssetContractsOutput < Struct.new(
478
+ :contracts,
479
+ :next_token)
480
+ SENSITIVE = []
481
+ include Aws::Structure
482
+ end
483
+
308
484
  # @!attribute [rw] owner_filter
309
485
  # The contract or wallet address on the blockchain network by which to
310
486
  # filter the request. You must specify the `address` property of the
@@ -313,8 +489,9 @@ module Aws::ManagedBlockchainQuery
313
489
  #
314
490
  # @!attribute [rw] token_filter
315
491
  # The contract address or a token identifier on the blockchain network
316
- # by which to filter the request. You must specify the contractAddress
317
- # property of this container when listing tokens minted by a contract.
492
+ # by which to filter the request. You must specify the
493
+ # `contractAddress` property of this container when listing tokens
494
+ # minted by a contract.
318
495
  #
319
496
  # <note markdown="1"> You must always specify the network property of this container when
320
497
  # using this operation.
@@ -657,7 +834,7 @@ module Aws::ManagedBlockchainQuery
657
834
  # @return [Types::BlockchainInstant]
658
835
  #
659
836
  # @!attribute [rw] last_updated_time
660
- # The `timestamp` of the last transaction at which the balance for the
837
+ # The `Timestamp` of the last transaction at which the balance for the
661
838
  # token in the wallet was updated.
662
839
  # @return [Types::BlockchainInstant]
663
840
  #
@@ -722,6 +899,13 @@ module Aws::ManagedBlockchainQuery
722
899
  #
723
900
  # @!attribute [rw] token_id
724
901
  # The unique identifier of the token.
902
+ #
903
+ # <note markdown="1"> You must specify this container with `btc` for the native BTC token,
904
+ # and `eth` for the native ETH token. For all other token types you
905
+ # must specify the `tokenId` in the 64 character hexadecimal `tokenid`
906
+ # format.
907
+ #
908
+ # </note>
725
909
  # @return [String]
726
910
  #
727
911
  # @see http://docs.aws.amazon.com/goto/WebAPI/managedblockchain-query-2023-05-04/TokenIdentifier AWS API Documentation
@@ -746,7 +930,7 @@ module Aws::ManagedBlockchainQuery
746
930
  # state-changing action occurs within a transaction.
747
931
  #
748
932
  # @!attribute [rw] network
749
- # The blockchain network where the transaction occured.
933
+ # The blockchain network where the transaction occurred.
750
934
  # @return [String]
751
935
  #
752
936
  # @!attribute [rw] block_hash
@@ -53,6 +53,6 @@ require_relative 'aws-sdk-managedblockchainquery/customizations'
53
53
  # @!group service
54
54
  module Aws::ManagedBlockchainQuery
55
55
 
56
- GEM_VERSION = '1.1.0'
56
+ GEM_VERSION = '1.2.0'
57
57
 
58
58
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-managedblockchainquery
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-27 00:00:00.000000000 Z
11
+ date: 2023-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core