@coinlist-co/react 0.12.2-rc.0fda52c → 0.12.2-rc.5f2ca48

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.
Files changed (32) hide show
  1. package/dist/{chunk-STAHYDLY.js → chunk-6NCNF5GF.js} +2 -2
  2. package/dist/{chunk-KRA6EM2L.js → chunk-VUIDJYHY.js} +18 -3
  3. package/dist/chunk-VUIDJYHY.js.map +1 -0
  4. package/dist/{chunk-BNMF2HMW.js → chunk-XCRU3YE2.js} +628 -402
  5. package/dist/chunk-XCRU3YE2.js.map +1 -0
  6. package/dist/client/index.cjs +605 -160
  7. package/dist/client/index.cjs.map +1 -1
  8. package/dist/client/index.d.cts +271 -29
  9. package/dist/client/index.d.ts +271 -29
  10. package/dist/client/index.js +294 -21
  11. package/dist/client/index.js.map +1 -1
  12. package/dist/server/index.cjs +216 -62
  13. package/dist/server/index.cjs.map +1 -1
  14. package/dist/server/index.d.cts +10 -2
  15. package/dist/server/index.d.ts +10 -2
  16. package/dist/server/index.js +4 -2
  17. package/dist/server/index.js.map +1 -1
  18. package/dist/{time-B5YOQxuh.d.ts → time-CTuVDTx6.d.ts} +1 -1
  19. package/dist/{time-BY3apBpc.d.cts → time-Dv1dejVB.d.cts} +1 -1
  20. package/dist/{token-registry-snapshot-DyjrA32p.d.cts → token-registry-snapshot-CX5YiSHp.d.cts} +9 -7
  21. package/dist/{token-registry-snapshot-C1NxdBmF.d.ts → token-registry-snapshot-CzJd2VYU.d.ts} +9 -7
  22. package/dist/{tokens-namespace-BJfFeowE.d.cts → tokens-namespace-CcvHrw-k.d.cts} +462 -20
  23. package/dist/{tokens-namespace-BJfFeowE.d.ts → tokens-namespace-CcvHrw-k.d.ts} +462 -20
  24. package/dist/universal/index.cjs +568 -316
  25. package/dist/universal/index.cjs.map +1 -1
  26. package/dist/universal/index.d.cts +38 -6
  27. package/dist/universal/index.d.ts +38 -6
  28. package/dist/universal/index.js +22 -2
  29. package/package.json +1 -1
  30. package/dist/chunk-BNMF2HMW.js.map +0 -1
  31. package/dist/chunk-KRA6EM2L.js.map +0 -1
  32. /package/dist/{chunk-STAHYDLY.js.map → chunk-6NCNF5GF.js.map} +0 -0
