@quicknode/sdk 1.1.0 → 1.1.1
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/cjs/index.js +130 -190
- package/esm/package.json.js +1 -1
- package/esm/src/api/controllers/contracts.js +6 -8
- package/esm/src/api/controllers/events.js +23 -31
- package/esm/src/api/controllers/nfts.js +44 -61
- package/esm/src/api/controllers/tokens.js +10 -15
- package/esm/src/api/controllers/transactions.js +26 -31
- package/esm/src/api/controllers/utils.js +6 -8
- package/esm/src/api/graphql/generatedTypes.js +1 -41
- package/esm/src/api/graphql/modifyQueryForChain.js +27 -0
- package/esm/src/api/graphql/schema.json.js +1 -1
- package/esm/src/api/index.d.ts +34 -40
- package/index.d.ts +34 -40
- package/package.json +3 -3
package/esm/src/api/index.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Client, GraphQLRequestParams } from '@urql/core';
|
|
2
|
-
import * as _urql_core_dist_urql_core_chunk from '@urql/core/dist/urql-core-chunk';
|
|
3
2
|
import { z } from 'zod';
|
|
4
3
|
|
|
5
4
|
/** All built-in and custom scalars, mapped to their actual values */
|
|
@@ -385,13 +384,8 @@ type ResultOutput = Record<string | number | symbol, any>;
|
|
|
385
384
|
declare class CustomUrqlClient {
|
|
386
385
|
urqlClient: Client;
|
|
387
386
|
constructor(urqlClient: Client);
|
|
388
|
-
query<TVariables extends Record<string,
|
|
389
|
-
data:
|
|
390
|
-
operation: _urql_core_dist_urql_core_chunk.Operation<any, Record<string, any> | TVariables>;
|
|
391
|
-
error?: _urql_core_dist_urql_core_chunk.CombinedError | undefined;
|
|
392
|
-
extensions?: Record<string, any> | undefined;
|
|
393
|
-
stale: boolean;
|
|
394
|
-
hasNext: boolean;
|
|
387
|
+
query<TVariables extends Record<string, unknown>, KResults extends Record<string, unknown>, KResultsOutput extends ResultOutput>(options: GraphQLRequestParams<any, TVariables>): Promise<{
|
|
388
|
+
data: KResultsOutput | undefined;
|
|
395
389
|
}>;
|
|
396
390
|
}
|
|
397
391
|
|
|
@@ -450,7 +444,7 @@ declare const walletByAddressValidator: z.ZodObject<{
|
|
|
450
444
|
before?: string | null | undefined;
|
|
451
445
|
after?: string | null | undefined;
|
|
452
446
|
first?: number | null | undefined;
|
|
453
|
-
chain?: "ethereum" | "
|
|
447
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
454
448
|
}, {
|
|
455
449
|
address: string;
|
|
456
450
|
filter?: {
|
|
@@ -465,7 +459,7 @@ declare const walletByAddressValidator: z.ZodObject<{
|
|
|
465
459
|
before?: string | null | undefined;
|
|
466
460
|
after?: string | null | undefined;
|
|
467
461
|
first?: number | null | undefined;
|
|
468
|
-
chain?: "ethereum" | "
|
|
462
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
469
463
|
}>;
|
|
470
464
|
type WalletNFTsByAddressInput = z.infer<typeof walletByAddressValidator>;
|
|
471
465
|
type WalletNFTsByAddressResult = SimplifyType<{
|
|
@@ -482,11 +476,11 @@ declare const nftDetailsValidator: z.ZodObject<{
|
|
|
482
476
|
}, "strict", z.ZodTypeAny, {
|
|
483
477
|
contractAddress: string;
|
|
484
478
|
tokenId: string;
|
|
485
|
-
chain?: "ethereum" | "
|
|
479
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
486
480
|
}, {
|
|
487
481
|
contractAddress: string;
|
|
488
482
|
tokenId: string;
|
|
489
|
-
chain?: "ethereum" | "
|
|
483
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
490
484
|
}>;
|
|
491
485
|
type NFTDetailsInput = z.infer<typeof nftDetailsValidator>;
|
|
492
486
|
type NFTDetailsResult = SimplifyType<{
|
|
@@ -498,10 +492,10 @@ declare const nftCollectionDetailsValidator: z.ZodObject<{
|
|
|
498
492
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
499
493
|
}, "strict", z.ZodTypeAny, {
|
|
500
494
|
contractAddress: string;
|
|
501
|
-
chain?: "ethereum" | "
|
|
495
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
502
496
|
}, {
|
|
503
497
|
contractAddress: string;
|
|
504
|
-
chain?: "ethereum" | "
|
|
498
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
505
499
|
}>;
|
|
506
500
|
type NftCollectionDetailsInput = z.infer<typeof nftCollectionDetailsValidator>;
|
|
507
501
|
type NftCollectionDetailsResult = SimplifyType<{
|
|
@@ -517,12 +511,12 @@ declare const nftTrendingCollectionsValidator: z.ZodObject<{
|
|
|
517
511
|
before?: string | null | undefined;
|
|
518
512
|
after?: string | null | undefined;
|
|
519
513
|
first?: number | null | undefined;
|
|
520
|
-
chain?: "ethereum" | "
|
|
514
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
521
515
|
}, {
|
|
522
516
|
before?: string | null | undefined;
|
|
523
517
|
after?: string | null | undefined;
|
|
524
518
|
first?: number | null | undefined;
|
|
525
|
-
chain?: "ethereum" | "
|
|
519
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
526
520
|
}>;
|
|
527
521
|
type NFTTrendingCollectionsInput = z.infer<typeof nftTrendingCollectionsValidator>;
|
|
528
522
|
type NFTTrendingCollectionResult = SimplifyType<{
|
|
@@ -543,13 +537,13 @@ declare const nftsByContractAddressValidator: z.ZodObject<{
|
|
|
543
537
|
before?: string | null | undefined;
|
|
544
538
|
after?: string | null | undefined;
|
|
545
539
|
first?: number | null | undefined;
|
|
546
|
-
chain?: "ethereum" | "
|
|
540
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
547
541
|
}, {
|
|
548
542
|
contractAddress: string;
|
|
549
543
|
before?: string | null | undefined;
|
|
550
544
|
after?: string | null | undefined;
|
|
551
545
|
first?: number | null | undefined;
|
|
552
|
-
chain?: "ethereum" | "
|
|
546
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
553
547
|
}>;
|
|
554
548
|
type NFTsByContractAddressInput = z.infer<typeof nftsByContractAddressValidator>;
|
|
555
549
|
type NFTsByContractAddressResult = SimplifyType<{
|
|
@@ -580,7 +574,7 @@ declare const verifyOwnershipValidator: z.ZodObject<{
|
|
|
580
574
|
contractAddress: string;
|
|
581
575
|
tokenId?: string | undefined;
|
|
582
576
|
}[]];
|
|
583
|
-
chain?: "ethereum" | "
|
|
577
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
584
578
|
}, {
|
|
585
579
|
address: string;
|
|
586
580
|
nfts: [{
|
|
@@ -590,7 +584,7 @@ declare const verifyOwnershipValidator: z.ZodObject<{
|
|
|
590
584
|
contractAddress: string;
|
|
591
585
|
tokenId?: string | undefined;
|
|
592
586
|
}[]];
|
|
593
|
-
chain?: "ethereum" | "
|
|
587
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
594
588
|
}>;
|
|
595
589
|
type VerifyOwnershipByAddressInput = z.infer<typeof verifyOwnershipValidator>;
|
|
596
590
|
|
|
@@ -628,13 +622,13 @@ declare const balancesByWalletAddressValidator$1: z.ZodObject<{
|
|
|
628
622
|
before?: string | null | undefined;
|
|
629
623
|
after?: string | null | undefined;
|
|
630
624
|
first?: number | null | undefined;
|
|
631
|
-
chain?: "ethereum" | "
|
|
625
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
632
626
|
}, {
|
|
633
627
|
address: string;
|
|
634
628
|
before?: string | null | undefined;
|
|
635
629
|
after?: string | null | undefined;
|
|
636
630
|
first?: number | null | undefined;
|
|
637
|
-
chain?: "ethereum" | "
|
|
631
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
638
632
|
}>;
|
|
639
633
|
type BalancesByWalletAddressInput = z.infer<typeof balancesByWalletAddressValidator$1>;
|
|
640
634
|
|
|
@@ -711,7 +705,7 @@ declare const gasPricesValidator: z.ZodObject<{
|
|
|
711
705
|
} | null | undefined;
|
|
712
706
|
} | null | undefined;
|
|
713
707
|
returnInGwei?: boolean | null | undefined;
|
|
714
|
-
chain?: "ethereum" | "
|
|
708
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
715
709
|
}, {
|
|
716
710
|
filter?: {
|
|
717
711
|
blockNumber?: {
|
|
@@ -725,7 +719,7 @@ declare const gasPricesValidator: z.ZodObject<{
|
|
|
725
719
|
} | null | undefined;
|
|
726
720
|
} | null | undefined;
|
|
727
721
|
returnInGwei?: boolean | null | undefined;
|
|
728
|
-
chain?: "ethereum" | "
|
|
722
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
729
723
|
}>;
|
|
730
724
|
type GasPricesInput = z.infer<typeof gasPricesValidator>;
|
|
731
725
|
type GasPricesResult = SimplifyType<{
|
|
@@ -744,10 +738,10 @@ declare const contractDetailsValidator: z.ZodObject<{
|
|
|
744
738
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
745
739
|
}, "strict", z.ZodTypeAny, {
|
|
746
740
|
contractAddress: string;
|
|
747
|
-
chain?: "ethereum" | "
|
|
741
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
748
742
|
}, {
|
|
749
743
|
contractAddress: string;
|
|
750
|
-
chain?: "ethereum" | "
|
|
744
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
751
745
|
}>;
|
|
752
746
|
type ContractDetailsInput = z.infer<typeof contractDetailsValidator>;
|
|
753
747
|
type ContractDetailsResult = SimplifyType<{
|
|
@@ -1106,7 +1100,7 @@ declare const contractEventsValidator: z.ZodObject<{
|
|
|
1106
1100
|
before?: string | null | undefined;
|
|
1107
1101
|
after?: string | null | undefined;
|
|
1108
1102
|
first?: number | null | undefined;
|
|
1109
|
-
chain?: "ethereum" | "
|
|
1103
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1110
1104
|
}, {
|
|
1111
1105
|
contractAddress: string;
|
|
1112
1106
|
filter?: {
|
|
@@ -1172,7 +1166,7 @@ declare const contractEventsValidator: z.ZodObject<{
|
|
|
1172
1166
|
before?: string | null | undefined;
|
|
1173
1167
|
after?: string | null | undefined;
|
|
1174
1168
|
first?: number | null | undefined;
|
|
1175
|
-
chain?: "ethereum" | "
|
|
1169
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1176
1170
|
}>;
|
|
1177
1171
|
type ContractEventsInput = z.infer<typeof contractEventsValidator>;
|
|
1178
1172
|
type ContractEventsResult = SimplifyType<{
|
|
@@ -1525,7 +1519,7 @@ declare const collectionEventsValidator: z.ZodObject<{
|
|
|
1525
1519
|
before?: string | null | undefined;
|
|
1526
1520
|
after?: string | null | undefined;
|
|
1527
1521
|
first?: number | null | undefined;
|
|
1528
|
-
chain?: "ethereum" | "
|
|
1522
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1529
1523
|
}, {
|
|
1530
1524
|
contractAddress: string;
|
|
1531
1525
|
filter?: {
|
|
@@ -1591,7 +1585,7 @@ declare const collectionEventsValidator: z.ZodObject<{
|
|
|
1591
1585
|
before?: string | null | undefined;
|
|
1592
1586
|
after?: string | null | undefined;
|
|
1593
1587
|
first?: number | null | undefined;
|
|
1594
|
-
chain?: "ethereum" | "
|
|
1588
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1595
1589
|
}>;
|
|
1596
1590
|
type CollectionEventsInput = z.infer<typeof collectionEventsValidator>;
|
|
1597
1591
|
type CollectionEventsResult = SimplifyType<{
|
|
@@ -1946,7 +1940,7 @@ declare const nftEventsValidator: z.ZodObject<{
|
|
|
1946
1940
|
before?: string | null | undefined;
|
|
1947
1941
|
after?: string | null | undefined;
|
|
1948
1942
|
first?: number | null | undefined;
|
|
1949
|
-
chain?: "ethereum" | "
|
|
1943
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1950
1944
|
}, {
|
|
1951
1945
|
contractAddress: string;
|
|
1952
1946
|
tokenId: string;
|
|
@@ -2013,7 +2007,7 @@ declare const nftEventsValidator: z.ZodObject<{
|
|
|
2013
2007
|
before?: string | null | undefined;
|
|
2014
2008
|
after?: string | null | undefined;
|
|
2015
2009
|
first?: number | null | undefined;
|
|
2016
|
-
chain?: "ethereum" | "
|
|
2010
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2017
2011
|
}>;
|
|
2018
2012
|
type NFTEventsInput = z.infer<typeof nftEventsValidator>;
|
|
2019
2013
|
type NFTEventsResult = SimplifyType<{
|
|
@@ -2364,7 +2358,7 @@ declare const allEventsValidator: z.ZodObject<{
|
|
|
2364
2358
|
before?: string | null | undefined;
|
|
2365
2359
|
after?: string | null | undefined;
|
|
2366
2360
|
first?: number | null | undefined;
|
|
2367
|
-
chain?: "ethereum" | "
|
|
2361
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2368
2362
|
}, {
|
|
2369
2363
|
filter?: {
|
|
2370
2364
|
blockNumber?: {
|
|
@@ -2429,7 +2423,7 @@ declare const allEventsValidator: z.ZodObject<{
|
|
|
2429
2423
|
before?: string | null | undefined;
|
|
2430
2424
|
after?: string | null | undefined;
|
|
2431
2425
|
first?: number | null | undefined;
|
|
2432
|
-
chain?: "ethereum" | "
|
|
2426
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2433
2427
|
}>;
|
|
2434
2428
|
type AllEventsInput = z.infer<typeof allEventsValidator>;
|
|
2435
2429
|
type AllEventsResult = SimplifyType<{
|
|
@@ -2458,13 +2452,13 @@ declare const balancesByWalletAddressValidator: z.ZodObject<{
|
|
|
2458
2452
|
before?: string | null | undefined;
|
|
2459
2453
|
after?: string | null | undefined;
|
|
2460
2454
|
first?: number | null | undefined;
|
|
2461
|
-
chain?: "ethereum" | "
|
|
2455
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2462
2456
|
}, {
|
|
2463
2457
|
address: string;
|
|
2464
2458
|
before?: string | null | undefined;
|
|
2465
2459
|
after?: string | null | undefined;
|
|
2466
2460
|
first?: number | null | undefined;
|
|
2467
|
-
chain?: "ethereum" | "
|
|
2461
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2468
2462
|
}>;
|
|
2469
2463
|
type TransactionsByWalletAddressInput = z.infer<typeof balancesByWalletAddressValidator>;
|
|
2470
2464
|
type TransactionsByWalletAddressResult = SimplifyType<{
|
|
@@ -2601,7 +2595,7 @@ declare const transactionsBySearchValidator: z.ZodObject<{
|
|
|
2601
2595
|
before?: string | null | undefined;
|
|
2602
2596
|
after?: string | null | undefined;
|
|
2603
2597
|
first?: number | null | undefined;
|
|
2604
|
-
chain?: "ethereum" | "
|
|
2598
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2605
2599
|
}, {
|
|
2606
2600
|
filter?: {
|
|
2607
2601
|
blockNumber?: {
|
|
@@ -2628,7 +2622,7 @@ declare const transactionsBySearchValidator: z.ZodObject<{
|
|
|
2628
2622
|
before?: string | null | undefined;
|
|
2629
2623
|
after?: string | null | undefined;
|
|
2630
2624
|
first?: number | null | undefined;
|
|
2631
|
-
chain?: "ethereum" | "
|
|
2625
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2632
2626
|
}>;
|
|
2633
2627
|
type TransactionsBySearchInput = z.infer<typeof transactionsBySearchValidator>;
|
|
2634
2628
|
type TransactionsBySearchResult = SimplifyType<{
|
|
@@ -2641,10 +2635,10 @@ declare const transactionsByHashValidator: z.ZodObject<{
|
|
|
2641
2635
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
2642
2636
|
}, "strict", z.ZodTypeAny, {
|
|
2643
2637
|
hash: string;
|
|
2644
|
-
chain?: "ethereum" | "
|
|
2638
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2645
2639
|
}, {
|
|
2646
2640
|
hash: string;
|
|
2647
|
-
chain?: "ethereum" | "
|
|
2641
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2648
2642
|
}>;
|
|
2649
2643
|
type TransactionsByHashInput = z.infer<typeof transactionsByHashValidator>;
|
|
2650
2644
|
type TransactionsByHashResult = SimplifyType<{
|
package/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Client, GraphQLRequestParams } from '@urql/core';
|
|
2
2
|
export { gql } from '@urql/core';
|
|
3
|
-
import * as _urql_core_dist_urql_core_chunk from '@urql/core/dist/urql-core-chunk';
|
|
4
3
|
import { z, ZodError } from 'zod';
|
|
5
4
|
import { Chain, PublicClient } from 'viem';
|
|
6
5
|
import * as viem from 'viem';
|
|
@@ -424,13 +423,8 @@ type ResultOutput = Record<string | number | symbol, any>;
|
|
|
424
423
|
declare class CustomUrqlClient {
|
|
425
424
|
urqlClient: Client;
|
|
426
425
|
constructor(urqlClient: Client);
|
|
427
|
-
query<TVariables extends Record<string,
|
|
428
|
-
data:
|
|
429
|
-
operation: _urql_core_dist_urql_core_chunk.Operation<any, Record<string, any> | TVariables>;
|
|
430
|
-
error?: _urql_core_dist_urql_core_chunk.CombinedError | undefined;
|
|
431
|
-
extensions?: Record<string, any> | undefined;
|
|
432
|
-
stale: boolean;
|
|
433
|
-
hasNext: boolean;
|
|
426
|
+
query<TVariables extends Record<string, unknown>, KResults extends Record<string, unknown>, KResultsOutput extends ResultOutput>(options: GraphQLRequestParams<any, TVariables>): Promise<{
|
|
427
|
+
data: KResultsOutput | undefined;
|
|
434
428
|
}>;
|
|
435
429
|
}
|
|
436
430
|
|
|
@@ -489,7 +483,7 @@ declare const walletByAddressValidator: z.ZodObject<{
|
|
|
489
483
|
before?: string | null | undefined;
|
|
490
484
|
after?: string | null | undefined;
|
|
491
485
|
first?: number | null | undefined;
|
|
492
|
-
chain?: "ethereum" | "
|
|
486
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
493
487
|
}, {
|
|
494
488
|
address: string;
|
|
495
489
|
filter?: {
|
|
@@ -504,7 +498,7 @@ declare const walletByAddressValidator: z.ZodObject<{
|
|
|
504
498
|
before?: string | null | undefined;
|
|
505
499
|
after?: string | null | undefined;
|
|
506
500
|
first?: number | null | undefined;
|
|
507
|
-
chain?: "ethereum" | "
|
|
501
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
508
502
|
}>;
|
|
509
503
|
type WalletNFTsByAddressInput = z.infer<typeof walletByAddressValidator>;
|
|
510
504
|
type WalletNFTsByAddressResult = SimplifyType<{
|
|
@@ -521,11 +515,11 @@ declare const nftDetailsValidator: z.ZodObject<{
|
|
|
521
515
|
}, "strict", z.ZodTypeAny, {
|
|
522
516
|
contractAddress: string;
|
|
523
517
|
tokenId: string;
|
|
524
|
-
chain?: "ethereum" | "
|
|
518
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
525
519
|
}, {
|
|
526
520
|
contractAddress: string;
|
|
527
521
|
tokenId: string;
|
|
528
|
-
chain?: "ethereum" | "
|
|
522
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
529
523
|
}>;
|
|
530
524
|
type NFTDetailsInput = z.infer<typeof nftDetailsValidator>;
|
|
531
525
|
type NFTDetailsResult = SimplifyType<{
|
|
@@ -537,10 +531,10 @@ declare const nftCollectionDetailsValidator: z.ZodObject<{
|
|
|
537
531
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
538
532
|
}, "strict", z.ZodTypeAny, {
|
|
539
533
|
contractAddress: string;
|
|
540
|
-
chain?: "ethereum" | "
|
|
534
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
541
535
|
}, {
|
|
542
536
|
contractAddress: string;
|
|
543
|
-
chain?: "ethereum" | "
|
|
537
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
544
538
|
}>;
|
|
545
539
|
type NftCollectionDetailsInput = z.infer<typeof nftCollectionDetailsValidator>;
|
|
546
540
|
type NftCollectionDetailsResult = SimplifyType<{
|
|
@@ -556,12 +550,12 @@ declare const nftTrendingCollectionsValidator: z.ZodObject<{
|
|
|
556
550
|
before?: string | null | undefined;
|
|
557
551
|
after?: string | null | undefined;
|
|
558
552
|
first?: number | null | undefined;
|
|
559
|
-
chain?: "ethereum" | "
|
|
553
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
560
554
|
}, {
|
|
561
555
|
before?: string | null | undefined;
|
|
562
556
|
after?: string | null | undefined;
|
|
563
557
|
first?: number | null | undefined;
|
|
564
|
-
chain?: "ethereum" | "
|
|
558
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
565
559
|
}>;
|
|
566
560
|
type NFTTrendingCollectionsInput = z.infer<typeof nftTrendingCollectionsValidator>;
|
|
567
561
|
type NFTTrendingCollectionResult = SimplifyType<{
|
|
@@ -582,13 +576,13 @@ declare const nftsByContractAddressValidator: z.ZodObject<{
|
|
|
582
576
|
before?: string | null | undefined;
|
|
583
577
|
after?: string | null | undefined;
|
|
584
578
|
first?: number | null | undefined;
|
|
585
|
-
chain?: "ethereum" | "
|
|
579
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
586
580
|
}, {
|
|
587
581
|
contractAddress: string;
|
|
588
582
|
before?: string | null | undefined;
|
|
589
583
|
after?: string | null | undefined;
|
|
590
584
|
first?: number | null | undefined;
|
|
591
|
-
chain?: "ethereum" | "
|
|
585
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
592
586
|
}>;
|
|
593
587
|
type NFTsByContractAddressInput = z.infer<typeof nftsByContractAddressValidator>;
|
|
594
588
|
type NFTsByContractAddressResult = SimplifyType<{
|
|
@@ -619,7 +613,7 @@ declare const verifyOwnershipValidator: z.ZodObject<{
|
|
|
619
613
|
contractAddress: string;
|
|
620
614
|
tokenId?: string | undefined;
|
|
621
615
|
}[]];
|
|
622
|
-
chain?: "ethereum" | "
|
|
616
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
623
617
|
}, {
|
|
624
618
|
address: string;
|
|
625
619
|
nfts: [{
|
|
@@ -629,7 +623,7 @@ declare const verifyOwnershipValidator: z.ZodObject<{
|
|
|
629
623
|
contractAddress: string;
|
|
630
624
|
tokenId?: string | undefined;
|
|
631
625
|
}[]];
|
|
632
|
-
chain?: "ethereum" | "
|
|
626
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
633
627
|
}>;
|
|
634
628
|
type VerifyOwnershipByAddressInput = z.infer<typeof verifyOwnershipValidator>;
|
|
635
629
|
|
|
@@ -672,13 +666,13 @@ declare const balancesByWalletAddressValidator$1: z.ZodObject<{
|
|
|
672
666
|
before?: string | null | undefined;
|
|
673
667
|
after?: string | null | undefined;
|
|
674
668
|
first?: number | null | undefined;
|
|
675
|
-
chain?: "ethereum" | "
|
|
669
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
676
670
|
}, {
|
|
677
671
|
address: string;
|
|
678
672
|
before?: string | null | undefined;
|
|
679
673
|
after?: string | null | undefined;
|
|
680
674
|
first?: number | null | undefined;
|
|
681
|
-
chain?: "ethereum" | "
|
|
675
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
682
676
|
}>;
|
|
683
677
|
type BalancesByWalletAddressInput = z.infer<typeof balancesByWalletAddressValidator$1>;
|
|
684
678
|
type BalancesByWalletAddressResult = SimplifyType<{
|
|
@@ -761,7 +755,7 @@ declare const gasPricesValidator: z.ZodObject<{
|
|
|
761
755
|
} | null | undefined;
|
|
762
756
|
} | null | undefined;
|
|
763
757
|
returnInGwei?: boolean | null | undefined;
|
|
764
|
-
chain?: "ethereum" | "
|
|
758
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
765
759
|
}, {
|
|
766
760
|
filter?: {
|
|
767
761
|
blockNumber?: {
|
|
@@ -775,7 +769,7 @@ declare const gasPricesValidator: z.ZodObject<{
|
|
|
775
769
|
} | null | undefined;
|
|
776
770
|
} | null | undefined;
|
|
777
771
|
returnInGwei?: boolean | null | undefined;
|
|
778
|
-
chain?: "ethereum" | "
|
|
772
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
779
773
|
}>;
|
|
780
774
|
type GasPricesInput = z.infer<typeof gasPricesValidator>;
|
|
781
775
|
type GasPricesResult = SimplifyType<{
|
|
@@ -794,10 +788,10 @@ declare const contractDetailsValidator: z.ZodObject<{
|
|
|
794
788
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
795
789
|
}, "strict", z.ZodTypeAny, {
|
|
796
790
|
contractAddress: string;
|
|
797
|
-
chain?: "ethereum" | "
|
|
791
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
798
792
|
}, {
|
|
799
793
|
contractAddress: string;
|
|
800
|
-
chain?: "ethereum" | "
|
|
794
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
801
795
|
}>;
|
|
802
796
|
type ContractDetailsInput = z.infer<typeof contractDetailsValidator>;
|
|
803
797
|
type ContractDetailsResult = SimplifyType<{
|
|
@@ -1156,7 +1150,7 @@ declare const contractEventsValidator: z.ZodObject<{
|
|
|
1156
1150
|
before?: string | null | undefined;
|
|
1157
1151
|
after?: string | null | undefined;
|
|
1158
1152
|
first?: number | null | undefined;
|
|
1159
|
-
chain?: "ethereum" | "
|
|
1153
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1160
1154
|
}, {
|
|
1161
1155
|
contractAddress: string;
|
|
1162
1156
|
filter?: {
|
|
@@ -1222,7 +1216,7 @@ declare const contractEventsValidator: z.ZodObject<{
|
|
|
1222
1216
|
before?: string | null | undefined;
|
|
1223
1217
|
after?: string | null | undefined;
|
|
1224
1218
|
first?: number | null | undefined;
|
|
1225
|
-
chain?: "ethereum" | "
|
|
1219
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1226
1220
|
}>;
|
|
1227
1221
|
type ContractEventsInput = z.infer<typeof contractEventsValidator>;
|
|
1228
1222
|
type ContractEventsResult = SimplifyType<{
|
|
@@ -1575,7 +1569,7 @@ declare const collectionEventsValidator: z.ZodObject<{
|
|
|
1575
1569
|
before?: string | null | undefined;
|
|
1576
1570
|
after?: string | null | undefined;
|
|
1577
1571
|
first?: number | null | undefined;
|
|
1578
|
-
chain?: "ethereum" | "
|
|
1572
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1579
1573
|
}, {
|
|
1580
1574
|
contractAddress: string;
|
|
1581
1575
|
filter?: {
|
|
@@ -1641,7 +1635,7 @@ declare const collectionEventsValidator: z.ZodObject<{
|
|
|
1641
1635
|
before?: string | null | undefined;
|
|
1642
1636
|
after?: string | null | undefined;
|
|
1643
1637
|
first?: number | null | undefined;
|
|
1644
|
-
chain?: "ethereum" | "
|
|
1638
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
1645
1639
|
}>;
|
|
1646
1640
|
type CollectionEventsInput = z.infer<typeof collectionEventsValidator>;
|
|
1647
1641
|
type CollectionEventsResult = SimplifyType<{
|
|
@@ -1996,7 +1990,7 @@ declare const nftEventsValidator: z.ZodObject<{
|
|
|
1996
1990
|
before?: string | null | undefined;
|
|
1997
1991
|
after?: string | null | undefined;
|
|
1998
1992
|
first?: number | null | undefined;
|
|
1999
|
-
chain?: "ethereum" | "
|
|
1993
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2000
1994
|
}, {
|
|
2001
1995
|
contractAddress: string;
|
|
2002
1996
|
tokenId: string;
|
|
@@ -2063,7 +2057,7 @@ declare const nftEventsValidator: z.ZodObject<{
|
|
|
2063
2057
|
before?: string | null | undefined;
|
|
2064
2058
|
after?: string | null | undefined;
|
|
2065
2059
|
first?: number | null | undefined;
|
|
2066
|
-
chain?: "ethereum" | "
|
|
2060
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2067
2061
|
}>;
|
|
2068
2062
|
type NFTEventsInput = z.infer<typeof nftEventsValidator>;
|
|
2069
2063
|
type NFTEventsResult = SimplifyType<{
|
|
@@ -2414,7 +2408,7 @@ declare const allEventsValidator: z.ZodObject<{
|
|
|
2414
2408
|
before?: string | null | undefined;
|
|
2415
2409
|
after?: string | null | undefined;
|
|
2416
2410
|
first?: number | null | undefined;
|
|
2417
|
-
chain?: "ethereum" | "
|
|
2411
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2418
2412
|
}, {
|
|
2419
2413
|
filter?: {
|
|
2420
2414
|
blockNumber?: {
|
|
@@ -2479,7 +2473,7 @@ declare const allEventsValidator: z.ZodObject<{
|
|
|
2479
2473
|
before?: string | null | undefined;
|
|
2480
2474
|
after?: string | null | undefined;
|
|
2481
2475
|
first?: number | null | undefined;
|
|
2482
|
-
chain?: "ethereum" | "
|
|
2476
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2483
2477
|
}>;
|
|
2484
2478
|
type AllEventsInput = z.infer<typeof allEventsValidator>;
|
|
2485
2479
|
type AllEventsResult = SimplifyType<{
|
|
@@ -2508,13 +2502,13 @@ declare const balancesByWalletAddressValidator: z.ZodObject<{
|
|
|
2508
2502
|
before?: string | null | undefined;
|
|
2509
2503
|
after?: string | null | undefined;
|
|
2510
2504
|
first?: number | null | undefined;
|
|
2511
|
-
chain?: "ethereum" | "
|
|
2505
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2512
2506
|
}, {
|
|
2513
2507
|
address: string;
|
|
2514
2508
|
before?: string | null | undefined;
|
|
2515
2509
|
after?: string | null | undefined;
|
|
2516
2510
|
first?: number | null | undefined;
|
|
2517
|
-
chain?: "ethereum" | "
|
|
2511
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2518
2512
|
}>;
|
|
2519
2513
|
type TransactionsByWalletAddressInput = z.infer<typeof balancesByWalletAddressValidator>;
|
|
2520
2514
|
type TransactionsByWalletAddressResult = SimplifyType<{
|
|
@@ -2651,7 +2645,7 @@ declare const transactionsBySearchValidator: z.ZodObject<{
|
|
|
2651
2645
|
before?: string | null | undefined;
|
|
2652
2646
|
after?: string | null | undefined;
|
|
2653
2647
|
first?: number | null | undefined;
|
|
2654
|
-
chain?: "ethereum" | "
|
|
2648
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2655
2649
|
}, {
|
|
2656
2650
|
filter?: {
|
|
2657
2651
|
blockNumber?: {
|
|
@@ -2678,7 +2672,7 @@ declare const transactionsBySearchValidator: z.ZodObject<{
|
|
|
2678
2672
|
before?: string | null | undefined;
|
|
2679
2673
|
after?: string | null | undefined;
|
|
2680
2674
|
first?: number | null | undefined;
|
|
2681
|
-
chain?: "ethereum" | "
|
|
2675
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2682
2676
|
}>;
|
|
2683
2677
|
type TransactionsBySearchInput = z.infer<typeof transactionsBySearchValidator>;
|
|
2684
2678
|
type TransactionsBySearchResult = SimplifyType<{
|
|
@@ -2691,10 +2685,10 @@ declare const transactionsByHashValidator: z.ZodObject<{
|
|
|
2691
2685
|
chain: z.ZodOptional<z.ZodNullable<z.ZodEnum<["ethereum", "polygon", "ethereumSepolia"]>>>;
|
|
2692
2686
|
}, "strict", z.ZodTypeAny, {
|
|
2693
2687
|
hash: string;
|
|
2694
|
-
chain?: "ethereum" | "
|
|
2688
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2695
2689
|
}, {
|
|
2696
2690
|
hash: string;
|
|
2697
|
-
chain?: "ethereum" | "
|
|
2691
|
+
chain?: "ethereum" | "polygon" | "ethereumSepolia" | null | undefined;
|
|
2698
2692
|
}>;
|
|
2699
2693
|
type TransactionsByHashInput = z.infer<typeof transactionsByHashValidator>;
|
|
2700
2694
|
type TransactionsByHashResult = SimplifyType<{
|
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
"directory": "packages/libs/sdk"
|
|
7
7
|
},
|
|
8
8
|
"license": "MIT",
|
|
9
|
-
"version": "1.1.
|
|
9
|
+
"version": "1.1.1",
|
|
10
10
|
"main": "./cjs/index.js",
|
|
11
11
|
"module": "./esm/src/index.js",
|
|
12
12
|
"types": "./index.d.ts",
|
|
@@ -15,8 +15,9 @@
|
|
|
15
15
|
"@urql/core": "^4.0.7",
|
|
16
16
|
"@urql/exchange-graphcache": "^6.0.4",
|
|
17
17
|
"cross-fetch": "^3.1.6",
|
|
18
|
-
"
|
|
18
|
+
"graphql": "^16.6.0",
|
|
19
19
|
"tslib": "^2.5.3",
|
|
20
|
+
"viem": "^1.2.0",
|
|
20
21
|
"zod": "^3.21.4"
|
|
21
22
|
},
|
|
22
23
|
"devDependencies": {
|
|
@@ -35,7 +36,6 @@
|
|
|
35
36
|
"@types/supertest": "^2.0.12",
|
|
36
37
|
"dotenv": "^16.0.3",
|
|
37
38
|
"eslint-plugin-no-only-tests": "^3.1.0",
|
|
38
|
-
"graphql": "^16.6.0",
|
|
39
39
|
"supertest": "^6.3.3"
|
|
40
40
|
},
|
|
41
41
|
"scripts": {
|