@metatrongg/sdk 0.8.0-dev.a70a494 → 0.8.0-dev.bace078

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.
@@ -288,6 +288,7 @@ type OauthPaymentIntentContext = {
288
288
  studioXHandle: string | null;
289
289
  };
290
290
  } | null;
291
+ environment: "development" | "production";
291
292
  };
292
293
  type OauthPaymentIntentSignResponse = {
293
294
  chain: string;
@@ -438,25 +439,39 @@ type Review = {
438
439
  id: string;
439
440
  recommended: ReviewRecommended;
440
441
  body: ReviewBody;
442
+ reactions: ReviewReactionCounts;
443
+ tippedCents: number;
444
+ commentCount: number;
441
445
  author: ReviewAuthor;
446
+ authorStats: ReviewerStats;
442
447
  developerReply: ReviewReply;
443
448
  createdAt: string;
444
449
  updatedAt: string;
445
450
  };
446
451
  type ReviewRecommended = boolean;
447
452
  type ReviewBody = string;
453
+ type ReviewReactionCounts = {
454
+ helpful: number;
455
+ unhelpful: number;
456
+ funny: number;
457
+ };
448
458
  type ReviewAuthor = {
449
459
  userId: string;
450
460
  handle: string | null;
451
461
  name: string | null;
452
462
  avatarUrl: string | null;
453
463
  };
464
+ type ReviewerStats = {
465
+ playtimeSecondsThisGame: number;
466
+ gamesPlayed: number;
467
+ reviewsWritten: number;
468
+ };
454
469
  type ReviewReply = {
455
470
  body: ReviewReplyBody;
456
471
  repliedAt: string;
457
472
  } | null;
458
473
  type ReviewReplyBody = string;
459
- type ReviewSort = "newest" | "oldest";
474
+ type ReviewSort = "newest" | "oldest" | "helpful";
460
475
  type MyReviewResponse = {
461
476
  eligible: boolean;
462
477
  eligibleVia: ReviewEligibilityReason;
@@ -475,6 +490,58 @@ type UpsertReviewRequest = {
475
490
  recommended: ReviewRecommended;
476
491
  body: ReviewBody;
477
492
  };
493
+ type MyReviewReactionsResponse = {
494
+ reactions: Array<MyReviewReaction>;
495
+ };
496
+ type MyReviewReaction = {
497
+ reviewId: string;
498
+ vote: ReviewVote;
499
+ funny: boolean;
500
+ };
501
+ type ReviewVote = "helpful" | "unhelpful" | null;
502
+ type SetReviewReactionResponse = {
503
+ reactions: ReviewReactionCounts;
504
+ vote: ReviewVote;
505
+ funny: boolean;
506
+ };
507
+ type SetReviewReactionRequest = {
508
+ vote: ReviewVote;
509
+ funny: boolean;
510
+ };
511
+ type TipReviewResponse = {
512
+ status: "completed";
513
+ amountCents: number;
514
+ balanceCents: number;
515
+ tippedCents: number;
516
+ };
517
+ type TipReviewRequest = {
518
+ amountCents: number;
519
+ note?: string;
520
+ challengeId?: string;
521
+ signature?: string;
522
+ };
523
+ type ReviewCommentListResponse = {
524
+ comments: Array<ReviewComment>;
525
+ total: number;
526
+ hasMore: boolean;
527
+ };
528
+ type ReviewComment = {
529
+ id: string;
530
+ body: ReviewCommentBody;
531
+ author: ReviewAuthor;
532
+ createdAt: string;
533
+ };
534
+ type ReviewCommentBody = string;
535
+ type CreateReviewCommentResponse = {
536
+ comment: ReviewComment;
537
+ commentCount: number;
538
+ };
539
+ type CreateReviewCommentRequest = {
540
+ body: ReviewCommentBody;
541
+ };
542
+ type DeleteReviewCommentResponse = {
543
+ commentCount: number;
544
+ };
478
545
  type ReviewReplyResponse = {
479
546
  developerReply: ReviewReply;
480
547
  };
@@ -582,7 +649,9 @@ type ActivityRow = ({
582
649
  kind: "tron_transfer";
583
650
  } & ActivityRowTronTransfer) | ({
584
651
  kind: "referral_earning";
585
- } & ActivityRowReferralEarning);
652
+ } & ActivityRowReferralEarning) | ({
653
+ kind: "nft_charge";
654
+ } & ActivityRowNftCharge);
586
655
  type ActivityRowPayment = {
587
656
  kind: "payment";
588
657
  groupId: string | null;
@@ -894,6 +963,22 @@ type ActivityRowReferralEarning = {
894
963
  logIndex: number;
895
964
  usdCents: number | null;
896
965
  };
966
+ type ActivityRowNftCharge = {
967
+ kind: "nft_charge";
968
+ groupId: string | null;
969
+ id: string;
970
+ occurredAt: string;
971
+ role: "outgoing";
972
+ chargeKind: "registration" | "mint" | "transfer_gas";
973
+ amountCents: number;
974
+ usdCents: number;
975
+ status: "settled";
976
+ collectionAddress: string | null;
977
+ tokenId: string | null;
978
+ counterpartyUserId: string | null;
979
+ counterpartyHandle: string | null;
980
+ counterpartyDisplayName: string | null;
981
+ };
897
982
  type OutstandingResponse = {
898
983
  rows: Array<OutstandingByToken>;
899
984
  };
@@ -943,7 +1028,7 @@ type TronLedgerResponse = {
943
1028
  };
944
1029
  type TronLedgerEntry = {
945
1030
  id: string;
946
- kind: "deposit" | "pot_stake" | "pot_payout" | "dev_earning" | "cashout_hold" | "cashout_release" | "dispute_freeze" | "dispute_unfreeze" | "hosted_billing" | "store_purchase" | "referral_earning" | "peer_transfer";
1031
+ kind: "deposit" | "pot_stake" | "pot_payout" | "dev_earning" | "cashout_hold" | "cashout_release" | "dispute_freeze" | "dispute_unfreeze" | "hosted_billing" | "store_purchase" | "referral_earning" | "peer_transfer" | "nft_registration" | "nft_mint" | "nft_gas";
947
1032
  amountCents: number;
948
1033
  currency: string;
949
1034
  createdAt: string;
@@ -972,6 +1057,30 @@ type TronTransferRequest = {
972
1057
  recipientUserId: string;
973
1058
  amountCents: number;
974
1059
  note?: string;
1060
+ challengeId?: string;
1061
+ signature?: string;
1062
+ threadId?: string;
1063
+ };
1064
+ type TronSecuritySetting = {
1065
+ requireSignature: boolean;
1066
+ };
1067
+ type TronTransferChallengeResponse = ({
1068
+ required: false;
1069
+ } & TronTransferChallengeNotRequired) | ({
1070
+ required: true;
1071
+ } & TronTransferChallengeRequired);
1072
+ type TronTransferChallengeNotRequired = {
1073
+ required: false;
1074
+ };
1075
+ type TronTransferChallengeRequired = {
1076
+ required: true;
1077
+ challengeId: string;
1078
+ message: string;
1079
+ expiresAt: string;
1080
+ };
1081
+ type TronTransferChallengeRequest = {
1082
+ recipientUserId: string;
1083
+ amountCents: number;
975
1084
  };
976
1085
  type TronGameBalanceResponse = {
977
1086
  balanceCents: number;
@@ -1215,6 +1324,7 @@ type ThreadLastMessagePreview = {
1215
1324
  url: string;
1216
1325
  count: number;
1217
1326
  } | null;
1327
+ transaction?: MessageTransaction;
1218
1328
  sentAt: string;
1219
1329
  } | null;
1220
1330
  type MessageEnvelope = {
@@ -1226,6 +1336,20 @@ type MessageEnvelope = {
1226
1336
  iv: string;
1227
1337
  ct: string;
1228
1338
  } | null;
1339
+ type MessageTransaction = MessageTransactionTronTransfer | MessageTransactionNftTransfer;
1340
+ type MessageTransactionTronTransfer = {
1341
+ kind: "tron_transfer";
1342
+ amountCents: number;
1343
+ recipientUserId: string;
1344
+ };
1345
+ type MessageTransactionNftTransfer = {
1346
+ kind: "nft_transfer";
1347
+ recipientUserId: string;
1348
+ collectionAddress: string;
1349
+ tokenId: string;
1350
+ amount: string;
1351
+ itemName: string | null;
1352
+ };
1229
1353
  type GroupThreadSummary = {
1230
1354
  kind: "group";
1231
1355
  id: string;
@@ -1272,6 +1396,7 @@ type MessageItem = {
1272
1396
  id: string;
1273
1397
  threadId: string;
1274
1398
  senderUserId: string;
1399
+ transaction?: MessageTransaction;
1275
1400
  body: string;
1276
1401
  envelope?: MessageEnvelope;
1277
1402
  sentAt: string;
@@ -1462,11 +1587,45 @@ type InventoryHolding = {
1462
1587
  tokenId: string;
1463
1588
  amount: string;
1464
1589
  name: string | null;
1590
+ description: string | null;
1465
1591
  imageAssetId: string | null;
1466
1592
  bannerAssetId: string | null;
1467
1593
  devMetadata: {
1468
1594
  [key: string]: unknown;
1469
1595
  };
1596
+ appId: string | null;
1597
+ appName: string | null;
1598
+ appLogoUrl: string | null;
1599
+ };
1600
+ type InventoryPendingPermitListResponse = {
1601
+ permits: Array<InventoryPendingPermit>;
1602
+ };
1603
+ type InventoryPendingPermit = {
1604
+ id: string;
1605
+ appId: string;
1606
+ itemId: string;
1607
+ amount: string;
1608
+ priceCents: number | null;
1609
+ gasSponsored: boolean;
1610
+ environment: "development" | "production";
1611
+ createdAt: string;
1612
+ tokenId: string;
1613
+ name: string | null;
1614
+ description: string | null;
1615
+ imageAssetId: string | null;
1616
+ chain: string;
1617
+ collectionAddress: string;
1618
+ kind: "erc721" | "erc1155";
1619
+ };
1620
+ type InventoryPermitRedeemResult = {
1621
+ mint: MintRequestResult;
1622
+ charge: {
1623
+ currency: "tron";
1624
+ gasCents: number;
1625
+ priceCents: number;
1626
+ totalCents: number;
1627
+ gasPaidBy: "user" | "developer";
1628
+ };
1470
1629
  };
1471
1630
  type MintRequestResult = {
1472
1631
  mintRequestId: string;
@@ -1482,6 +1641,247 @@ type MintRequestInput = {
1482
1641
  tokenId?: string;
1483
1642
  amount?: string;
1484
1643
  };
1644
+ type InventoryCollectionListResponse = {
1645
+ collections: Array<InventoryCollectionSummary>;
1646
+ };
1647
+ type InventoryCollectionSummary = {
1648
+ id: string;
1649
+ chain: string;
1650
+ collectionAddress: string;
1651
+ kind: "erc721" | "erc1155";
1652
+ name: string | null;
1653
+ environment: "development" | "production";
1654
+ };
1655
+ type InventoryRegistrationQuote = {
1656
+ itemCount: number;
1657
+ baselineUsdCents: number;
1658
+ gasUsdCents: number;
1659
+ tron: {
1660
+ baselineCents: number;
1661
+ gasCents: number;
1662
+ totalCents: number;
1663
+ };
1664
+ eth: {
1665
+ baselineWei: string;
1666
+ gasWei: string;
1667
+ totalWei: string;
1668
+ };
1669
+ };
1670
+ type InventoryItemRegistrationInput = {
1671
+ collectionAddress: string;
1672
+ chain: string;
1673
+ items: Array<InventoryItemRegistrationSpec>;
1674
+ };
1675
+ type InventoryItemRegistrationSpec = {
1676
+ name?: string | null;
1677
+ description?: string | null;
1678
+ devMetadata?: {
1679
+ [key: string]: unknown;
1680
+ };
1681
+ supplyType?: InventorySupplyType;
1682
+ maxSupply?: string | null;
1683
+ active?: boolean;
1684
+ };
1685
+ type InventorySupplyType = "capped" | "flexible" | "unlimited";
1686
+ type InventoryItemRegistrationResult = {
1687
+ items: Array<InventoryItemRecord>;
1688
+ charge: {
1689
+ currency: "tron";
1690
+ amountCents: number;
1691
+ baselineCents: number;
1692
+ gasCents: number;
1693
+ addItemTxHash: string;
1694
+ };
1695
+ };
1696
+ type InventoryItemRecord = {
1697
+ id: string;
1698
+ collectionId: string;
1699
+ collectionAddress: string;
1700
+ chain: string;
1701
+ kind: "erc721" | "erc1155";
1702
+ tokenId: string;
1703
+ name: string | null;
1704
+ description: string | null;
1705
+ imageAssetId: string | null;
1706
+ bannerAssetId: string | null;
1707
+ devMetadata: {
1708
+ [key: string]: unknown;
1709
+ };
1710
+ supplyType: InventorySupplyType | null;
1711
+ maxSupply: string | null;
1712
+ active: boolean;
1713
+ };
1714
+ type InventoryItemListResponse = {
1715
+ items: Array<InventoryItemRecord>;
1716
+ };
1717
+ type InventoryMintPermitRecord = {
1718
+ id: string;
1719
+ appId: string;
1720
+ itemId: string;
1721
+ userId: string;
1722
+ amount: string;
1723
+ priceCents: number | null;
1724
+ gasSponsored: boolean;
1725
+ status: "pending" | "redeemed" | "revoked";
1726
+ createdAt: string;
1727
+ };
1728
+ type InventoryMintPermitCreateInput = {
1729
+ toUserId: string;
1730
+ amount?: string;
1731
+ priceCents?: number | null;
1732
+ gasSponsored?: boolean;
1733
+ };
1734
+ type InventoryItemHoldersResponse = {
1735
+ stats: InventoryItemStats;
1736
+ holders: Array<InventoryItemHolder>;
1737
+ };
1738
+ type InventoryItemStats = {
1739
+ holderCount: number;
1740
+ walletCount: number;
1741
+ totalHeld: string;
1742
+ };
1743
+ type InventoryItemHolder = {
1744
+ walletAddress: string;
1745
+ userId: string | null;
1746
+ amount: string;
1747
+ };
1748
+ type InventoryVaultPermitRecord = {
1749
+ id: string;
1750
+ appId: string;
1751
+ itemId: string;
1752
+ userId: string;
1753
+ direction: "vault_in" | "withdraw";
1754
+ lockKind: "vault" | "burn" | null;
1755
+ amount: string;
1756
+ gasSponsored: boolean;
1757
+ status: "pending" | "redeemed" | "revoked";
1758
+ custodyId: string | null;
1759
+ createdAt: string;
1760
+ };
1761
+ type InventoryVaultPermitCreateInput = {
1762
+ toUserId: string;
1763
+ lockKind: "vault" | "burn";
1764
+ amount?: string;
1765
+ gasSponsored?: boolean;
1766
+ };
1767
+ type InventoryWithdrawPermitCreateInput = {
1768
+ custodyId: string;
1769
+ };
1770
+ type InventoryPendingVaultPermitListResponse = {
1771
+ permits: Array<InventoryPendingVaultPermit>;
1772
+ };
1773
+ type InventoryPendingVaultPermit = {
1774
+ id: string;
1775
+ appId: string;
1776
+ itemId: string;
1777
+ direction: "vault_in" | "withdraw";
1778
+ lockKind: "vault" | "burn" | null;
1779
+ amount: string;
1780
+ gasSponsored: boolean;
1781
+ environment: "development" | "production";
1782
+ custodyId: string | null;
1783
+ createdAt: string;
1784
+ tokenId: string;
1785
+ name: string | null;
1786
+ description: string | null;
1787
+ imageAssetId: string | null;
1788
+ chain: string;
1789
+ collectionAddress: string;
1790
+ kind: "erc721" | "erc1155";
1791
+ };
1792
+ type InventorySignedVaultPermit = {
1793
+ permitId: string;
1794
+ direction: "vault_in" | "withdraw";
1795
+ vault: string;
1796
+ collection: string;
1797
+ user: string;
1798
+ tokenId: string;
1799
+ amount: string;
1800
+ lockKind: "vault" | "burn" | null;
1801
+ destination: string | null;
1802
+ deadline: number;
1803
+ signature: string;
1804
+ };
1805
+ type InventoryRelayedVaultQuoteResponse = {
1806
+ direction: "vault_in" | "withdraw";
1807
+ collection: string;
1808
+ vault: string;
1809
+ chainId: number;
1810
+ user: string;
1811
+ tokenId: string;
1812
+ amount: string;
1813
+ nonce: string | null;
1814
+ deadline: number;
1815
+ feeCents: number;
1816
+ gasWei: string;
1817
+ gasPaidBy: "developer" | "user";
1818
+ requiresUserSignature: boolean;
1819
+ };
1820
+ type InventoryRelayedVaultSubmitResponse = {
1821
+ ok: boolean;
1822
+ txHash: string;
1823
+ chargedCents: number;
1824
+ gasPaidBy: "developer" | "user";
1825
+ };
1826
+ type InventoryRelayedVaultSubmitRequest = {
1827
+ userSignature?: string;
1828
+ deadline?: number;
1829
+ };
1830
+ type InventoryNftTransferQuoteResponse = {
1831
+ collection: string;
1832
+ chainId: number;
1833
+ from: string;
1834
+ to: string;
1835
+ tokenId: string;
1836
+ amount: string;
1837
+ nonce: string;
1838
+ deadline: number;
1839
+ feeCents: number;
1840
+ gasWei: string;
1841
+ selfPayAvailable: boolean;
1842
+ };
1843
+ type InventoryNftTransferQuoteRequest = {
1844
+ toUserId: string;
1845
+ collection: string;
1846
+ tokenId: string;
1847
+ amount?: string;
1848
+ };
1849
+ type InventoryNftTransferResponse = {
1850
+ ok: boolean;
1851
+ txHash: string;
1852
+ chargedCents: number;
1853
+ };
1854
+ type InventoryNftTransferRequest = {
1855
+ toUserId: string;
1856
+ collection: string;
1857
+ tokenId: string;
1858
+ amount?: string;
1859
+ deadline: number;
1860
+ userSignature: string;
1861
+ threadId?: string;
1862
+ };
1863
+ type InventoryVaultCustodyListResponse = {
1864
+ custody: Array<InventoryVaultCustody>;
1865
+ };
1866
+ type InventoryVaultCustody = {
1867
+ id: string;
1868
+ collectionId: string;
1869
+ collectionAddress: string;
1870
+ chain: string;
1871
+ kind: "erc721" | "erc1155";
1872
+ tokenId: string;
1873
+ amount: string;
1874
+ lockKind: "vault" | "burn";
1875
+ vaultAddress: string;
1876
+ createdAt: string;
1877
+ name: string | null;
1878
+ description: string | null;
1879
+ imageAssetId: string | null;
1880
+ };
1881
+ type InventoryVaultForceWithdrawResponse = {
1882
+ ok: boolean;
1883
+ txHash: string;
1884
+ };
1485
1885
  type NotificationListResponse = {
1486
1886
  notifications: Array<NotificationItem>;
1487
1887
  unreadCount: number;
@@ -2626,6 +3026,12 @@ declare function listDevelopers(context: TransportContext, input: {
2626
3026
  readonly bearer: string;
2627
3027
  }): Promise<AdminDeveloperListResponse>;
2628
3028
  //#endregion
3029
+ //#region src/admin/inventory-vault.d.ts
3030
+ declare function forceWithdrawVaultCustody(context: TransportContext, input: {
3031
+ readonly bearer: string;
3032
+ readonly custodyId: string;
3033
+ }): Promise<InventoryVaultForceWithdrawResponse>;
3034
+ //#endregion
2629
3035
  //#region src/admin/payments.d.ts
2630
3036
  declare function getPlatformFees(context: TransportContext, input: {
2631
3037
  readonly bearer: string;
@@ -2788,6 +3194,41 @@ declare function deleteMyGameReview(context: TransportContext, input: {
2788
3194
  readonly slug: string;
2789
3195
  readonly bearer: string;
2790
3196
  }): Promise<MyReviewResponse>;
3197
+ declare function getMyGameReviewReactions(context: TransportContext, input: {
3198
+ readonly slug: string;
3199
+ readonly bearer: string;
3200
+ }): Promise<MyReviewReactionsResponse>;
3201
+ declare function setMyGameReviewReaction(context: TransportContext, input: {
3202
+ readonly slug: string;
3203
+ readonly reviewId: string;
3204
+ readonly bearer: string;
3205
+ readonly reaction: SetReviewReactionRequest;
3206
+ }): Promise<SetReviewReactionResponse>;
3207
+ declare function tipGameReview(context: TransportContext, input: {
3208
+ readonly slug: string;
3209
+ readonly reviewId: string;
3210
+ readonly bearer: string;
3211
+ readonly tip: TipReviewRequest;
3212
+ readonly idempotencyKey?: string;
3213
+ }): Promise<TipReviewResponse>;
3214
+ declare function listGameReviewComments(context: TransportContext, input: {
3215
+ readonly slug: string;
3216
+ readonly reviewId: string;
3217
+ readonly bearer?: string;
3218
+ readonly limit?: number;
3219
+ readonly offset?: number;
3220
+ }): Promise<ReviewCommentListResponse>;
3221
+ declare function commentOnGameReview(context: TransportContext, input: {
3222
+ readonly slug: string;
3223
+ readonly reviewId: string;
3224
+ readonly bearer: string;
3225
+ readonly comment: CreateReviewCommentRequest;
3226
+ }): Promise<CreateReviewCommentResponse>;
3227
+ declare function deleteGameReviewComment(context: TransportContext, input: {
3228
+ readonly slug: string;
3229
+ readonly commentId: string;
3230
+ readonly bearer: string;
3231
+ }): Promise<DeleteReviewCommentResponse>;
2791
3232
  declare function replyToGameReview(context: TransportContext, input: {
2792
3233
  readonly appId: string;
2793
3234
  readonly reviewId: string;
@@ -3016,6 +3457,53 @@ declare function updateDeveloperAppContentReportStatus(context: TransportContext
3016
3457
  readonly status: "acknowledged" | "dismissed";
3017
3458
  }): Promise<AppContentReport>;
3018
3459
  //#endregion
3460
+ //#region src/developer/inventory.d.ts
3461
+ declare function quoteDeveloperAppInventoryRegistration(context: TransportContext, input: {
3462
+ readonly bearer: string;
3463
+ readonly appId: string;
3464
+ readonly registration: InventoryItemRegistrationInput;
3465
+ }): Promise<InventoryRegistrationQuote>;
3466
+ declare function registerDeveloperAppInventoryItem(context: TransportContext, input: {
3467
+ readonly bearer: string;
3468
+ readonly appId: string;
3469
+ readonly registration: InventoryItemRegistrationInput;
3470
+ }): Promise<InventoryItemRegistrationResult>;
3471
+ declare function listDeveloperAppInventoryCollections(context: TransportContext, input: {
3472
+ readonly bearer: string;
3473
+ readonly appId: string;
3474
+ }): Promise<InventoryCollectionListResponse>;
3475
+ declare function listDeveloperAppInventoryItems(context: TransportContext, input: {
3476
+ readonly bearer: string;
3477
+ readonly appId: string;
3478
+ }): Promise<InventoryItemListResponse>;
3479
+ declare function createDeveloperAppMintPermit(context: TransportContext, input: {
3480
+ readonly bearer: string;
3481
+ readonly appId: string;
3482
+ readonly itemId: string;
3483
+ readonly grant: InventoryMintPermitCreateInput;
3484
+ }): Promise<InventoryMintPermitRecord>;
3485
+ declare function getDeveloperAppInventoryItemHolders(context: TransportContext, input: {
3486
+ readonly bearer: string;
3487
+ readonly appId: string;
3488
+ readonly itemId: string;
3489
+ }): Promise<InventoryItemHoldersResponse>;
3490
+ declare function uploadDeveloperAppInventoryItemImage(context: TransportContext, input: {
3491
+ readonly bearer: string;
3492
+ readonly appId: string;
3493
+ readonly itemId: string;
3494
+ readonly file: Blob | ArrayBufferView | ArrayBuffer;
3495
+ readonly filename: string;
3496
+ readonly contentType: string;
3497
+ }): Promise<InventoryItemRecord>;
3498
+ declare function uploadDeveloperAppInventoryItemBanner(context: TransportContext, input: {
3499
+ readonly bearer: string;
3500
+ readonly appId: string;
3501
+ readonly itemId: string;
3502
+ readonly file: Blob | ArrayBufferView | ArrayBuffer;
3503
+ readonly filename: string;
3504
+ readonly contentType: string;
3505
+ }): Promise<InventoryItemRecord>;
3506
+ //#endregion
3019
3507
  //#region src/developer/pages.d.ts
3020
3508
  declare function getDeveloperAppPage(context: TransportContext, input: {
3021
3509
  readonly bearer: string;
@@ -3140,6 +3628,68 @@ declare function uploadMultipart(context: TransportContext, input: {
3140
3628
  readonly contentType: string;
3141
3629
  }): Promise<unknown>;
3142
3630
  //#endregion
3631
+ //#region src/developer/vault.d.ts
3632
+ declare function createDeveloperVaultPermit(context: TransportContext, input: {
3633
+ readonly bearer: string;
3634
+ readonly appId: string;
3635
+ readonly itemId: string;
3636
+ readonly grant: InventoryVaultPermitCreateInput;
3637
+ }): Promise<InventoryVaultPermitRecord>;
3638
+ declare function createDeveloperWithdrawPermit(context: TransportContext, input: {
3639
+ readonly bearer: string;
3640
+ readonly appId: string;
3641
+ readonly itemId: string;
3642
+ readonly grant: InventoryWithdrawPermitCreateInput;
3643
+ }): Promise<InventoryVaultPermitRecord>;
3644
+ //#endregion
3645
+ //#region src/events/inventory-socket.d.ts
3646
+ declare const inventoryUpdateEventSchema: z.ZodObject<{
3647
+ event: z.ZodLiteral<"inventory.updated">;
3648
+ deliveredAt: z.ZodString;
3649
+ environment: z.ZodEnum<{
3650
+ development: "development";
3651
+ production: "production";
3652
+ }>;
3653
+ subject: z.ZodString;
3654
+ collectionId: z.ZodString;
3655
+ collectionAddress: z.ZodString;
3656
+ chain: z.ZodString;
3657
+ kind: z.ZodEnum<{
3658
+ erc721: "erc721";
3659
+ erc1155: "erc1155";
3660
+ }>;
3661
+ tokenId: z.ZodString;
3662
+ direction: z.ZodEnum<{
3663
+ credit: "credit";
3664
+ debit: "debit";
3665
+ }>;
3666
+ amount: z.ZodString;
3667
+ balance: z.ZodString;
3668
+ }, z.core.$strip>;
3669
+ type InventoryUpdateEvent = z.infer<typeof inventoryUpdateEventSchema>;
3670
+ type OauthInventoryEventsSubscriberLifecycle = {
3671
+ onOpen?: () => void;
3672
+ onSubscribed?: (appId: string) => void;
3673
+ onMessage: (body: InventoryUpdateEvent) => void | Promise<void>;
3674
+ onClose?: (error: TronWsCloseError) => void;
3675
+ onError?: (error: Error) => void;
3676
+ };
3677
+ type OauthInventoryEventsSubscriberOptions = {
3678
+ readonly issuer: string;
3679
+ readonly clientId: string;
3680
+ readonly clientSecret: string;
3681
+ readonly logger?: Logger;
3682
+ readonly lifecycle: OauthInventoryEventsSubscriberLifecycle;
3683
+ readonly initialBackoffMs?: number;
3684
+ readonly maxBackoffMs?: number;
3685
+ readonly shouldReconnect?: (error: TronWsCloseError) => boolean;
3686
+ readonly WebSocketImpl?: typeof globalThis.WebSocket;
3687
+ };
3688
+ type OauthInventoryEventsSubscriber = {
3689
+ readonly stop: () => void;
3690
+ };
3691
+ declare function startOauthInventoryEventsSubscriber(options: OauthInventoryEventsSubscriberOptions): OauthInventoryEventsSubscriber;
3692
+ //#endregion
3143
3693
  //#region src/webhook/verify.d.ts
3144
3694
  declare const oauthPaymentWebhookBodySchema: z.ZodObject<{
3145
3695
  event: z.ZodEnum<{
@@ -3153,9 +3703,9 @@ declare const oauthPaymentWebhookBodySchema: z.ZodObject<{
3153
3703
  intentId: z.ZodString;
3154
3704
  appId: z.ZodString;
3155
3705
  status: z.ZodEnum<{
3156
- completed: "completed";
3157
3706
  pending: "pending";
3158
3707
  awaiting_funding: "awaiting_funding";
3708
+ completed: "completed";
3159
3709
  denied: "denied";
3160
3710
  expired: "expired";
3161
3711
  }>;
@@ -3214,6 +3764,7 @@ type OauthPaymentEventsSubscriberOptions = {
3214
3764
  readonly maxBackoffMs?: number;
3215
3765
  readonly shouldReconnect?: (error: TronWsCloseError) => boolean;
3216
3766
  readonly WebSocketImpl?: typeof globalThis.WebSocket;
3767
+ readonly disableEventAck?: boolean;
3217
3768
  };
3218
3769
  type OauthPaymentEventsSubscriber = {
3219
3770
  readonly stop: () => void;
@@ -3228,12 +3779,55 @@ declare function listInventoryForApp(context: TransportContext, input: {
3228
3779
  readonly bearer: string;
3229
3780
  }): Promise<InventoryListResponse>;
3230
3781
  //#endregion
3782
+ //#region src/inventory/nft-transfer.d.ts
3783
+ declare function quoteNftTransfer(context: TransportContext, input: {
3784
+ readonly bearer: string;
3785
+ readonly body: InventoryNftTransferQuoteRequest;
3786
+ }): Promise<InventoryNftTransferQuoteResponse>;
3787
+ declare function executeNftTransfer(context: TransportContext, input: {
3788
+ readonly bearer: string;
3789
+ readonly body: InventoryNftTransferRequest;
3790
+ }): Promise<InventoryNftTransferResponse>;
3791
+ //#endregion
3792
+ //#region src/inventory/permits.d.ts
3793
+ declare function listInventoryMintPermits(context: TransportContext, input: {
3794
+ readonly bearer: string;
3795
+ }): Promise<InventoryPendingPermitListResponse>;
3796
+ declare function redeemInventoryMintPermit(context: TransportContext, input: {
3797
+ readonly bearer: string;
3798
+ readonly permitId: string;
3799
+ }): Promise<InventoryPermitRedeemResult>;
3800
+ //#endregion
3231
3801
  //#region src/inventory/request-mint.d.ts
3232
3802
  declare function requestMint(context: TransportContext, input: {
3233
3803
  readonly appBearer: string;
3234
3804
  readonly body: MintRequestInput;
3235
3805
  }): Promise<MintRequestResult>;
3236
3806
  //#endregion
3807
+ //#region src/inventory/vault.d.ts
3808
+ declare function listInventoryVaultPermits(context: TransportContext, input: {
3809
+ readonly bearer: string;
3810
+ }): Promise<InventoryPendingVaultPermitListResponse>;
3811
+ declare function signInventoryVaultPermit(context: TransportContext, input: {
3812
+ readonly bearer: string;
3813
+ readonly permitId: string;
3814
+ }): Promise<InventorySignedVaultPermit>;
3815
+ declare function quoteRelayedVaultPermit(context: TransportContext, input: {
3816
+ readonly bearer: string;
3817
+ readonly permitId: string;
3818
+ }): Promise<InventoryRelayedVaultQuoteResponse>;
3819
+ declare function submitRelayedVaultPermit(context: TransportContext, input: {
3820
+ readonly bearer: string;
3821
+ readonly permitId: string;
3822
+ readonly body: InventoryRelayedVaultSubmitRequest;
3823
+ }): Promise<InventoryRelayedVaultSubmitResponse>;
3824
+ declare function listInventoryVaulted(context: TransportContext, input: {
3825
+ readonly bearer: string;
3826
+ }): Promise<InventoryVaultCustodyListResponse>;
3827
+ declare function listOauthInventoryVaulted(context: TransportContext, input: {
3828
+ readonly bearer: string;
3829
+ }): Promise<InventoryVaultCustodyListResponse>;
3830
+ //#endregion
3237
3831
  //#region src/messaging/dm-key-backup.d.ts
3238
3832
  declare function getDmKeyBackupStatus(context: TransportContext, input: {
3239
3833
  readonly bearer: string;
@@ -3553,6 +4147,17 @@ declare function createTronTransfer(context: TransportContext, input: {
3553
4147
  readonly body: TronTransferRequest;
3554
4148
  readonly idempotencyKey?: string;
3555
4149
  }): Promise<TronTransferResponse>;
4150
+ declare function getTronSecurity(context: TransportContext, input: {
4151
+ readonly bearer: string;
4152
+ }): Promise<TronSecuritySetting>;
4153
+ declare function setTronSecurity(context: TransportContext, input: {
4154
+ readonly bearer: string;
4155
+ readonly setting: TronSecuritySetting;
4156
+ }): Promise<TronSecuritySetting>;
4157
+ declare function createTronTransferChallenge(context: TransportContext, input: {
4158
+ readonly bearer: string;
4159
+ readonly body: TronTransferChallengeRequest;
4160
+ }): Promise<TronTransferChallengeResponse>;
3556
4161
  declare function createTronConnectOnboarding(context: TransportContext, input: {
3557
4162
  readonly bearer: string;
3558
4163
  }): Promise<TronConnectOnboardingResponse>;
@@ -3727,6 +4332,10 @@ declare function sendFriendRequest(context: TransportContext, input: {
3727
4332
  readonly bearer: string;
3728
4333
  readonly userId: string;
3729
4334
  }): Promise<void>;
4335
+ declare function removeFriend(context: TransportContext, input: {
4336
+ readonly bearer: string;
4337
+ readonly userId: string;
4338
+ }): Promise<void>;
3730
4339
  declare function decideFriendRequest(context: TransportContext, input: {
3731
4340
  readonly bearer: string;
3732
4341
  readonly requestId: string;
@@ -3865,6 +4474,7 @@ declare class TronNodeClient {
3865
4474
  };
3866
4475
  };
3867
4476
  subscribeOauthPaymentEvents(lifecycle: OauthPaymentEventsSubscriberLifecycle): OauthPaymentEventsSubscriber;
4477
+ subscribeOauthInventoryEvents(lifecycle: OauthInventoryEventsSubscriberLifecycle): OauthInventoryEventsSubscriber;
3868
4478
  get users(): {
3869
4479
  get: (input: {
3870
4480
  bearer?: string;
@@ -3986,4 +4596,4 @@ declare class TronNodeClient {
3986
4596
  };
3987
4597
  }
3988
4598
  //#endregion
3989
- export { AppTokenCache, AuthorizeUrl, type BrowserClientConfig, BuildAuthorizeUrlInput, ChargeResult, type FetchLike, GameHalfCredentials, HttpsGuardOptions, InflightDedup, type Logger, MountPresenceWidgetOptions, NOOP_RATE_LIMITER, type NodeClientConfig, OauthErrorCode, OauthPaymentEventsSubscriber, OauthPaymentEventsSubscriberLifecycle, OauthPaymentEventsSubscriberOptions, OauthPaymentWebhookBody, type OauthScope, PkcePair, PlaySessionGameStatus, PresenceStatus, PresenceWidgetHandle, RateLimitOptions, RateLimiter, RequestOptions, SERVER_RATE_LIMIT_MAX_MUTATING, SERVER_RATE_LIMIT_MAX_READ, SERVER_RATE_LIMIT_WINDOW_MS, type SdkBaseConfig, TRON_WS_CLOSE_CODES, type TokenSet, type TokenStore, TransportContext, TronError, TronNodeClient, TronOauthError, TronWsCloseCode, TronWsCloseError, VerifyWebhookFailure, VerifyWebhookInput, VerifyWebhookResult, VerifyWebhookSuccess, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_TIMESTAMP_HEADER, acceptDeveloperInvite, addAdmin, addAppealBlacklist, addReaction, approveTronCashout, assertSecureIssuer, batchThreadDmKeys, bindReferral, buildAuthorizeUrl, cancelFriendRequest, cancelPot, charge, chargeTronDirect, chargeTronPot, completePaymentIntent, confirmPlaySession, consolidateDeveloperAppWallet, createAppTokenCache, createConsoleLogger, createDelegation, createDeveloperApiKey, createDeveloperApp, createDirectThread, createInMemoryTokenStore, createInflightDedup, createNoopLogger, createRateLimiter, createReferralCode, createTronCashout, createTronConnectOnboarding, createTronDeposit, createTronTransfer, decideFriendRequest, declineDeveloperInvite, defaultEndpoints, deleteAppPageBanner, deleteAppPageThumbnail, deleteAppPageThumbnailVideo, deleteAvatar, deleteDelegation, deleteDeveloperApp, deleteDeveloperAppLogo, deleteDeveloperProfileLogo, deleteDeveloperRequestLogo, deleteGameReviewReply, deleteMessage, deleteMyGameReview, deleteThread, deleteThreadLogo, denyPaymentIntent, distributePot, distributeTronPot, editMessage, endPlaySession, exchangeAuthorizationCode, fetchAuthorizationServerMetadata, fetchUserInfo, fileAppeal, fileAppealPotLeg, followUser, generatePkce, generateState, getActivity, getActivityGroup, getAdminAppealRoom, getAppFeeConfig, getAppPage, getAppPageChanges, getAppealRoom, getDelegation, getDeveloperAppActivity, getDeveloperAppBalances, getDeveloperAppEarnings, getDeveloperAppOverview, getDeveloperAppPage, getDeveloperAppPlaytime, getDeveloperAppTronBalance, getDeveloperAppWallets, getDeveloperPaymentAppeals, getDeveloperPaymentPendingDeposits, getDeveloperStatus, getDeveloperTronBalanceSummary, getDmKeyBackupStatus, getIntentStatus, getLibrary, getMoonpayAvailability, getMyDmKey, getMyGameReview, getOutstanding, getPaymentChains, getPaymentHistory, getPaymentIntent, getPaymentLimits, getPaymentPrice, getPlatformFees, getPlaytime, getPlaytimeTimeseries, getPublicProfile, getReferral, getThreadDmKey, getTronBalance, getTronGameBalance, heartbeatPlaySession, hideAppPage, hideThread, inviteDeveloperAppParticipant, inviteParticipants, leaveThread, listActivePlayers, listAdmins, listAppPages, listAppealBlacklist, listAppealQueue, listAudit, listDeveloperApiKeys, listDeveloperAppContentReports, listDeveloperAppParticipants, listDeveloperAppReviews, listDeveloperInvites, listDeveloperRequests, listDevelopers, listFriends, listGameReviews, listInventory, listInventoryForApp, listNotifications, listPaymentAuthorizations, listSocials, listThreadMessages, listThreads, listTronCashoutQueue, listTronCashouts, listTronLedger, listUsers, listWalletManager, listWallets, markAllNotificationsRead, markThreadRead, mintClientCredentialsToken, mintMoonpayBuyUrl, mintMoonpaySellUrl, mountPresenceWidget, oauthPaymentWebhookBodySchema, parseJson, pinThread, postAdminAppealRoomMessage, postAppealRoomMessage, previewReferral, provisionDeveloperAppWallet, publishDmKey, refreshAccessToken, registerOauthClient, rejectTronCashout, removeAdmin, removeAppealBlacklist, removeParticipant, removeReaction, replyToGameReview, requestDeveloperAppProduction, requestMint, requestPayout, resolveAppeal, reviewAppPage, reviewAppPageChanges, reviewDeveloperRequest, revokeDeveloperApiKey, revokeDeveloperAppParticipant, revokePaymentAuthorization, revokeToken, rotateDeveloperAppKey, rotateDeveloperAppPaymentWebhookSecret, rotateProcessorTreasury, searchGiphy, searchUsers, send, sendFriendRequest, sendJson, sendMessage, sendPresenceHeartbeat, setProcessorWhitelist, setVaultOperator, setVaultPause, setVaultWithdrawLockDefault, setVaultWithdrawLockOverride, setupDmKeyBackup, sha256Base64Url, signPaymentIntent, startOauthPaymentEventsSubscriber, submitAppContentReport, submitAppPageForReview, submitDeveloperRequest, toTokenSet, unfollowUser, unhideAppPage, unlockDmKeyBackup, unpinThread, unpublishAppPage, updateAdminRole, updateAppFeeConfig, updateAppPage, updateDeveloperApp, updateDeveloperAppAutoSweep, updateDeveloperAppContentReportStatus, updateDeveloperProfile, updateNotification, updateParticipantRole, updatePaymentAuthorization, updatePlatformFees, updateProfile, updateThreadSettings, updateUserBan, updateWalletLabel, uploadAdminAppealRoomAttachment, uploadAppPageBanner, uploadAppPageGallery, uploadAppPageThumbnail, uploadAppPageThumbnailVideo, uploadAppealRoomAttachment, uploadAttachment, uploadAvatar, uploadDeveloperAppLogo, uploadDeveloperProfileLogo, uploadDeveloperRequestLogo, uploadMultipart, uploadThreadLogo, upsertMyGameReview, verifyWebhook, withdrawDeveloperAppWallet };
4599
+ export { AppTokenCache, AuthorizeUrl, type BrowserClientConfig, BuildAuthorizeUrlInput, ChargeResult, type FetchLike, GameHalfCredentials, HttpsGuardOptions, InflightDedup, InventoryUpdateEvent, type Logger, MountPresenceWidgetOptions, NOOP_RATE_LIMITER, type NodeClientConfig, OauthErrorCode, OauthInventoryEventsSubscriber, OauthInventoryEventsSubscriberLifecycle, OauthInventoryEventsSubscriberOptions, OauthPaymentEventsSubscriber, OauthPaymentEventsSubscriberLifecycle, OauthPaymentEventsSubscriberOptions, OauthPaymentWebhookBody, type OauthScope, PkcePair, PlaySessionGameStatus, PresenceStatus, PresenceWidgetHandle, RateLimitOptions, RateLimiter, RequestOptions, SERVER_RATE_LIMIT_MAX_MUTATING, SERVER_RATE_LIMIT_MAX_READ, SERVER_RATE_LIMIT_WINDOW_MS, type SdkBaseConfig, TRON_WS_CLOSE_CODES, type TokenSet, type TokenStore, TransportContext, TronError, TronNodeClient, TronOauthError, TronWsCloseCode, TronWsCloseError, VerifyWebhookFailure, VerifyWebhookInput, VerifyWebhookResult, VerifyWebhookSuccess, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_TIMESTAMP_HEADER, acceptDeveloperInvite, addAdmin, addAppealBlacklist, addReaction, approveTronCashout, assertSecureIssuer, batchThreadDmKeys, bindReferral, buildAuthorizeUrl, cancelFriendRequest, cancelPot, charge, chargeTronDirect, chargeTronPot, commentOnGameReview, completePaymentIntent, confirmPlaySession, consolidateDeveloperAppWallet, createAppTokenCache, createConsoleLogger, createDelegation, createDeveloperApiKey, createDeveloperApp, createDeveloperAppMintPermit, createDeveloperVaultPermit, createDeveloperWithdrawPermit, createDirectThread, createInMemoryTokenStore, createInflightDedup, createNoopLogger, createRateLimiter, createReferralCode, createTronCashout, createTronConnectOnboarding, createTronDeposit, createTronTransfer, createTronTransferChallenge, decideFriendRequest, declineDeveloperInvite, defaultEndpoints, deleteAppPageBanner, deleteAppPageThumbnail, deleteAppPageThumbnailVideo, deleteAvatar, deleteDelegation, deleteDeveloperApp, deleteDeveloperAppLogo, deleteDeveloperProfileLogo, deleteDeveloperRequestLogo, deleteGameReviewComment, deleteGameReviewReply, deleteMessage, deleteMyGameReview, deleteThread, deleteThreadLogo, denyPaymentIntent, distributePot, distributeTronPot, editMessage, endPlaySession, exchangeAuthorizationCode, executeNftTransfer, fetchAuthorizationServerMetadata, fetchUserInfo, fileAppeal, fileAppealPotLeg, followUser, forceWithdrawVaultCustody, generatePkce, generateState, getActivity, getActivityGroup, getAdminAppealRoom, getAppFeeConfig, getAppPage, getAppPageChanges, getAppealRoom, getDelegation, getDeveloperAppActivity, getDeveloperAppBalances, getDeveloperAppEarnings, getDeveloperAppInventoryItemHolders, getDeveloperAppOverview, getDeveloperAppPage, getDeveloperAppPlaytime, getDeveloperAppTronBalance, getDeveloperAppWallets, getDeveloperPaymentAppeals, getDeveloperPaymentPendingDeposits, getDeveloperStatus, getDeveloperTronBalanceSummary, getDmKeyBackupStatus, getIntentStatus, getLibrary, getMoonpayAvailability, getMyDmKey, getMyGameReview, getMyGameReviewReactions, getOutstanding, getPaymentChains, getPaymentHistory, getPaymentIntent, getPaymentLimits, getPaymentPrice, getPlatformFees, getPlaytime, getPlaytimeTimeseries, getPublicProfile, getReferral, getThreadDmKey, getTronBalance, getTronGameBalance, getTronSecurity, heartbeatPlaySession, hideAppPage, hideThread, inventoryUpdateEventSchema, inviteDeveloperAppParticipant, inviteParticipants, leaveThread, listActivePlayers, listAdmins, listAppPages, listAppealBlacklist, listAppealQueue, listAudit, listDeveloperApiKeys, listDeveloperAppContentReports, listDeveloperAppInventoryCollections, listDeveloperAppInventoryItems, listDeveloperAppParticipants, listDeveloperAppReviews, listDeveloperInvites, listDeveloperRequests, listDevelopers, listFriends, listGameReviewComments, listGameReviews, listInventory, listInventoryForApp, listInventoryMintPermits, listInventoryVaultPermits, listInventoryVaulted, listNotifications, listOauthInventoryVaulted, listPaymentAuthorizations, listSocials, listThreadMessages, listThreads, listTronCashoutQueue, listTronCashouts, listTronLedger, listUsers, listWalletManager, listWallets, markAllNotificationsRead, markThreadRead, mintClientCredentialsToken, mintMoonpayBuyUrl, mintMoonpaySellUrl, mountPresenceWidget, oauthPaymentWebhookBodySchema, parseJson, pinThread, postAdminAppealRoomMessage, postAppealRoomMessage, previewReferral, provisionDeveloperAppWallet, publishDmKey, quoteDeveloperAppInventoryRegistration, quoteNftTransfer, quoteRelayedVaultPermit, redeemInventoryMintPermit, refreshAccessToken, registerDeveloperAppInventoryItem, registerOauthClient, rejectTronCashout, removeAdmin, removeAppealBlacklist, removeFriend, removeParticipant, removeReaction, replyToGameReview, requestDeveloperAppProduction, requestMint, requestPayout, resolveAppeal, reviewAppPage, reviewAppPageChanges, reviewDeveloperRequest, revokeDeveloperApiKey, revokeDeveloperAppParticipant, revokePaymentAuthorization, revokeToken, rotateDeveloperAppKey, rotateDeveloperAppPaymentWebhookSecret, rotateProcessorTreasury, searchGiphy, searchUsers, send, sendFriendRequest, sendJson, sendMessage, sendPresenceHeartbeat, setMyGameReviewReaction, setProcessorWhitelist, setTronSecurity, setVaultOperator, setVaultPause, setVaultWithdrawLockDefault, setVaultWithdrawLockOverride, setupDmKeyBackup, sha256Base64Url, signInventoryVaultPermit, signPaymentIntent, startOauthInventoryEventsSubscriber, startOauthPaymentEventsSubscriber, submitAppContentReport, submitAppPageForReview, submitDeveloperRequest, submitRelayedVaultPermit, tipGameReview, toTokenSet, unfollowUser, unhideAppPage, unlockDmKeyBackup, unpinThread, unpublishAppPage, updateAdminRole, updateAppFeeConfig, updateAppPage, updateDeveloperApp, updateDeveloperAppAutoSweep, updateDeveloperAppContentReportStatus, updateDeveloperProfile, updateNotification, updateParticipantRole, updatePaymentAuthorization, updatePlatformFees, updateProfile, updateThreadSettings, updateUserBan, updateWalletLabel, uploadAdminAppealRoomAttachment, uploadAppPageBanner, uploadAppPageGallery, uploadAppPageThumbnail, uploadAppPageThumbnailVideo, uploadAppealRoomAttachment, uploadAttachment, uploadAvatar, uploadDeveloperAppInventoryItemBanner, uploadDeveloperAppInventoryItemImage, uploadDeveloperAppLogo, uploadDeveloperProfileLogo, uploadDeveloperRequestLogo, uploadMultipart, uploadThreadLogo, upsertMyGameReview, verifyWebhook, withdrawDeveloperAppWallet };