@@ -412,7 +412,7 @@ type PinoLoggerOptions = {
412
412
  * - an operation, a flow, a hook - is a {@link LogBinding} and appears as its
413
413
  * own field.
414
414
  */
415
- type LogScope = 'HTTP' | 'RPC' | 'AUTH' | 'OFFERS' | 'REQUIREMENTS' | 'WALLETS' | 'ERC20' | 'TOKEN_SALE' | 'SUPERSTATE' | 'ONDO' | 'TOKENS' | 'SUPPORT' | 'HOOKS';
415
+ type LogScope = 'HTTP' | 'RPC' | 'AUTH' | 'OFFERS' | 'REQUIREMENTS' | 'WALLETS' | 'ERC20' | 'TOKEN_SALE' | 'SUPERSTATE' | 'ONDO' | 'CENTRIFUGE' | 'TOKENS' | 'SUPPORT' | 'HOOKS';
416
416
  /**
417
417
  * Correlates every line one logical request produces. The first attempt, each
418
418
  * retry, and the re-send after a session renewal all carry the same id, so a
@@ -1267,13 +1267,13 @@ type InternalDebugEvent = {
1267
1267
  * union makes a `switch` over it exhaustive: adding a provider without
1268
1268
  * handling it becomes a compile error.
1269
1269
  */
1270
- type OfferTypeDto = 'coinlist::token_sale' | 'superstate::swap' | 'ondo::swap';
1270
+ type OfferTypeDto = 'coinlist::token_sale' | 'superstate::swap' | 'ondo::swap' | 'centrifuge::vault';
1271
1271
  /**
1272
1272
  * One variant per {@link OfferTypeDto}, mirroring frontline#1365, which keys
1273
1273
  * `GET /v1/offers` on `type`. Read `type` first: it decides which of the
1274
1274
  * fields below mean anything.
1275
1275
  */
1276
- type OfferDto = CoinListTokenSaleOfferDto | SuperstateSwapOfferDto | OndoSwapOfferDto;
1276
+ type OfferDto = CoinListTokenSaleOfferDto | SuperstateSwapOfferDto | OndoSwapOfferDto | CentrifugeVaultOfferDto;
1277
1277
  type OfferBaseDto = {
1278
1278
  id: string;
1279
1279
  slug: string;
@@ -1290,15 +1290,16 @@ type OfferEditorialDto = {
1290
1290
  starts_at: string;
1291
1291
  };
1292
1292
  /**
1293
- * What an Ondo swap sends in place of {@link OfferEditorialDto}. It trades
1294
- * continuously and runs no campaign, so the keys arrive as `null` and carry
1295
- * nothing. Declared so a fixture can describe the real payload; no `fromDto`
1296
- * reads them.
1293
+ * What an Ondo swap or a Centrifuge vault sends in place of
1294
+ * {@link OfferEditorialDto}. Neither runs a campaign, so the keys arrive as
1295
+ * `null` and carry nothing, and the backend may stop sending them at all.
1296
+ * Declared so a fixture can describe the real payload; no `fromDto` reads
1297
+ * them.
1297
1298
  */
1298
1299
  type OfferNoEditorialDto = {
1299
- tagline: null;
1300
- banner_url: null;
1301
- starts_at: null;
1300
+ tagline?: null;
1301
+ banner_url?: null;
1302
+ starts_at?: null;
1302
1303
  };
1303
1304
  type CoinListTokenSaleOfferDto = OfferBaseDto & OfferEditorialDto & {
1304
1305
  type: 'coinlist::token_sale';
@@ -1314,8 +1315,17 @@ type OndoSwapOfferDto = OfferBaseDto & OfferNoEditorialDto & {
1314
1315
  /** Publishing a swap does not require anyone to upload artwork for it. */
1315
1316
  logo_url: string | null;
1316
1317
  };
1318
+ type CentrifugeVaultOfferDto = OfferBaseDto & OfferNoEditorialDto & {
1319
+ type: 'centrifuge::vault';
1320
+ /** Publishing a vault does not require anyone to upload artwork for it. */
1321
+ logo_url: string | null;
1322
+ };
1317
1323
  type OfferTokenDto = {
1318
- role: 'funding' | 'distribution' | 'swap';
1324
+ /**
1325
+ * `vault` is the share token a `centrifuge::vault` offer issues for
1326
+ * deposits, as `swap` is the token a swap offer trades into.
1327
+ */
1328
+ role: 'funding' | 'distribution' | 'swap' | 'vault';
1319
1329
  chain: string;
1320
1330
  address: string;
1321
1331
  };
@@ -1346,10 +1356,16 @@ type OndoSwapOffer = OfferBase & {
1346
1356
  /** Null when nobody has uploaded artwork: a swap publishes without it. */
1347
1357
  logoUrl: string | null;
1348
1358
  };
1359
+ type CentrifugeVaultOffer = OfferBase & {
1360
+ type: 'centrifuge::vault';
1361
+ /** Null when nobody has uploaded artwork: a vault publishes without it. */
1362
+ logoUrl: string | null;
1363
+ };
1349
1364
  /**
1350
1365
  * A curated sale window and the hand-authored copy that goes with it. Every
1351
1366
  * variant that runs such a campaign carries all three, validated; an Ondo swap
1352
- * trades continuously, runs none, and carries none.
1367
+ * trades continuously and a Centrifuge vault takes deposits continuously, so
1368
+ * neither runs one and neither carries any.
1353
1369
  */
1354
1370
  type OfferEditorial = {
1355
1371
  tagline: string;
@@ -1369,7 +1385,7 @@ declare const OfferEditorial: {
1369
1385
  * `type` before reading anything beyond {@link OfferBase} - an Ondo swap has
1370
1386
  * no `startsAt` to read, and the compiler says so.
1371
1387
  */
1372
- type Offer = CoinListTokenSaleOffer | SuperstateSwapOffer | OndoSwapOffer;
1388
+ type Offer = CoinListTokenSaleOffer | SuperstateSwapOffer | OndoSwapOffer | CentrifugeVaultOffer;
1373
1389
  declare const Offer: {
1374
1390
  fromDto: (dto: OfferDto) => Offer;
1375
1391
  /**
@@ -1382,7 +1398,11 @@ declare const Offer: {
1382
1398
  */
1383
1399
  listFromDto: (dtos: OfferDto[]) => Offer[];
1384
1400
  };
1385
- type TokenRole = 'funding' | 'distribution' | 'swap';
1401
+ /**
1402
+ * `vault` is the share token a `centrifuge::vault` offer issues for deposits,
1403
+ * as `swap` is the token a swap offer trades into.
1404
+ */
1405
+ type TokenRole = 'funding' | 'distribution' | 'swap' | 'vault';
1386
1406
  type OfferToken = {
1387
1407
  role: TokenRole;
1388
1408
  chain: Chain;
@@ -1497,16 +1517,16 @@ type CreateParticipationDto = {
1497
1517
  * One variant per `OfferTypeDto`, the same split as `OfferDto` with what
1498
1518
  * `GET /v1/offers/:id` adds on top. Read `type` first.
1499
1519
  */
1500
- type OfferDetailDto = CoinListTokenSaleOfferDetailDto | SuperstateSwapOfferDetailDto | OndoSwapOfferDetailDto;
1501
- type CoinListTokenSaleOfferDetailDto = OfferDetailBaseDto & OfferEditorialDto & OfferDetailNoSwapContractsDto & {
1520
+ type OfferDetailDto = CoinListTokenSaleOfferDetailDto | SuperstateSwapOfferDetailDto | OndoSwapOfferDetailDto | CentrifugeVaultOfferDetailDto;
1521
+ type CoinListTokenSaleOfferDetailDto = OfferDetailBaseDto & OfferEditorialDto & OfferDetailNoSwapContractsDto & OfferDetailNoVaultContractsDto & {
1502
1522
  type: 'coinlist::token_sale';
1503
1523
  logo_url: string;
1504
1524
  };
1505
- type SuperstateSwapOfferDetailDto = OfferDetailBaseDto & OfferEditorialDto & OfferDetailNoSwapContractsDto & {
1525
+ type SuperstateSwapOfferDetailDto = OfferDetailBaseDto & OfferEditorialDto & OfferDetailNoSwapContractsDto & OfferDetailNoVaultContractsDto & {
1506
1526
  type: 'superstate::swap';
1507
1527
  logo_url: string | null;
1508
1528
  };
1509
- type OndoSwapOfferDetailDto = OfferDetailBaseDto & OfferNoEditorialDto & {
1529
+ type OndoSwapOfferDetailDto = OfferDetailBaseDto & OfferNoEditorialDto & OfferDetailNoVaultContractsDto & {
1510
1530
  type: 'ondo::swap';
1511
1531
  logo_url: string | null;
1512
1532
  /**
@@ -1515,6 +1535,19 @@ type OndoSwapOfferDetailDto = OfferDetailBaseDto & OfferNoEditorialDto & {
1515
1535
  */
1516
1536
  swap_contracts: OfferDetailSwapContractDto[];
1517
1537
  };
1538
+ type CentrifugeVaultOfferDetailDto = OfferDetailBaseDto & OfferNoEditorialDto & OfferDetailNoSwapContractsDto & {
1539
+ type: 'centrifuge::vault';
1540
+ logo_url: string | null;
1541
+ /**
1542
+ * Every chain this vault takes deposits on, with the CoinList proxy each
1543
+ * request goes through. `[]` is an answer - "deposits nowhere", which is
1544
+ * every vault until a proxy is deployed - and a missing key is not.
1545
+ */
1546
+ vault_contracts: OfferDetailVaultContractDto[];
1547
+ };
1548
+ type OfferDetailNoVaultContractsDto = {
1549
+ vault_contracts?: OfferDetailVaultContractDto[];
1550
+ };
1518
1551
  /**
1519
1552
  * An offer that does not settle through a CoinList swap contract sends `[]`
1520
1553
  * or no key at all, and either way there is nothing to read. Declared so a
@@ -1581,6 +1614,10 @@ type OfferDetailSwapContractDto = {
1581
1614
  chain: string;
1582
1615
  address: string;
1583
1616
  };
1617
+ type OfferDetailVaultContractDto = {
1618
+ chain: string;
1619
+ address: string;
1620
+ };
1584
1621
 
1585
1622
  type Ticker = Newtype<string, 'Ticker'>;
1586
1623
  declare const Ticker: (value: string) => Ticker;
@@ -1618,6 +1655,16 @@ type OndoSwapOfferDetail = OfferDetailBase & {
1618
1655
  */
1619
1656
  swapContracts: OfferSwapContract[];
1620
1657
  };
1658
+ type CentrifugeVaultOfferDetail = OfferDetailBase & {
1659
+ type: 'centrifuge::vault';
1660
+ /** Null when nobody has uploaded artwork: a vault publishes without it. */
1661
+ logoUrl: string | null;
1662
+ /**
1663
+ * Every chain this vault takes deposits on, with the CoinList proxy each
1664
+ * request goes through. Empty means it takes deposits nowhere yet.
1665
+ */
1666
+ vaultContracts: OfferVaultContract[];
1667
+ };
1621
1668
  type OfferDetailBase = {
1622
1669
  id: OfferId;
1623
1670
  slug: OfferSlug;
@@ -1695,13 +1742,38 @@ type OfferSwapContract = {
1695
1742
  declare const OfferSwapContract: {
1696
1743
  fromDto: (dto: OfferDetailSwapContractDto) => OfferSwapContract;
1697
1744
  };
1745
+ /**
1746
+ * A chain a Centrifuge vault takes deposits on, with the CoinList proxy the
1747
+ * request goes through. Not a token, so the token registry knows nothing about
1748
+ * it: it is the spender the user approves the funding token to, and the `to`
1749
+ * the buy and claim transactions are sent to.
1750
+ *
1751
+ * Its own type rather than an {@link OfferSwapContract}, although the shape is
1752
+ * the same, because the meaning is not: a swap contract serves every Ondo
1753
+ * asset on its chain, while a proxy belongs to one offer on one chain, so the
1754
+ * same chain carries a different address on every vault.
1755
+ */
1756
+ type OfferVaultContract = {
1757
+ chain: Chain;
1758
+ address: EvmContractAddress;
1759
+ };
1760
+ declare const OfferVaultContract: {
1761
+ fromDto: (dto: OfferDetailVaultContractDto) => OfferVaultContract;
1762
+ /**
1763
+ * Drops every proxy on a chain this SDK does not name, as
1764
+ * `OfferToken.listFromDto` does: frontline publishes the full offer-token
1765
+ * chain list, which runs ahead of {@link Chain}, and one unmodelled chain
1766
+ * should not throw away the proxies the SDK can use.
1767
+ */
1768
+ listFromDto: (dtos: OfferDetailVaultContractDto[]) => OfferVaultContract[];
1769
+ };
1698
1770
  /**
1699
1771
  * An offer as `GET /v1/offers/:id` serves it: the same union on `type` as
1700
1772
  * {@link Offer}, each variant carrying only the fields that mean something
1701
1773
  * for it. Narrow on `type` before reading anything beyond
1702
1774
  * {@link OfferDetailBase}.
1703
1775
  */
1704
- type OfferDetail = CoinListTokenSaleOfferDetail | SuperstateSwapOfferDetail | OndoSwapOfferDetail;
1776
+ type OfferDetail = CoinListTokenSaleOfferDetail | SuperstateSwapOfferDetail | OndoSwapOfferDetail | CentrifugeVaultOfferDetail;
1705
1777
  declare const OfferDetail: {
1706
1778
  fromDto: (dto: OfferDetailDto) => OfferDetail;
1707
1779
  };
@@ -2488,6 +2560,17 @@ declare const OndoSellTransaction: {
2488
2560
  */
2489
2561
  interface OndoNamespace {
2490
2562
  getTradingStatus(params: GetOndoTradingStatusParams): Promise<OndoTradingStatus>;
2563
+ /**
2564
+ * An indicative price for `params`' size, from Ondo's live market.
2565
+ *
2566
+ * Ondo refuses to quote while the market is closed or paused, or the asset
2567
+ * is paused or closed for the session - including for about a minute at
2568
+ * every US session change, when `getTradingStatus` may still have reported
2569
+ * the asset tradable. The request then rejects with a 409 carrying
2570
+ * `code: "not_tradable"`; tell it apart from a failure with
2571
+ * {@link isOndoNotTradableError}. Retrying before the market opens fails the
2572
+ * same way.
2573
+ */
2491
2574
  getQuote(params: GetOndoQuoteParams): Promise<OndoQuote>;
2492
2575
  /**
2493
2576
  * Builds a purchase for a specific wallet and deposit: spends an attestation
@@ -3135,6 +3218,365 @@ declare class RequirementsNamespaceImpl implements RequirementsNamespace {
3135
3218
  submitDocument(params: SubmitDocumentParams): Promise<DocumentSubmission>;
3136
3219
  }
3137
3220
 
3221
+ type GetCentrifugeVaultStatusParams = {
3222
+ /** Share token symbol of the vault, e.g. `deJTRSY`. */
3223
+ symbol: AssetSymbol;
3224
+ /**
3225
+ * The chain whose proxy answers. Only chains this offer has a proxy on
3226
+ * are accepted; the offer's `vault_contracts` lists them.
3227
+ */
3228
+ chain: EthereumChain;
3229
+ };
3230
+ type GetCentrifugeVaultQuoteParams = GetCentrifugeVaultStatusParams & {
3231
+ /**
3232
+ * Amount to price, in the base units of the funding token. Must be greater
3233
+ * than zero. No fee is deducted; this product charges none.
3234
+ *
3235
+ * Sized by `amount` alone: the quote is a free read of one spend, not a
3236
+ * dollar figure converted later.
3237
+ */
3238
+ amount: BlockchainAmount;
3239
+ };
3240
+
3241
+ /**
3242
+ * Wire shapes for frontline's `/v1/centrifuge/vault/*` endpoints, as published
3243
+ * in frontline's OpenAPI schema (ENG-1936). Every uint256 crosses as a decimal
3244
+ * string, every price as a decimal string, every timestamp as ISO 8601.
3245
+ *
3246
+ * **A vault deposit does not settle in the transaction that places it.** The
3247
+ * fund fulfils requests on its own epoch, in whole or in part, at a price set
3248
+ * then, and the user claims the resulting shares in a second transaction. So
3249
+ * every share figure before a fill is an estimate.
3250
+ *
3251
+ * The three GETs are free to poll. The two POSTs return calldata to broadcast:
3252
+ * `buy` is signed for one wallet and called once on confirmation, `claim`
3253
+ * collects everything claimable and carries no amount.
3254
+ */
3255
+ /**
3256
+ * Why a deposit cannot be placed right now. A closed set, so a client can
3257
+ * branch on every value. `vault_unlinked` is terminal for the offer's proxy on
3258
+ * that chain; the rest clear on their own or by hand.
3259
+ *
3260
+ * `below_minimum` is the one reason that depends on an amount, so only a quote
3261
+ * can report it - see {@link CentrifugeVaultReasonDto}.
3262
+ */
3263
+ type CentrifugeOrderReasonDto = 'vault_unlinked' | 'vault_halted' | 'proxy_not_permissioned' | 'price_unavailable' | 'below_minimum';
3264
+ /** What a vault status can report: every reason but the amount-dependent one. */
3265
+ type CentrifugeVaultReasonDto = Exclude<CentrifugeOrderReasonDto, 'below_minimum'>;
3266
+ /**
3267
+ * Where a wallet stands on a vault, derived from its amounts rather than
3268
+ * stored. Not a lifecycle: a new request moves any of these back to `pending`
3269
+ * while earlier shares stay claimed.
3270
+ */
3271
+ type CentrifugePositionStatusDto = 'none' | 'pending' | 'partially_filled' | 'filled' | 'claimed';
3272
+ /** `GET /v1/centrifuge/vault/quote?symbol&chain&amount`. Indicative only. */
3273
+ type CentrifugeVaultQuoteDto = {
3274
+ object: 'centrifuge_vault_quote';
3275
+ /** The vault's share token symbol, e.g. `deJTRSY`. */
3276
+ symbol: string;
3277
+ chain: string;
3278
+ /** The amount priced, echoed back, in `spend_input_decimals`. No fee. */
3279
+ spend_input_amount: string;
3280
+ spend_input_decimals: number;
3281
+ /** An estimate, not a floor: the fill can price either side of it. */
3282
+ estimated_shares: string;
3283
+ share_decimals: number;
3284
+ /** Funding token per whole share. Null when the vault has no price. */
3285
+ indicative_price: string | null;
3286
+ /** In `spend_input_decimals`. Null when the offer sets no minimum. */
3287
+ minimum_input_amount: string | null;
3288
+ can_order: boolean;
3289
+ /** Empty exactly when `can_order` is true. */
3290
+ reasons: CentrifugeOrderReasonDto[];
3291
+ };
3292
+ /**
3293
+ * `GET /v1/centrifuge/vault/status?symbol&chain`. The vault's own state, read
3294
+ * from the chain on every call; the gate to poll, because Centrifuge announces
3295
+ * none of these changes.
3296
+ */
3297
+ type CentrifugeVaultStatusDto = {
3298
+ object: 'centrifuge_vault_status';
3299
+ symbol: string;
3300
+ chain: string;
3301
+ /** Centrifuge's vault, read from the proxy. Fixed for the proxy's life. */
3302
+ vault_address: string;
3303
+ /** False is terminal for this proxy: a replacement has to be deployed. */
3304
+ linked: boolean;
3305
+ /** Whether the proxy is on the share token's memberlist. */
3306
+ permissioned: boolean;
3307
+ membership_valid_until: string | null;
3308
+ /** Set by the proxy after a force-cancel; cleared only by hand. */
3309
+ halted: boolean;
3310
+ price_updated_at: string | null;
3311
+ can_order: boolean;
3312
+ reasons: CentrifugeVaultReasonDto[];
3313
+ as_of: string;
3314
+ };
3315
+ /**
3316
+ * What both POSTs return: calldata for the wallet to broadcast verbatim.
3317
+ * Unlike Ondo's, `expires_at` is nullable - a claim carries no signature, so
3318
+ * it is always null there.
3319
+ */
3320
+ type CentrifugeBroadcastDto = {
3321
+ action: 'broadcast_transaction';
3322
+ /** The offer's proxy on the chain. Lower case: compare case-insensitively. */
3323
+ to: string;
3324
+ data: string;
3325
+ expires_at: string | null;
3326
+ };
3327
+ /**
3328
+ * `POST /v1/centrifuge/vault/buy` with `{ symbol, chain, wallet_address,
3329
+ * amount }`. Broadcasting it places a request in the vault's queue and buys
3330
+ * nothing yet.
3331
+ */
3332
+ type CentrifugeVaultBuyDto = CentrifugeBroadcastDto & {
3333
+ /** Exactly what the approval has to cover: no fee comes off it. */
3334
+ spend_input_amount: string;
3335
+ spend_input_decimals: number;
3336
+ /** Not a quantity purchased: the fill prices later. */
3337
+ estimated_shares: string;
3338
+ share_decimals: number;
3339
+ };
3340
+ /**
3341
+ * `GET /v1/centrifuge/vault/position?symbol&chain&wallet_address`. The six
3342
+ * amounts are independent: a wallet can hold a pending request, a claimable
3343
+ * balance and claimed shares at once. There is no per-fulfilment breakdown;
3344
+ * settlement pools every fulfilment into one rate.
3345
+ */
3346
+ type CentrifugeVaultPositionDto = {
3347
+ object: 'centrifuge_vault_position';
3348
+ symbol: string;
3349
+ chain: string;
3350
+ wallet_address: string;
3351
+ status: CentrifugePositionStatusDto;
3352
+ /** Funding token ever requested, in `asset_decimals`. */
3353
+ requested: string;
3354
+ /** Of that, still queued. */
3355
+ pending: string;
3356
+ /** Of that, fulfilled. */
3357
+ filled_assets: string;
3358
+ /** Shares the fulfilments earned, in `share_decimals`. Held by the proxy until claimed. */
3359
+ earned_shares: string;
3360
+ claimed_shares: string;
3361
+ /** Non-zero means the claim endpoint will return calldata. */
3362
+ claimable_shares: string;
3363
+ /** Read from the share token; can exceed `claimed_shares`. */
3364
+ share_balance: string;
3365
+ asset_decimals: number;
3366
+ share_decimals: number;
3367
+ /** Null before the first claim. */
3368
+ average_price: string | null;
3369
+ /** Centrifuge froze the wallet on the share token; blocks claiming. */
3370
+ frozen: boolean;
3371
+ as_of: string;
3372
+ };
3373
+ /**
3374
+ * `POST /v1/centrifuge/vault/claim` with `{ symbol, chain, wallet_address }`.
3375
+ * The wallet named must be the one that broadcasts: the proxy credits the
3376
+ * sender.
3377
+ */
3378
+ type CentrifugeVaultClaimDto = CentrifugeBroadcastDto & {
3379
+ /** A floor: a fill landing before the broadcast raises it. */
3380
+ claimable_shares: string;
3381
+ share_decimals: number;
3382
+ };
3383
+
3384
+ /**
3385
+ * Why a deposit cannot be placed on a vault right now. Kept verbatim from the
3386
+ * wire: frontline publishes it as a closed set for clients to branch on.
3387
+ */
3388
+ type CentrifugeOrderReason = CentrifugeOrderReasonDto;
3389
+ /** The reasons a vault status can report - all but `below_minimum`. */
3390
+ type CentrifugeVaultReason = CentrifugeVaultReasonDto;
3391
+ /**
3392
+ * Where a wallet stands on a vault. Not a lifecycle - see
3393
+ * {@link CentrifugeVaultPosition.status}.
3394
+ */
3395
+ type CentrifugePositionStatus = CentrifugePositionStatusDto;
3396
+ /**
3397
+ * Whether a deposit can be placed, as one union rather than the wire's
3398
+ * `can_order` beside `reasons`: a blocked answer always says why, and an
3399
+ * orderable one has nothing to say. The wire pair can contradict itself; this
3400
+ * cannot, because `fromDto` refuses the payloads that do.
3401
+ */
3402
+ type CentrifugeOrderability<R extends CentrifugeOrderReason> = {
3403
+ type: 'orderable';
3404
+ } | {
3405
+ type: 'blocked';
3406
+ reasons: [R, ...R[]];
3407
+ };
3408
+ /**
3409
+ * What a deposit of a given size would buy, and whether it can be placed.
3410
+ *
3411
+ * **Indicative only.** The price is read from the vault now and the fund
3412
+ * prices the fulfilment on its own epoch, so neither {@link indicativePrice}
3413
+ * nor {@link estimatedShares} is a commitment. Free to poll while the user
3414
+ * sizes a deposit.
3415
+ */
3416
+ type CentrifugeVaultQuote = {
3417
+ chain: EthereumChain;
3418
+ /** The vault's share token symbol, e.g. `deJTRSY`. */
3419
+ symbol: AssetSymbol;
3420
+ /** The amount priced, in the funding token's decimals. No fee is taken. */
3421
+ spendInputAmount: BlockchainAmount;
3422
+ /** Shares at the indicative price, in the share token's decimals. */
3423
+ estimatedShares: BlockchainAmount;
3424
+ /** Funding token per whole share. Null when the vault publishes no price. */
3425
+ indicativePrice: DecimalString | null;
3426
+ /** Null when the offer sets no minimum. Same decimals as the spend. */
3427
+ minimumInputAmount: BlockchainAmount | null;
3428
+ orderability: CentrifugeOrderability<CentrifugeOrderReason>;
3429
+ };
3430
+ declare const CentrifugeVaultQuote: {
3431
+ fromDto: (dto: CentrifugeVaultQuoteDto) => CentrifugeVaultQuote;
3432
+ };
3433
+ /**
3434
+ * A vault's own state, independent of any wallet or amount: the gate to poll.
3435
+ * Centrifuge announces none of these changes, and an unlinked vault leaves the
3436
+ * offer's proxy permanently dead, so a cached answer goes wrong silently.
3437
+ */
3438
+ type CentrifugeVaultStatus = {
3439
+ chain: EthereumChain;
3440
+ symbol: AssetSymbol;
3441
+ /** Centrifuge's vault behind the proxy. Fixed for the proxy's life. */
3442
+ vaultAddress: EvmContractAddress;
3443
+ /**
3444
+ * Whether Centrifuge still links the vault to its pool. False is terminal
3445
+ * for this proxy: no request or claim succeeds until a new one is deployed.
3446
+ */
3447
+ linked: boolean;
3448
+ /**
3449
+ * Whether the proxy is on the share token's memberlist. It holds shares for
3450
+ * every wallet, so one expired entry stops the whole offer.
3451
+ */
3452
+ permissioned: boolean;
3453
+ /** Watch it: {@link permissioned} goes false the moment it passes. */
3454
+ membershipValidUntil: Date | null;
3455
+ /** The proxy halted itself after a force-cancel; cleared only by hand. */
3456
+ halted: boolean;
3457
+ /** A stale value is the signal that a quote's price is old. */
3458
+ priceUpdatedAt: Date | null;
3459
+ orderability: CentrifugeOrderability<CentrifugeVaultReason>;
3460
+ /** When the chain was read: how old everything above is. */
3461
+ asOf: Date;
3462
+ };
3463
+ declare const CentrifugeVaultStatus: {
3464
+ fromDto: (dto: CentrifugeVaultStatusDto) => CentrifugeVaultStatus;
3465
+ };
3466
+ /**
3467
+ * What both vault transactions share: calldata to broadcast verbatim, and the
3468
+ * deadline on it.
3469
+ */
3470
+ type CentrifugeVaultTransactionCore = {
3471
+ /** The `to` is the offer's proxy: the spender the deposit was approved to. */
3472
+ tx: Tx;
3473
+ /**
3474
+ * When the calldata stops being accepted, or null when it carries no
3475
+ * deadline - always the case for a claim, which nobody signs.
3476
+ */
3477
+ expiresAt: Date | null;
3478
+ };
3479
+ /**
3480
+ * A signed deposit request, ready to broadcast.
3481
+ *
3482
+ * **Broadcasting it buys nothing yet.** It places a request in the vault's
3483
+ * queue; the fund fulfils it later at a price set then, and the user comes
3484
+ * back to claim. {@link estimatedShares} is therefore never a quantity
3485
+ * purchased. Single-use: built once on confirmation, never on a timer.
3486
+ */
3487
+ type CentrifugeVaultBuyTransaction = CentrifugeVaultTransactionCore & {
3488
+ /** Exactly what the approval has to cover: no fee comes off it. */
3489
+ spendInputAmount: BlockchainAmount;
3490
+ /** At the price read when the calldata was built. An estimate, not a floor. */
3491
+ estimatedShares: BlockchainAmount;
3492
+ };
3493
+ declare const CentrifugeVaultBuyTransaction: {
3494
+ fromDto: (dto: CentrifugeVaultBuyDto) => CentrifugeVaultBuyTransaction;
3495
+ };
3496
+ /**
3497
+ * The claim that moves fulfilled shares from the proxy to the wallet: the
3498
+ * second transaction every vault purchase needs. The wallet that broadcasts it
3499
+ * is the one credited.
3500
+ */
3501
+ type CentrifugeVaultClaimTransaction = CentrifugeVaultTransactionCore & {
3502
+ /**
3503
+ * Read when the calldata was built. A floor: a fill landing before the
3504
+ * broadcast raises it, and the claim still collects everything.
3505
+ */
3506
+ claimableShares: BlockchainAmount;
3507
+ };
3508
+ declare const CentrifugeVaultClaimTransaction: {
3509
+ fromDto: (dto: CentrifugeVaultClaimDto) => CentrifugeVaultClaimTransaction;
3510
+ };
3511
+ /**
3512
+ * One wallet's standing on one vault: what it put in, what has settled, and
3513
+ * what it can claim. The endpoint a returning user lands on, and the one that
3514
+ * says whether to offer the claim.
3515
+ *
3516
+ * The amounts are independent of each other: each piece of a request settles
3517
+ * and is claimed on its own, so a wallet can be pending, claimable and claimed
3518
+ * at once. There is no per-fulfilment breakdown; settlement pools every
3519
+ * fulfilment into one {@link averagePrice}.
3520
+ */
3521
+ type CentrifugeVaultPosition = {
3522
+ chain: EthereumChain;
3523
+ symbol: AssetSymbol;
3524
+ walletAddress: EvmWalletAddress;
3525
+ /**
3526
+ * Derived by frontline from the amounts. Not a lifecycle: a new request
3527
+ * moves it back to `pending` while earlier shares stay claimed.
3528
+ */
3529
+ status: CentrifugePositionStatus;
3530
+ /** Funding token ever requested. */
3531
+ requested: BlockchainAmount;
3532
+ /** Of {@link requested}, what is still queued. */
3533
+ pending: BlockchainAmount;
3534
+ /** Of {@link requested}, what has been fulfilled. */
3535
+ filledAssets: BlockchainAmount;
3536
+ /** Shares the fulfilments earned. Held by the proxy until claimed. */
3537
+ earnedShares: BlockchainAmount;
3538
+ claimedShares: BlockchainAmount;
3539
+ /** Non-zero means a claim will return calldata. */
3540
+ claimableShares: BlockchainAmount;
3541
+ /**
3542
+ * What the wallet holds on the share token. Can exceed
3543
+ * {@link claimedShares}: shares acquired any other way count here.
3544
+ */
3545
+ shareBalance: BlockchainAmount;
3546
+ /** Pooled rate over everything claimed. Null before the first claim. */
3547
+ averagePrice: DecimalString | null;
3548
+ /** Centrifuge froze this wallet on the share token. Blocks claiming. */
3549
+ frozen: boolean;
3550
+ asOf: Date;
3551
+ };
3552
+ declare const CentrifugeVaultPosition: {
3553
+ fromDto: (dto: CentrifugeVaultPositionDto) => CentrifugeVaultPosition;
3554
+ };
3555
+
3556
+ /**
3557
+ * Centrifuge vault reads: an indicative quote and the vault-wide ordering
3558
+ * gate.
3559
+ *
3560
+ * Both are free to poll - neither spends an attestation, so a client may
3561
+ * call them while the user sizes a deposit. The quote has no expiry: it is
3562
+ * indicative, the fund prices fulfilment later, and a countdown would imply
3563
+ * a commitment the API does not make.
3564
+ *
3565
+ * Every method requires `AuthState === 'logged-in'` and throws
3566
+ * {@link NotAuthenticatedError} otherwise.
3567
+ */
3568
+ interface CentrifugeNamespace {
3569
+ getQuote(params: GetCentrifugeVaultQuoteParams): Promise<CentrifugeVaultQuote>;
3570
+ getVaultStatus(params: GetCentrifugeVaultStatusParams): Promise<CentrifugeVaultStatus>;
3571
+ }
3572
+ declare class CentrifugeNamespaceImpl implements CentrifugeNamespace {
3573
+ private readonly ctx;
3574
+ protected readonly log: InternalLogger;
3575
+ constructor(ctx: UniversalNamespaceContext);
3576
+ getQuote(params: GetCentrifugeVaultQuoteParams): Promise<CentrifugeVaultQuote>;
3577
+ getVaultStatus(params: GetCentrifugeVaultStatusParams): Promise<CentrifugeVaultStatus>;
3578
+ }
3579
+
3138
3580
  /**
3139
3581
  * Reads over CoinList's offers: the catalogue a user can browse, and the full
3140
3582
  * detail of a single offer.
@@ -3350,4 +3792,4 @@ declare class TokensNamespaceImpl implements TokensNamespace {
3350
3792
  list(chain?: EthereumChain): Promise<TokenMetadata[]>;
3351
3793
  }
3352
3794
 
3353
- export { OndoTradingStatus as $, AuthorizationCode as A, BlockchainAmount as B, CodeVerifier as C, TokenMetadata as D, type Erc20Namespace as E, type OfferType as F, type OndoSwapOfferDetail as G, type CoinListTokenSaleOfferDetail as H, type SuperstateSwapOfferDetail as I, Offer as J, RequirementStatusInfo as K, type Logger as L, type RequirementType as M, type RequirementStatusValue as N, OfferId as O, Participation as P, OfferOptionAddress as Q, type RequirementsNamespace as R, type SuperstateSwapNamespace as S, type TokensNamespace as T, type UniversalNamespaceContext as U, RequirementId as V, type WalletError as W, type KycLevelName as X, DocumentSubmission as Y, type WalletChallengeType as Z, type PinoLoggerOptions as _, EthereumChain as a, type GetTokenBalanceParams as a$, AssetDecimals as a0, type BuildOndoBuyParams as a1, type BuildOndoSellParams as a2, OndoQuote as a3, type OndoQuoteSize as a4, type TokenIdentifier as a5, OfferOptionAddressId as a6, TokenLogo as a7, type DebugEvent as a8, type FrontlineEventId as a9, type Newtype as aA, type AllowWalletParams as aB, AllowWalletResponse as aC, Asset as aD, AssetCode as aE, Blockchain as aF, type BuildOndoSwapParamsCore as aG, Chain as aH, ClientId as aI, CodeChallenge as aJ, type CoinListTokenSaleOffer as aK, ConnectExternalWalletParams as aL, type CreateKycTokenParams as aM, CreateParticipationParams as aN, CreateWalletOwnershipChallengeParams as aO, Cursor as aP, type DocumentFormType as aQ, type DocumentSubmissionStatus as aR, type DocumentType as aS, ETHEREUM_CHAINS as aT, Erc20NamespaceImpl as aU, FaqItem as aV, type GetOndoQuoteParams as aW, type GetOndoTradingStatusParams as aX, type GetSwapAuthorizationParams as aY, type GetSwapPreviewParams as aZ, type GetTokenAllowanceParams as a_, HttpError as aa, type HttpResponse as ab, KycToken as ac, type LogBinding as ad, type LogBindings as ae, type LogCause as af, type LogLevel as ag, type LogScope as ah, type LogValue as ai, type ProductionLogLevel as aj, RedactedWalletError as ak, type RequestId as al, type RpcFailureReason as am, type SafeEvent as an, type SafeFields as ao, type UnredactedFields as ap, OAuthSession as aq, ClientCredentialsOAuth as ar, type Sender as as, PaginationParams as at, PaginatedResponse as au, ClientSecret as av, DecimalString as aw, SwapStatus as ax, type Uint256 as ay, KnownAssetSymbol as az, EvmContractAddress as b, HexEncodedTransactionData as b0, Isin as b1, Iso2CountryCode as b2, Link as b3, type ListOptionAddressesParams as b4, MAX_ASSET_DECIMALS as b5, MAX_UINT_256 as b6, Milestone as b7, OAuthRefreshToken as b8, type OfferBase as b9, SOLANA_CHAINS as bA, STABLE_DECIMALS as bB, SolanaChain as bC, type SubmitDocumentParams as bD, type SuperstateSwapOffer as bE, type SwapContractRef as bF, SwapPreview as bG, TermItem as bH, Ticker as bI, type TokenLogoImage as bJ, TokenLogoUrl as bK, type TokenRole as bL, TokensNamespaceImpl as bM, type Tx as bN, WalletAddress as bO, WalletOwnershipChallenge as bP, type WalletProtocol as bQ, WalletsNamespaceImpl as bR, apiErrorCode as bS, assertUint256 as bT, isChain as bU, isOfferType as bV, parseUint256 as bW, type OfferDetailBase as ba, OfferEditorial as bb, OfferOption as bc, OfferOptionSlug as bd, OfferSlug as be, OfferToken as bf, OffersNamespaceImpl as bg, type OndoQuoteDuration as bh, type OndoSellOutcome as bi, type OndoSwapOffer as bj, PKCEState as bk, type PaginatedResponseDto as bl, ParticipationId as bm, type ParticipationStatus as bn, ParticipationsPaginationParams as bo, PauseFlags as bp, Pii as bq, PiiAddress as br, PiiJurisdiction as bs, type PiiKind as bt, type QueryParamValue as bu, type QueryParamValues as bv, RedirectUri as bw, type RemoveOptionAddressParams as bx, type RequirementActionNeededReason as by, type RpcConfig as bz, type CoinListTokenSaleNamespace as c, OfferOptionId as d, AssetId as e, CoinListTokenSaleNamespaceImpl as f, type OndoNamespace as g, AssetSymbol as h, OfferSwapContract as i, OndoBuyTransaction as j, OndoSellTransaction as k, type OndoSwapTransactionCore as l, type OrderBookSide as m, OndoNamespaceImpl as n, type WalletsNamespace as o, Bps as p, EvmWalletAddress as q, SuperstateSwapNamespaceImpl as r, Requirement as s, RequirementsNamespaceImpl as t, type Config as u, type OAuthAccessToken as v, type OffersNamespace as w, StablecoinSymbol as x, type Erc20Asset as y, OfferDetail as z };
3795
+ export { type WalletChallengeType as $, AuthorizationCode as A, BlockchainAmount as B, CodeVerifier as C, OfferDetail as D, type Erc20Namespace as E, TokenMetadata as F, type CentrifugeVaultOfferDetail as G, type OfferType as H, type OndoSwapOfferDetail as I, type CoinListTokenSaleOfferDetail as J, type SuperstateSwapOfferDetail as K, type Logger as L, Offer as M, RequirementStatusInfo as N, OfferId as O, Participation as P, type RequirementType as Q, type RequirementsNamespace as R, type SuperstateSwapNamespace as S, type TokensNamespace as T, type UniversalNamespaceContext as U, type RequirementStatusValue as V, type WalletError as W, OfferOptionAddress as X, RequirementId as Y, type KycLevelName as Z, DocumentSubmission as _, EthereumChain as a, CreateParticipationParams as a$, type PinoLoggerOptions as a0, type CentrifugeOrderReason as a1, type CentrifugeOrderability as a2, CentrifugeVaultQuote as a3, CentrifugeVaultStatus as a4, OndoTradingStatus as a5, AssetDecimals as a6, type BuildOndoBuyParams as a7, type BuildOndoSellParams as a8, OndoQuote as a9, PaginatedResponse as aA, ClientSecret as aB, DecimalString as aC, SwapStatus as aD, type Uint256 as aE, KnownAssetSymbol as aF, type Newtype as aG, type AllowWalletParams as aH, AllowWalletResponse as aI, Asset as aJ, AssetCode as aK, Blockchain as aL, type BuildOndoSwapParamsCore as aM, CentrifugeNamespaceImpl as aN, type CentrifugePositionStatus as aO, CentrifugeVaultBuyTransaction as aP, CentrifugeVaultClaimTransaction as aQ, type CentrifugeVaultOffer as aR, CentrifugeVaultPosition as aS, type CentrifugeVaultReason as aT, type CentrifugeVaultTransactionCore as aU, Chain as aV, ClientId as aW, CodeChallenge as aX, type CoinListTokenSaleOffer as aY, ConnectExternalWalletParams as aZ, type CreateKycTokenParams as a_, type OndoQuoteSize as aa, type TokenIdentifier as ab, OfferOptionAddressId as ac, TokenLogo as ad, type DebugEvent as ae, type FrontlineEventId as af, HttpError as ag, type HttpResponse as ah, KycToken as ai, type LogBinding as aj, type LogBindings as ak, type LogCause as al, type LogLevel as am, type LogScope as an, type LogValue as ao, type ProductionLogLevel as ap, RedactedWalletError as aq, type RequestId as ar, type RpcFailureReason as as, type SafeEvent as at, type SafeFields as au, type UnredactedFields as av, OAuthSession as aw, ClientCredentialsOAuth as ax, type Sender as ay, PaginationParams as az, EvmContractAddress as b, TokenLogoUrl as b$, CreateWalletOwnershipChallengeParams as b0, Cursor as b1, type DocumentFormType as b2, type DocumentSubmissionStatus as b3, type DocumentType as b4, ETHEREUM_CHAINS as b5, Erc20NamespaceImpl as b6, FaqItem as b7, type GetCentrifugeVaultQuoteParams as b8, type GetCentrifugeVaultStatusParams as b9, type OndoSwapOffer as bA, PKCEState as bB, type PaginatedResponseDto as bC, ParticipationId as bD, type ParticipationStatus as bE, ParticipationsPaginationParams as bF, PauseFlags as bG, Pii as bH, PiiAddress as bI, PiiJurisdiction as bJ, type PiiKind as bK, type QueryParamValue as bL, type QueryParamValues as bM, RedirectUri as bN, type RemoveOptionAddressParams as bO, type RequirementActionNeededReason as bP, type RpcConfig as bQ, SOLANA_CHAINS as bR, STABLE_DECIMALS as bS, SolanaChain as bT, type SubmitDocumentParams as bU, type SuperstateSwapOffer as bV, type SwapContractRef as bW, SwapPreview as bX, TermItem as bY, Ticker as bZ, type TokenLogoImage as b_, type GetOndoQuoteParams as ba, type GetOndoTradingStatusParams as bb, type GetSwapAuthorizationParams as bc, type GetSwapPreviewParams as bd, type GetTokenAllowanceParams as be, type GetTokenBalanceParams as bf, HexEncodedTransactionData as bg, Isin as bh, Iso2CountryCode as bi, Link as bj, type ListOptionAddressesParams as bk, MAX_ASSET_DECIMALS as bl, MAX_UINT_256 as bm, Milestone as bn, OAuthRefreshToken as bo, type OfferBase as bp, type OfferDetailBase as bq, OfferEditorial as br, OfferOption as bs, OfferOptionSlug as bt, OfferSlug as bu, OfferToken as bv, OfferVaultContract as bw, OffersNamespaceImpl as bx, type OndoQuoteDuration as by, type OndoSellOutcome as bz, type CoinListTokenSaleNamespace as c, type TokenRole as c0, TokensNamespaceImpl as c1, type Tx as c2, WalletAddress as c3, WalletOwnershipChallenge as c4, type WalletProtocol as c5, WalletsNamespaceImpl as c6, apiErrorCode as c7, assertUint256 as c8, isChain as c9, isOfferType as ca, parseUint256 as cb, OfferOptionId as d, AssetId as e, CoinListTokenSaleNamespaceImpl as f, type OndoNamespace as g, AssetSymbol as h, OfferSwapContract as i, OndoBuyTransaction as j, OndoSellTransaction as k, type OndoSwapTransactionCore as l, type OrderBookSide as m, OndoNamespaceImpl as n, type WalletsNamespace as o, Bps as p, EvmWalletAddress as q, SuperstateSwapNamespaceImpl as r, Requirement as s, RequirementsNamespaceImpl as t, type Config as u, type OAuthAccessToken as v, type OffersNamespace as w, type CentrifugeNamespace as x, StablecoinSymbol as y, type Erc20Asset as z };