@xoxno/sdk-js 1.0.230 → 1.0.231

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.
@@ -1,8 +1,9 @@
1
1
  /** Typed Stellar lending reads. Configure the API deployment with XOXNOClient.apiUrl.
2
2
  * These cached HTTP reads do not simulate transactions or authorize spending.
3
3
  */
4
- import type { OurRequestInit, XOXNOClient } from '../../utils/api.js';
4
+ import { type OurRequestInit, type XOXNOClient } from '../../utils/api.js';
5
5
  import type * as Api from './lending-api-types.js';
6
+ import type { UserTokenInventoryResponseDto } from '@xoxno/types';
6
7
  import type { StellarLendingMarketSide, StellarLendingHoldersSide, StellarMarketGraphQuery, StellarReservesParams, StellarActivityQuery, StellarActivityPageQuery, StellarGovernanceQuery, StellarPositionsQuery, StellarRevenueQuery, StellarFeeRevenueQuery, StellarParticipantsQuery, StellarLiquidationsQuery, StellarLiquidationsLeaderboardQuery, StellarVolumeQuery, StellarDistributionQuery, StellarRateSpreadQuery } from './lending-read-types.js';
7
8
  /** Load assets, hubs, spokes, reserves and keyed reserve details in one response.
8
9
  * @category Stellar lending reads
@@ -56,7 +57,18 @@ export declare const getStellarUserPositions: (client: XOXNOClient, owner: strin
56
57
  * @category Stellar lending reads
57
58
  */
58
59
  export declare const getStellarAccountPositions: (client: XOXNOClient, accountId: string, init?: OurRequestInit) => Promise<Api.AccountPositionsDto>;
59
- /** Read exact token base-unit holdings for a G or C wallet. Holdings may exceed spendable funds. Requires the API release exposing this route; older deployments return 404.
60
+ /** Read a G or C wallet's token holdings from `/user/{owner}/token-inventory`:
61
+ * Horizon balances (native XLM and classic assets, keyed by their SAC id) plus
62
+ * indexed Soroban tokens, cached for about 10 seconds. Each token's
63
+ * `identifier` is its contract id and `balance` is base units as a decimal
64
+ * string. Tokens without a balance or trustline are absent.
65
+ * @category Stellar lending reads
66
+ */
67
+ export declare const getStellarWalletTokens: (client: XOXNOClient, owner: string, init?: OurRequestInit) => Promise<UserTokenInventoryResponseDto>;
68
+ /** Read exact token base-unit holdings of one asset for a G or C wallet, from
69
+ * {@link getStellarWalletTokens}. An asset the wallet does not hold returns
70
+ * `amount: '0'`, with decimals read from the lending asset. Holdings may exceed
71
+ * spendable funds (reserves, liabilities).
60
72
  * @category Stellar lending reads
61
73
  */
62
74
  export declare const getStellarWalletBalance: (client: XOXNOClient, owner: string, asset: string, init?: OurRequestInit) => Promise<Api.StellarWalletBalanceDto>;
@@ -218,6 +230,8 @@ export declare const stellarLendingRead: (client: XOXNOClient) => {
218
230
  userPositions: (owner: string, init?: OurRequestInit) => Promise<Api.AccountPositionsDto>;
219
231
  /** {@inheritDoc getStellarAccountPositions} */
220
232
  accountPositions: (accountId: string, init?: OurRequestInit) => Promise<Api.AccountPositionsDto>;
233
+ /** {@inheritDoc getStellarWalletTokens} */
234
+ walletTokens: (owner: string, init?: OurRequestInit) => Promise<UserTokenInventoryResponseDto>;
221
235
  /** {@inheritDoc getStellarWalletBalance} */
222
236
  walletBalance: (owner: string, asset: string, init?: OurRequestInit) => Promise<Api.StellarWalletBalanceDto>;
223
237
  /** {@inheritDoc getStellarAssetPage} */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xoxno/sdk-js",
3
- "version": "1.0.230",
3
+ "version": "1.0.231",
4
4
  "description": "The SDK to interact with the XOXNO Protocol!",
5
5
  "type": "module",
6
6
  "exports": {
@@ -140,7 +140,7 @@
140
140
  "dependencies": {
141
141
  "@multiversx/sdk-core": "^15.3.2",
142
142
  "@multiversx/sdk-network-providers": "^2.9.3",
143
- "@xoxno/types": "1.0.500",
143
+ "@xoxno/types": "1.0.501",
144
144
  "buffer": "^6.0.3"
145
145
  },
146
146
  "peerDependencies": {