@aws-sdk/client-managedblockchain-query 3.503.1 → 3.505.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist-cjs/index.js CHANGED
@@ -41,7 +41,6 @@ __export(src_exports, {
41
41
  QueryNetwork: () => QueryNetwork,
42
42
  QueryTokenStandard: () => QueryTokenStandard,
43
43
  QueryTransactionEventType: () => QueryTransactionEventType,
44
- QueryTransactionStatus: () => QueryTransactionStatus,
45
44
  ResourceNotFoundException: () => ResourceNotFoundException,
46
45
  ResourceType: () => ResourceType,
47
46
  ServiceQuotaExceededException: () => ServiceQuotaExceededException,
@@ -331,22 +330,13 @@ var _ValidationException = class _ValidationException extends ManagedBlockchainQ
331
330
  __name(_ValidationException, "ValidationException");
332
331
  var ValidationException = _ValidationException;
333
332
  var ConfirmationStatus = {
334
- FINAL: "FINAL"
333
+ FINAL: "FINAL",
334
+ NONFINAL: "NONFINAL"
335
335
  };
336
336
  var ExecutionStatus = {
337
337
  FAILED: "FAILED",
338
338
  SUCCEEDED: "SUCCEEDED"
339
339
  };
340
- var QueryTransactionStatus = {
341
- /**
342
- * The transaction completed on the blockchain, but failed
343
- */
344
- FAILED: "FAILED",
345
- /**
346
- * The transaction has been confirmed and is final in the blockchain
347
- */
348
- FINAL: "FINAL"
349
- };
350
340
  var QueryTransactionEventType = {
351
341
  /**
352
342
  * A Bitcoin Vin transfer type
@@ -537,6 +527,7 @@ var se_ListTransactionsCommand = /* @__PURE__ */ __name(async (input, context) =
537
527
  body = JSON.stringify(
538
528
  (0, import_smithy_client.take)(input, {
539
529
  address: [],
530
+ confirmationStatusFilter: (_) => (0, import_smithy_client._json)(_),
540
531
  fromBlockchainInstant: (_) => se_BlockchainInstant(_, context),
541
532
  maxResults: [],
542
533
  network: [],
@@ -1109,7 +1100,6 @@ var de_Transaction = /* @__PURE__ */ __name((output, context) => {
1109
1100
  signatureR: import_smithy_client.expectString,
1110
1101
  signatureS: import_smithy_client.expectString,
1111
1102
  signatureV: import_smithy_client.expectInt32,
1112
- status: import_smithy_client.expectString,
1113
1103
  to: import_smithy_client.expectString,
1114
1104
  transactionFee: import_smithy_client.expectString,
1115
1105
  transactionHash: import_smithy_client.expectString,
@@ -1120,6 +1110,7 @@ var de_Transaction = /* @__PURE__ */ __name((output, context) => {
1120
1110
  }, "de_Transaction");
1121
1111
  var de_TransactionOutputItem = /* @__PURE__ */ __name((output, context) => {
1122
1112
  return (0, import_smithy_client.take)(output, {
1113
+ confirmationStatus: import_smithy_client.expectString,
1123
1114
  network: import_smithy_client.expectString,
1124
1115
  transactionHash: import_smithy_client.expectString,
1125
1116
  transactionTimestamp: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseEpochTimestamp)((0, import_smithy_client.expectNumber)(_)))
@@ -1381,7 +1372,6 @@ var import_util_endpoints = require("@aws-sdk/util-endpoints");
1381
1372
  ValidationException,
1382
1373
  ConfirmationStatus,
1383
1374
  ExecutionStatus,
1384
- QueryTransactionStatus,
1385
1375
  QueryTransactionEventType,
1386
1376
  ListTransactionsSortBy,
1387
1377
  SortOrder
@@ -113,15 +113,12 @@ export class ValidationException extends __BaseException {
113
113
  }
114
114
  export const ConfirmationStatus = {
115
115
  FINAL: "FINAL",
116
+ NONFINAL: "NONFINAL",
116
117
  };
117
118
  export const ExecutionStatus = {
118
119
  FAILED: "FAILED",
119
120
  SUCCEEDED: "SUCCEEDED",
120
121
  };
121
- export const QueryTransactionStatus = {
122
- FAILED: "FAILED",
123
- FINAL: "FINAL",
124
- };
125
122
  export const QueryTransactionEventType = {
126
123
  BITCOIN_VIN: "BITCOIN_VIN",
127
124
  BITCOIN_VOUT: "BITCOIN_VOUT",
@@ -113,6 +113,7 @@ export const se_ListTransactionsCommand = async (input, context) => {
113
113
  let body;
114
114
  body = JSON.stringify(take(input, {
115
115
  address: [],
116
+ confirmationStatusFilter: (_) => _json(_),
116
117
  fromBlockchainInstant: (_) => se_BlockchainInstant(_, context),
117
118
  maxResults: [],
118
119
  network: [],
@@ -692,7 +693,6 @@ const de_Transaction = (output, context) => {
692
693
  signatureR: __expectString,
693
694
  signatureS: __expectString,
694
695
  signatureV: __expectInt32,
695
- status: __expectString,
696
696
  to: __expectString,
697
697
  transactionFee: __expectString,
698
698
  transactionHash: __expectString,
@@ -703,6 +703,7 @@ const de_Transaction = (output, context) => {
703
703
  };
704
704
  const de_TransactionOutputItem = (output, context) => {
705
705
  return take(output, {
706
+ confirmationStatus: __expectString,
706
707
  network: __expectString,
707
708
  transactionHash: __expectString,
708
709
  transactionTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
@@ -29,7 +29,7 @@ declare const BatchGetTokenBalanceCommand_base: {
29
29
  * <p>Gets the token balance for a batch of tokens by using the <code>BatchGetTokenBalance</code>
30
30
  * action for every token in the request.</p>
31
31
  * <note>
32
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
32
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
33
33
  * ERC-721, and ERC 1155 token standards are supported.</p>
34
34
  * </note>
35
35
  * @example
@@ -28,7 +28,7 @@ declare const GetTokenBalanceCommand_base: {
28
28
  * @public
29
29
  * <p>Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain.</p>
30
30
  * <note>
31
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
31
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
32
32
  * ERC-721, and ERC 1155 token standards are supported.</p>
33
33
  * </note>
34
34
  * @example
@@ -26,7 +26,13 @@ declare const GetTransactionCommand_base: {
26
26
  };
27
27
  /**
28
28
  * @public
29
- * <p>Get the details of a transaction.</p>
29
+ * <p>Gets the details of a transaction.</p>
30
+ * <note>
31
+ * <p>This action will return transaction details for all transactions
32
+ * that are <i>confirmed</i> on the blockchain, even if they have not reached
33
+ * <a href="https://docs.aws.amazon.com/managed-blockchain/latest/ambq-dg/key-concepts.html#finality">finality</a>.
34
+ * </p>
35
+ * </note>
30
36
  * @example
31
37
  * Use a bare-bones client and the command you need to make an API call.
32
38
  * ```javascript
@@ -48,7 +54,6 @@ declare const GetTransactionCommand_base: {
48
54
  * // transactionTimestamp: new Date("TIMESTAMP"), // required
49
55
  * // transactionIndex: Number("long"), // required
50
56
  * // numberOfTransactions: Number("long"), // required
51
- * // status: "STRING_VALUE",
52
57
  * // to: "STRING_VALUE", // required
53
58
  * // from: "STRING_VALUE",
54
59
  * // contractAddress: "STRING_VALUE",
@@ -28,6 +28,12 @@ declare const ListTransactionEventsCommand_base: {
28
28
  * @public
29
29
  * <p>An array of <code>TransactionEvent</code> objects. Each object contains details
30
30
  * about the transaction event.</p>
31
+ * <note>
32
+ * <p>This action will return transaction details for all transactions
33
+ * that are <i>confirmed</i> on the blockchain, even if they have not reached
34
+ * <a href="https://docs.aws.amazon.com/managed-blockchain/latest/ambq-dg/key-concepts.html#finality">finality</a>.
35
+ * </p>
36
+ * </note>
31
37
  * @example
32
38
  * Use a bare-bones client and the command you need to make an API call.
33
39
  * ```javascript
@@ -48,6 +48,11 @@ declare const ListTransactionsCommand_base: {
48
48
  * },
49
49
  * nextToken: "STRING_VALUE",
50
50
  * maxResults: Number("int"),
51
+ * confirmationStatusFilter: { // ConfirmationStatusFilter
52
+ * include: [ // ConfirmationStatusIncludeList // required
53
+ * "STRING_VALUE",
54
+ * ],
55
+ * },
51
56
  * };
52
57
  * const command = new ListTransactionsCommand(input);
53
58
  * const response = await client.send(command);
@@ -57,6 +62,7 @@ declare const ListTransactionsCommand_base: {
57
62
  * // transactionHash: "STRING_VALUE", // required
58
63
  * // network: "STRING_VALUE", // required
59
64
  * // transactionTimestamp: new Date("TIMESTAMP"), // required
65
+ * // confirmationStatus: "STRING_VALUE",
60
66
  * // },
61
67
  * // ],
62
68
  * // nextToken: "STRING_VALUE",
@@ -119,7 +119,7 @@ export interface OwnerIdentifier {
119
119
  * @public
120
120
  * <p>The container for the identifier for the token including the unique token ID and its blockchain network.</p>
121
121
  * <note>
122
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
122
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
123
123
  * ERC-721, and ERC 1155 token standards are supported.</p>
124
124
  * </note>
125
125
  */
@@ -138,8 +138,8 @@ export interface TokenIdentifier {
138
138
  * @public
139
139
  * <p>The unique identifier of the token.</p>
140
140
  * <note>
141
- * <p>You must specify this container with <code>btc</code> for the native BTC token, and
142
- * <code>eth</code> for the native ETH token. For all other token types you must
141
+ * <p>For native tokens, use the 3 character abbreviation that best matches your token.
142
+ * For example, btc for Bitcoin, eth for Ether, etc. For all other token types you must
143
143
  * specify the <code>tokenId</code> in the 64 character hexadecimal <code>tokenid</code> format.</p>
144
144
  * </note>
145
145
  */
@@ -154,7 +154,7 @@ export interface BatchGetTokenBalanceInputItem {
154
154
  * @public
155
155
  * <p>The container for the identifier for the token including the unique token ID and its blockchain network.</p>
156
156
  * <note>
157
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
157
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
158
158
  * ERC-721, and ERC 1155 token standards are supported.</p>
159
159
  * </note>
160
160
  */
@@ -207,7 +207,7 @@ export interface BatchGetTokenBalanceErrorItem {
207
207
  * @public
208
208
  * <p>The container for the identifier for the token including the unique token ID and its blockchain network.</p>
209
209
  * <note>
210
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
210
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
211
211
  * ERC-721, and ERC 1155 token standards are supported.</p>
212
212
  * </note>
213
213
  */
@@ -252,7 +252,7 @@ export interface BatchGetTokenBalanceOutputItem {
252
252
  * @public
253
253
  * <p>The container for the identifier for the token including the unique token ID and its blockchain network.</p>
254
254
  * <note>
255
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
255
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
256
256
  * ERC-721, and ERC 1155 token standards are supported.</p>
257
257
  * </note>
258
258
  */
@@ -462,11 +462,28 @@ export declare class ValidationException extends __BaseException {
462
462
  */
463
463
  export declare const ConfirmationStatus: {
464
464
  readonly FINAL: "FINAL";
465
+ readonly NONFINAL: "NONFINAL";
465
466
  };
466
467
  /**
467
468
  * @public
468
469
  */
469
470
  export type ConfirmationStatus = (typeof ConfirmationStatus)[keyof typeof ConfirmationStatus];
471
+ /**
472
+ * @public
473
+ * <p>The container for the <code>ConfirmationStatusFilter</code> that filters for the <a href="https://docs.aws.amazon.com/managed-blockchain/latest/ambq-dg/key-concepts.html#finality">
474
+ * <i>finality</i>
475
+ * </a> of the results.</p>
476
+ */
477
+ export interface ConfirmationStatusFilter {
478
+ /**
479
+ * @public
480
+ * <p>The container to determine whether to list results that have only reached <a href="https://docs.aws.amazon.com/managed-blockchain/latest/ambq-dg/key-concepts.html#finality">
481
+ * <i>finality</i>
482
+ * </a>. Transactions
483
+ * that have reached finality are always part of the response.</p>
484
+ */
485
+ include: ConfirmationStatus[] | undefined;
486
+ }
470
487
  /**
471
488
  * @public
472
489
  * <p>The contract or wallet address by which to filter the request.</p>
@@ -594,7 +611,7 @@ export interface GetTokenBalanceOutput {
594
611
  * @public
595
612
  * <p>The container for the identifier for the token including the unique token ID and its blockchain network.</p>
596
613
  * <note>
597
- * <p>Only the native tokens BTC,ETH, and the ERC-20,
614
+ * <p>Only the native tokens BTC and ETH, and the ERC-20,
598
615
  * ERC-721, and ERC 1155 token standards are supported.</p>
599
616
  * </note>
600
617
  */
@@ -630,24 +647,6 @@ export interface GetTransactionInput {
630
647
  */
631
648
  network: QueryNetwork | undefined;
632
649
  }
633
- /**
634
- * @public
635
- * @enum
636
- */
637
- export declare const QueryTransactionStatus: {
638
- /**
639
- * The transaction completed on the blockchain, but failed
640
- */
641
- readonly FAILED: "FAILED";
642
- /**
643
- * The transaction has been confirmed and is final in the blockchain
644
- */
645
- readonly FINAL: "FINAL";
646
- };
647
- /**
648
- * @public
649
- */
650
- export type QueryTransactionStatus = (typeof QueryTransactionStatus)[keyof typeof QueryTransactionStatus];
651
650
  /**
652
651
  * @public
653
652
  * <p>There are two possible types of transactions used for this data type:</p>
@@ -702,28 +701,6 @@ export interface Transaction {
702
701
  * <p>The number of transactions in the block.</p>
703
702
  */
704
703
  numberOfTransactions: number | undefined;
705
- /**
706
- * @public
707
- * @deprecated
708
- *
709
- * <p>The status of the transaction.</p>
710
- * <important>
711
- * <p>This property is deprecated. You must use the <code>confirmationStatus</code>
712
- * and the <code>executionStatus</code> properties to determine if the <code>status</code>
713
- * of the transaction is <code>FINAL</code> or <code>FAILED</code>.</p>
714
- * <ul>
715
- * <li>
716
- * <p>Transactions with a <code>status</code> of <code>FINAL</code> will now have the <code>confirmationStatus</code> set
717
- * to <code>FINAL</code> and the <code>executionStatus</code> set to <code>SUCCEEDED</code>.</p>
718
- * </li>
719
- * <li>
720
- * <p>Transactions with a <code>status</code> of <code>FAILED</code> will now have the <code>confirmationStatus</code> set
721
- * to <code>FINAL</code> and the <code>executionStatus</code> set to <code>FAILED</code>.</p>
722
- * </li>
723
- * </ul>
724
- * </important>
725
- */
726
- status?: QueryTransactionStatus;
727
704
  /**
728
705
  * @public
729
706
  * <p>The identifier of the transaction. It is generated whenever a transaction is verified and added to the blockchain.</p>
@@ -818,6 +795,15 @@ export interface ListAssetContractsInput {
818
795
  /**
819
796
  * @public
820
797
  * <p>The maximum number of contracts to list.</p>
798
+ * <p>Default:<code>100</code>
799
+ * </p>
800
+ * <note>
801
+ * <p>Even if additional results can be retrieved, the request can return less
802
+ * results than <code>maxResults</code> or an empty array of results.</p>
803
+ * <p>To retrieve the next set of results, make another request with the
804
+ * returned <code>nextToken</code> value. The value of <code>nextToken</code> is
805
+ * <code>null</code> when there are no more results to return</p>
806
+ * </note>
821
807
  */
822
808
  maxResults?: number;
823
809
  }
@@ -904,6 +890,15 @@ export interface ListTokenBalancesInput {
904
890
  /**
905
891
  * @public
906
892
  * <p>The maximum number of token balances to return.</p>
893
+ * <p>Default:<code>100</code>
894
+ * </p>
895
+ * <note>
896
+ * <p>Even if additional results can be retrieved, the request can return less
897
+ * results than <code>maxResults</code> or an empty array of results.</p>
898
+ * <p>To retrieve the next set of results, make another request with the
899
+ * returned <code>nextToken</code> value. The value of <code>nextToken</code> is
900
+ * <code>null</code> when there are no more results to return</p>
901
+ * </note>
907
902
  */
908
903
  maxResults?: number;
909
904
  }
@@ -980,6 +975,8 @@ export interface ListTransactionEventsInput {
980
975
  /**
981
976
  * @public
982
977
  * <p>The maximum number of transaction events to list.</p>
978
+ * <p>Default:<code>100</code>
979
+ * </p>
983
980
  * <note>
984
981
  * <p>Even if additional results can be retrieved, the request can return less
985
982
  * results than <code>maxResults</code> or an empty array of results.</p>
@@ -1194,8 +1191,8 @@ export interface ListTransactionsInput {
1194
1191
  toBlockchainInstant?: BlockchainInstant;
1195
1192
  /**
1196
1193
  * @public
1197
- * <p>Sorts items in an ascending order if the first page starts at <code>fromTime</code>.
1198
- * Sorts items in a descending order if the first page starts at <code>toTime</code>.</p>
1194
+ * <p>The order by which the results will be sorted. If <code>ASCENNDING</code> is selected, the results
1195
+ * will be ordered by <code>fromTime</code>. </p>
1199
1196
  */
1200
1197
  sort?: ListTransactionsSort;
1201
1198
  /**
@@ -1206,6 +1203,8 @@ export interface ListTransactionsInput {
1206
1203
  /**
1207
1204
  * @public
1208
1205
  * <p>The maximum number of transactions to list.</p>
1206
+ * <p>Default:<code>100</code>
1207
+ * </p>
1209
1208
  * <note>
1210
1209
  * <p>Even if additional results can be retrieved, the request can return less
1211
1210
  * results than <code>maxResults</code> or an empty array of results.</p>
@@ -1215,6 +1214,14 @@ export interface ListTransactionsInput {
1215
1214
  * </note>
1216
1215
  */
1217
1216
  maxResults?: number;
1217
+ /**
1218
+ * @public
1219
+ * <p>This filter is used to include transactions in the response that haven't reached <a href="https://docs.aws.amazon.com/managed-blockchain/latest/ambq-dg/key-concepts.html#finality">
1220
+ * <i>finality</i>
1221
+ * </a>. Transactions that have reached finiality are always
1222
+ * part of the response.</p>
1223
+ */
1224
+ confirmationStatusFilter?: ConfirmationStatusFilter;
1218
1225
  }
1219
1226
  /**
1220
1227
  * @public
@@ -1236,6 +1243,11 @@ export interface TransactionOutputItem {
1236
1243
  * <p>The time when the transaction occurred.</p>
1237
1244
  */
1238
1245
  transactionTimestamp: Date | undefined;
1246
+ /**
1247
+ * @public
1248
+ * <p>Specifies whether to list transactions that have not reached Finality.</p>
1249
+ */
1250
+ confirmationStatus?: ConfirmationStatus;
1239
1251
  }
1240
1252
  /**
1241
1253
  * @public
@@ -142,9 +142,13 @@ export declare class ValidationException extends __BaseException {
142
142
  }
143
143
  export declare const ConfirmationStatus: {
144
144
  readonly FINAL: "FINAL";
145
+ readonly NONFINAL: "NONFINAL";
145
146
  };
146
147
  export type ConfirmationStatus =
147
148
  (typeof ConfirmationStatus)[keyof typeof ConfirmationStatus];
149
+ export interface ConfirmationStatusFilter {
150
+ include: ConfirmationStatus[] | undefined;
151
+ }
148
152
  export interface ContractFilter {
149
153
  network: QueryNetwork | undefined;
150
154
  tokenStandard: QueryTokenStandard | undefined;
@@ -186,12 +190,6 @@ export interface GetTransactionInput {
186
190
  transactionHash: string | undefined;
187
191
  network: QueryNetwork | undefined;
188
192
  }
189
- export declare const QueryTransactionStatus: {
190
- readonly FAILED: "FAILED";
191
- readonly FINAL: "FINAL";
192
- };
193
- export type QueryTransactionStatus =
194
- (typeof QueryTransactionStatus)[keyof typeof QueryTransactionStatus];
195
193
  export interface Transaction {
196
194
  network: QueryNetwork | undefined;
197
195
  blockHash?: string;
@@ -200,7 +198,6 @@ export interface Transaction {
200
198
  transactionTimestamp: Date | undefined;
201
199
  transactionIndex: number | undefined;
202
200
  numberOfTransactions: number | undefined;
203
- status?: QueryTransactionStatus;
204
201
  to: string | undefined;
205
202
  from?: string;
206
203
  contractAddress?: string;
@@ -311,11 +308,13 @@ export interface ListTransactionsInput {
311
308
  sort?: ListTransactionsSort;
312
309
  nextToken?: string;
313
310
  maxResults?: number;
311
+ confirmationStatusFilter?: ConfirmationStatusFilter;
314
312
  }
315
313
  export interface TransactionOutputItem {
316
314
  transactionHash: string | undefined;
317
315
  network: QueryNetwork | undefined;
318
316
  transactionTimestamp: Date | undefined;
317
+ confirmationStatus?: ConfirmationStatus;
319
318
  }
320
319
  export interface ListTransactionsOutput {
321
320
  transactions: TransactionOutputItem[] | undefined;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-managedblockchain-query",
3
3
  "description": "AWS SDK for JavaScript Managedblockchain Query Client for Node.js, Browser and React Native",
4
- "version": "3.503.1",
4
+ "version": "3.505.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-managedblockchain-query",
@@ -20,9 +20,9 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "3.0.0",
22
22
  "@aws-crypto/sha256-js": "3.0.0",
23
- "@aws-sdk/client-sts": "3.502.0",
23
+ "@aws-sdk/client-sts": "3.504.0",
24
24
  "@aws-sdk/core": "3.496.0",
25
- "@aws-sdk/credential-provider-node": "3.503.1",
25
+ "@aws-sdk/credential-provider-node": "3.504.0",
26
26
  "@aws-sdk/middleware-host-header": "3.502.0",
27
27
  "@aws-sdk/middleware-logger": "3.502.0",
28
28
  "@aws-sdk/middleware-recursion-detection": "3.502.0",