@agoric/inter-protocol 0.16.1 → 0.16.2-calypso-dev-84eb287.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (192) hide show
  1. package/README.md +6 -6
  2. package/package.json +41 -36
  3. package/scripts/build-bundles.js +5 -21
  4. package/src/auction/auctionBook.d.ts +147 -0
  5. package/src/auction/auctionBook.d.ts.map +1 -0
  6. package/src/auction/auctionBook.js +135 -103
  7. package/src/auction/auctioneer.d.ts +69 -0
  8. package/src/auction/auctioneer.d.ts.map +1 -0
  9. package/src/auction/auctioneer.js +63 -49
  10. package/src/auction/offerBook.d.ts +45 -0
  11. package/src/auction/offerBook.d.ts.map +1 -0
  12. package/src/auction/offerBook.js +13 -12
  13. package/src/auction/params.d.ts +144 -0
  14. package/src/auction/params.d.ts.map +1 -0
  15. package/src/auction/params.js +10 -9
  16. package/src/auction/scheduleMath.d.ts +5 -0
  17. package/src/auction/scheduleMath.d.ts.map +1 -0
  18. package/src/auction/scheduleMath.js +17 -15
  19. package/src/auction/scheduler.d.ts +49 -0
  20. package/src/auction/scheduler.d.ts.map +1 -0
  21. package/src/auction/scheduler.js +51 -43
  22. package/src/auction/sortedOffers.d.ts +8 -0
  23. package/src/auction/sortedOffers.d.ts.map +1 -0
  24. package/src/auction/sortedOffers.js +9 -7
  25. package/src/auction/util.d.ts +32 -0
  26. package/src/auction/util.d.ts.map +1 -0
  27. package/src/auction/util.js +6 -4
  28. package/src/clientSupport.d.ts +167 -0
  29. package/src/clientSupport.d.ts.map +1 -0
  30. package/src/clientSupport.js +154 -96
  31. package/src/collectFees.d.ts +2 -0
  32. package/src/collectFees.d.ts.map +1 -0
  33. package/src/contractSupport.d.ts +28 -0
  34. package/src/contractSupport.d.ts.map +1 -0
  35. package/src/contractSupport.js +14 -12
  36. package/src/econCommitteeCharter.d.ts +39 -0
  37. package/src/econCommitteeCharter.d.ts.map +1 -0
  38. package/src/econCommitteeCharter.js +21 -20
  39. package/src/feeDistributor.d.ts +224 -0
  40. package/src/feeDistributor.d.ts.map +1 -0
  41. package/src/feeDistributor.js +37 -33
  42. package/src/index.d.ts +2 -0
  43. package/src/index.d.ts.map +1 -0
  44. package/src/index.js +1 -0
  45. package/src/interest-math.d.ts +3 -0
  46. package/src/interest-math.d.ts.map +1 -0
  47. package/src/interest.d.ts +28 -0
  48. package/src/interest.d.ts.map +1 -0
  49. package/src/interest.js +21 -16
  50. package/src/price/README.md +13 -0
  51. package/src/price/fluxAggregatorContract.d.ts +70 -0
  52. package/src/price/fluxAggregatorContract.d.ts.map +1 -0
  53. package/src/price/fluxAggregatorContract.js +62 -55
  54. package/src/price/fluxAggregatorKit.d.ts +103 -0
  55. package/src/price/fluxAggregatorKit.d.ts.map +1 -0
  56. package/src/price/fluxAggregatorKit.js +50 -37
  57. package/src/price/priceOracleKit.d.ts +38 -0
  58. package/src/price/priceOracleKit.d.ts.map +1 -0
  59. package/src/price/priceOracleKit.js +11 -13
  60. package/src/price/roundsManager.d.ts +204 -0
  61. package/src/price/roundsManager.d.ts.map +1 -0
  62. package/src/price/roundsManager.js +79 -82
  63. package/src/proposals/README.md +2 -3
  64. package/src/proposals/add-auction.d.ts +69 -0
  65. package/src/proposals/add-auction.d.ts.map +1 -0
  66. package/src/proposals/add-auction.js +180 -0
  67. package/src/proposals/addAssetToVault.d.ts +160 -0
  68. package/src/proposals/addAssetToVault.d.ts.map +1 -0
  69. package/src/proposals/addAssetToVault.js +172 -38
  70. package/src/proposals/committee-proposal.d.ts +113 -0
  71. package/src/proposals/committee-proposal.d.ts.map +1 -0
  72. package/src/proposals/committee-proposal.js +25 -31
  73. package/src/proposals/core-proposal.d.ts +149 -0
  74. package/src/proposals/core-proposal.d.ts.map +1 -0
  75. package/src/proposals/core-proposal.js +9 -11
  76. package/src/proposals/econ-behaviors.d.ts +539 -0
  77. package/src/proposals/econ-behaviors.d.ts.map +1 -0
  78. package/src/proposals/econ-behaviors.js +64 -45
  79. package/src/proposals/price-feed-proposal.d.ts +84 -0
  80. package/src/proposals/price-feed-proposal.d.ts.map +1 -0
  81. package/src/proposals/price-feed-proposal.js +108 -51
  82. package/src/proposals/startEconCommittee.d.ts +34 -0
  83. package/src/proposals/startEconCommittee.d.ts.map +1 -0
  84. package/src/proposals/startEconCommittee.js +2 -2
  85. package/src/proposals/startPSM.d.ts +59 -0
  86. package/src/proposals/startPSM.d.ts.map +1 -0
  87. package/src/proposals/startPSM.js +38 -27
  88. package/src/proposals/upgrade-scaledPriceAuthorities.d.ts +24 -0
  89. package/src/proposals/upgrade-scaledPriceAuthorities.d.ts.map +1 -0
  90. package/src/proposals/upgrade-scaledPriceAuthorities.js +78 -0
  91. package/src/proposals/upgrade-vaults.d.ts +35 -0
  92. package/src/proposals/upgrade-vaults.d.ts.map +1 -0
  93. package/src/proposals/upgrade-vaults.js +235 -0
  94. package/src/proposals/utils.d.ts +17 -0
  95. package/src/proposals/utils.d.ts.map +1 -0
  96. package/src/proposals/utils.js +34 -7
  97. package/src/provisionPool.d.ts +167 -0
  98. package/src/provisionPool.d.ts.map +1 -0
  99. package/src/provisionPool.js +122 -0
  100. package/src/provisionPoolKit.d.ts +367 -0
  101. package/src/provisionPoolKit.d.ts.map +1 -0
  102. package/src/provisionPoolKit.js +522 -0
  103. package/src/psm/psm.d.ts +122 -0
  104. package/src/psm/psm.d.ts.map +1 -0
  105. package/src/psm/psm.js +73 -69
  106. package/src/psm/types-ambient.d.ts +2 -0
  107. package/src/psm/types-ambient.d.ts.map +1 -0
  108. package/src/psm/types-ambient.js +3 -0
  109. package/src/reserve/assetReserve.d.ts +47 -0
  110. package/src/reserve/assetReserve.d.ts.map +1 -0
  111. package/src/reserve/assetReserve.js +28 -19
  112. package/src/reserve/assetReserveKit.d.ts +74 -0
  113. package/src/reserve/assetReserveKit.d.ts.map +1 -0
  114. package/src/reserve/assetReserveKit.js +18 -24
  115. package/src/reserve/params.d.ts +10 -0
  116. package/src/reserve/params.d.ts.map +1 -0
  117. package/src/tokens.d.ts +3 -0
  118. package/src/tokens.d.ts.map +1 -0
  119. package/src/tokens.js +5 -0
  120. package/src/vaultFactory/burn.d.ts +2 -0
  121. package/src/vaultFactory/burn.d.ts.map +1 -0
  122. package/src/vaultFactory/burn.js +1 -1
  123. package/src/vaultFactory/liquidation.d.ts +23 -0
  124. package/src/vaultFactory/liquidation.d.ts.map +1 -0
  125. package/src/vaultFactory/liquidation.js +36 -22
  126. package/src/vaultFactory/math.d.ts +11 -0
  127. package/src/vaultFactory/math.d.ts.map +1 -0
  128. package/src/vaultFactory/math.js +10 -9
  129. package/src/vaultFactory/orderedVaultStore.d.ts +93 -0
  130. package/src/vaultFactory/orderedVaultStore.d.ts.map +1 -0
  131. package/src/vaultFactory/orderedVaultStore.js +8 -11
  132. package/src/vaultFactory/params.d.ts +140 -0
  133. package/src/vaultFactory/params.d.ts.map +1 -0
  134. package/src/vaultFactory/params.js +52 -24
  135. package/src/vaultFactory/prioritizedVaults.d.ts +279 -0
  136. package/src/vaultFactory/prioritizedVaults.d.ts.map +1 -0
  137. package/src/vaultFactory/prioritizedVaults.js +4 -4
  138. package/src/vaultFactory/proceeds.d.ts +35 -0
  139. package/src/vaultFactory/proceeds.d.ts.map +1 -0
  140. package/src/vaultFactory/proceeds.js +26 -18
  141. package/src/vaultFactory/storeUtils.d.ts +25 -0
  142. package/src/vaultFactory/storeUtils.d.ts.map +1 -0
  143. package/src/vaultFactory/storeUtils.js +10 -12
  144. package/src/vaultFactory/types-ambient.d.ts +137 -0
  145. package/src/vaultFactory/types-ambient.d.ts.map +1 -0
  146. package/src/vaultFactory/{types.js → types-ambient.js} +42 -42
  147. package/src/vaultFactory/vault.d.ts +332 -0
  148. package/src/vaultFactory/vault.d.ts.map +1 -0
  149. package/src/vaultFactory/vault.js +99 -93
  150. package/src/vaultFactory/vaultDirector.d.ts +340 -0
  151. package/src/vaultFactory/vaultDirector.d.ts.map +1 -0
  152. package/src/vaultFactory/vaultDirector.js +63 -50
  153. package/src/vaultFactory/vaultFactory.d.ts +201 -0
  154. package/src/vaultFactory/vaultFactory.d.ts.map +1 -0
  155. package/src/vaultFactory/vaultFactory.js +49 -32
  156. package/src/vaultFactory/vaultHolder.d.ts +126 -0
  157. package/src/vaultFactory/vaultHolder.d.ts.map +1 -0
  158. package/src/vaultFactory/vaultHolder.js +10 -14
  159. package/src/vaultFactory/vaultKit.d.ts +32 -0
  160. package/src/vaultFactory/vaultKit.d.ts.map +1 -0
  161. package/src/vaultFactory/vaultKit.js +5 -4
  162. package/src/vaultFactory/vaultManager.d.ts +674 -0
  163. package/src/vaultFactory/vaultManager.d.ts.map +1 -0
  164. package/src/vaultFactory/vaultManager.js +249 -151
  165. package/CHANGELOG.md +0 -1033
  166. package/bundles/bundle-auctioneer-js-meta.json +0 -722
  167. package/bundles/bundle-auctioneer.js +0 -1
  168. package/bundles/bundle-econCommitteeCharter-js-meta.json +0 -514
  169. package/bundles/bundle-econCommitteeCharter.js +0 -1
  170. package/bundles/bundle-feeDistributor-js-meta.json +0 -458
  171. package/bundles/bundle-feeDistributor.js +0 -1
  172. package/bundles/bundle-fluxAggregatorKit-js-meta.json +0 -674
  173. package/bundles/bundle-fluxAggregatorKit.js +0 -1
  174. package/bundles/bundle-psm-js-meta.json +0 -666
  175. package/bundles/bundle-psm.js +0 -1
  176. package/bundles/bundle-reserve-js-meta.json +0 -662
  177. package/bundles/bundle-reserve.js +0 -1
  178. package/bundles/bundle-scaledPriceAuthority-js-meta.json +0 -542
  179. package/bundles/bundle-scaledPriceAuthority.js +0 -1
  180. package/bundles/bundle-vaultFactory-js-meta.json +0 -790
  181. package/bundles/bundle-vaultFactory.js +0 -1
  182. package/exported.js +0 -2
  183. package/scripts/add-collateral-core.js +0 -112
  184. package/scripts/deploy-contracts.js +0 -100
  185. package/scripts/init-core.js +0 -198
  186. package/scripts/invite-committee-core.js +0 -42
  187. package/scripts/manual-price-feed.js +0 -117
  188. package/scripts/price-feed-core.js +0 -104
  189. package/scripts/start-local-chain.sh +0 -84
  190. package/src/psm/types.js +0 -3
  191. package/src/typeGuards.js +0 -13
  192. package/src/vaultFactory/type-imports.js +0 -4
@@ -13,12 +13,13 @@ const { Fail } = assert;
13
13
 
14
14
  /**
15
15
  * @file we use a floating point representation of the price or rate as the
16
- * first part of the key in the store. The second part is the sequence number of
17
- * the bid, but it doesn't matter for sorting. When we retrieve multiple bids,
18
- * it's only by bid value, so we don't care how the sequence numbers sort.
16
+ * first part of the key in the store. The second part is the sequence number
17
+ * of the bid, but it doesn't matter for sorting. When we retrieve multiple
18
+ * bids, it's only by bid value, so we don't care how the sequence numbers
19
+ * sort.
19
20
  *
20
- * We take advantage of the fact that encodeData takes a passable and turns it
21
- * into a sort key. Arrays of passable data sort like composite keys.
21
+ * We take advantage of the fact that encodeData takes a passable and turns it
22
+ * into a sort key. Arrays of passable data sort like composite keys.
22
23
  */
23
24
 
24
25
  /**
@@ -39,7 +40,7 @@ export const toPartialOfferKey = offerPrice => {
39
40
  * @param {Ratio} offerPrice IST/collateral
40
41
  * @param {bigint} sequenceNumber
41
42
  * @returns {string} lexically sortable string in which highest price is first,
42
- * ties will be broken by sequenceNumber of offer
43
+ * ties will be broken by sequenceNumber of offer
43
44
  */
44
45
  export const toPriceOfferKey = (offerPrice, sequenceNumber) => {
45
46
  mustMatch(offerPrice, RatioShape);
@@ -87,6 +88,7 @@ const bidScalingRatioFromKey = (bidScaleFloat, numBrand, useDecimals) => {
87
88
  * @returns {[normalizedPrice: Ratio, sequenceNumber: bigint]}
88
89
  */
89
90
  export const fromPriceOfferKey = (key, numBrand, denomBrand, useDecimals) => {
91
+ // @ts-expect-error XXX
90
92
  const [pricePart, sequenceNumberPart] = decodeData(key);
91
93
  return [
92
94
  priceRatioFromFloat(pricePart, numBrand, denomBrand, useDecimals),
@@ -107,7 +109,7 @@ export const toBidScalingComparator = rate => {
107
109
  * @param {Ratio} rate discount/markup rate expressed as a ratio IST/IST
108
110
  * @param {bigint} sequenceNumber
109
111
  * @returns {string} lexically sortable string in which highest price is first,
110
- * ties will be broken by sequenceNumber of offer
112
+ * ties will be broken by sequenceNumber of offer
111
113
  */
112
114
  export const toScaledRateOfferKey = (rate, sequenceNumber) => {
113
115
  mustMatch(rate, RatioShape);
@@ -0,0 +1,32 @@
1
+ /** @import {PriceAuthority, PriceDescription, PriceQuote, PriceQuoteValue, PriceQuery,} from '@agoric/zoe/tools/types.js'; */
2
+ /**
3
+ * Constants for Auction State.
4
+ *
5
+ * @type {{ ACTIVE: 'active'; WAITING: 'waiting' }}
6
+ */
7
+ export const AuctionState: {
8
+ ACTIVE: "active";
9
+ WAITING: "waiting";
10
+ };
11
+ export function makeBrandedRatioPattern(numeratorAmountShape: {
12
+ brand: Brand;
13
+ value: Pattern;
14
+ }, denominatorAmountShape: {
15
+ brand: Brand;
16
+ value: Pattern;
17
+ }): {
18
+ numerator: {
19
+ brand: Brand;
20
+ value: Pattern;
21
+ };
22
+ denominator: {
23
+ brand: Brand;
24
+ value: Pattern;
25
+ };
26
+ };
27
+ export function isScaledBidPriceHigher(bidScaling: Ratio, currentPrice: Ratio, oraclePrice: Ratio): boolean;
28
+ /** @type {(quote: PriceQuote) => Ratio} */
29
+ export const priceFrom: (quote: PriceQuote) => Ratio;
30
+ export function makeCancelTokenMaker(name: any): () => import("@endo/marshal").RemotableObject<`Alleged: ${string}`> & import("@endo/eventual-send").RemotableBrand<{}, {}>;
31
+ import type { PriceQuote } from '@agoric/zoe/tools/types.js';
32
+ //# sourceMappingURL=util.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"util.d.ts","sourceRoot":"","sources":["util.js"],"names":[],"mappings":"AASA,8HAA8H;AAE9H;;;;GAIG;AACH,2BAFU;IAAE,MAAM,EAAE,QAAQ,CAAC;IAAC,OAAO,EAAE,SAAS,CAAA;CAAE,CAKhD;AAMK,8DAHI;IAAE,KAAK,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,0BAChC;IAAE,KAAK,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE;;eADvB,KAAK;eAAS,OAAO;;;eACrB,KAAK;eAAS,OAAO;;EAUxC;AASM,mDANI,KAAK,gBACL,KAAK,eACL,KAAK,GACH,OAAO,CAI6C;AAEjE,2CAA2C;AAC3C,wBADW,CAAC,KAAK,EAAE,UAAU,KAAK,KAAK,CAKnC;AAEG,4KAIN;gCA/C6F,4BAA4B"}
@@ -7,10 +7,12 @@ import {
7
7
  } from '@agoric/zoe/src/contractSupport/index.js';
8
8
  import { Far } from '@endo/marshal';
9
9
 
10
+ /** @import {PriceAuthority, PriceDescription, PriceQuote, PriceQuoteValue, PriceQuery,} from '@agoric/zoe/tools/types.js'; */
11
+
10
12
  /**
11
13
  * Constants for Auction State.
12
14
  *
13
- * @type {{ ACTIVE: 'active', WAITING: 'waiting' }}
15
+ * @type {{ ACTIVE: 'active'; WAITING: 'waiting' }}
14
16
  */
15
17
  export const AuctionState = {
16
18
  ACTIVE: 'active',
@@ -18,8 +20,8 @@ export const AuctionState = {
18
20
  };
19
21
 
20
22
  /**
21
- * @param {{ brand: Brand, value: Pattern }} numeratorAmountShape
22
- * @param {{ brand: Brand, value: Pattern }} denominatorAmountShape
23
+ * @param {{ brand: Brand; value: Pattern }} numeratorAmountShape
24
+ * @param {{ brand: Brand; value: Pattern }} denominatorAmountShape
23
25
  */
24
26
  export const makeBrandedRatioPattern = (
25
27
  numeratorAmountShape,
@@ -36,7 +38,7 @@ export const makeBrandedRatioPattern = (
36
38
  * @param {Ratio} currentPrice
37
39
  * @param {Ratio} oraclePrice
38
40
  * @returns {boolean} TRUE iff the discount(/markup) applied to the price is
39
- * higher than the quote.
41
+ * higher than the quote.
40
42
  */
41
43
  export const isScaledBidPriceHigher = (bidScaling, currentPrice, oraclePrice) =>
42
44
  ratioGTE(multiplyRatios(oraclePrice, bidScaling), currentPrice);
@@ -0,0 +1,167 @@
1
+ export function lookupOfferIdForVault(vaultId: string, currentP: Promise<import("@agoric/smart-wallet/src/smartWallet.js").CurrentWalletRecord>): Promise<string>;
2
+ export function makeParseAmount(agoricNames: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand" | "vbankAsset">, makeError?: (msg: string) => Error): (a: string) => Amount<"nat">;
3
+ export namespace Offers {
4
+ namespace auction {
5
+ export { makeBidOffer as Bid };
6
+ }
7
+ namespace fluxAggregator {
8
+ export { makePushPriceOffer as PushPrice };
9
+ }
10
+ namespace psm {
11
+ export { makePsmSwapOffer as swap };
12
+ }
13
+ namespace vaults {
14
+ export { makeOpenOffer as OpenVault };
15
+ export { makeAdjustOffer as AdjustBalances };
16
+ export { makeCloseOffer as CloseVault };
17
+ }
18
+ namespace reserve {
19
+ export { makeAddCollateralOffer as AddCollateral };
20
+ }
21
+ }
22
+ /**
23
+ * @param {Pick<
24
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
25
+ * 'brand' | 'vbankAsset'
26
+ * >} agoricNames
27
+ * @param {{
28
+ * offerId: string;
29
+ * give: string;
30
+ * maxBuy: string;
31
+ * wantMinimum?: string;
32
+ * } & (
33
+ * | {
34
+ * price: number;
35
+ * }
36
+ * | {
37
+ * discount: number; // -1 to 1. e.g. 0.10 for 10% discount, -0.05 for 5% markup
38
+ * }
39
+ * )} opts
40
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
41
+ */
42
+ declare function makeBidOffer(agoricNames: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand" | "vbankAsset">, opts: {
43
+ offerId: string;
44
+ give: string;
45
+ maxBuy: string;
46
+ wantMinimum?: string;
47
+ } & ({
48
+ price: number;
49
+ } | {
50
+ discount: number;
51
+ })): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
52
+ /**
53
+ * @param {unknown} _agoricNames
54
+ * @param {{
55
+ * offerId: string;
56
+ * roundId?: bigint;
57
+ * unitPrice: bigint;
58
+ * }} opts
59
+ * @param {string} previousOffer
60
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
61
+ */
62
+ declare function makePushPriceOffer(_agoricNames: unknown, opts: {
63
+ offerId: string;
64
+ roundId?: bigint;
65
+ unitPrice: bigint;
66
+ }, previousOffer: string): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
67
+ /**
68
+ * @param {Pick<
69
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
70
+ * 'brand'
71
+ * >} agoricNames
72
+ * @param {Instance} instance
73
+ * @param {{ offerId: string; feePct?: number; pair: [string, string] } & (
74
+ * | { wantMinted: number }
75
+ * | { giveMinted: number }
76
+ * )} opts
77
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
78
+ */
79
+ declare function makePsmSwapOffer({ brand }: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand">, instance: Instance, opts: {
80
+ offerId: string;
81
+ feePct?: number;
82
+ pair: [string, string];
83
+ } & ({
84
+ wantMinted: number;
85
+ } | {
86
+ giveMinted: number;
87
+ })): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
88
+ /**
89
+ * @param {Pick<
90
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
91
+ * 'brand'
92
+ * >} agoricNames
93
+ * @param {{
94
+ * offerId: string;
95
+ * wantMinted: number;
96
+ * giveCollateral: number;
97
+ * collateralBrandKey: string;
98
+ * }} opts
99
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
100
+ */
101
+ declare function makeOpenOffer({ brand }: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand">, opts: {
102
+ offerId: string;
103
+ wantMinted: number;
104
+ giveCollateral: number;
105
+ collateralBrandKey: string;
106
+ }): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
107
+ /**
108
+ * @param {Pick<
109
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
110
+ * 'brand'
111
+ * >} agoricNames
112
+ * @param {{
113
+ * offerId: string;
114
+ * collateralBrandKey?: string;
115
+ * giveCollateral?: number;
116
+ * wantCollateral?: number;
117
+ * giveMinted?: number;
118
+ * wantMinted?: number;
119
+ * }} opts
120
+ * @param {string} previousOffer
121
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
122
+ */
123
+ declare function makeAdjustOffer({ brand }: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand">, opts: {
124
+ offerId: string;
125
+ collateralBrandKey?: string;
126
+ giveCollateral?: number;
127
+ wantCollateral?: number;
128
+ giveMinted?: number;
129
+ wantMinted?: number;
130
+ }, previousOffer: string): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
131
+ /**
132
+ * @param {Pick<
133
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
134
+ * 'brand'
135
+ * >} agoricNames
136
+ * @param {{
137
+ * offerId: string;
138
+ * collateralBrandKey?: string;
139
+ * giveMinted: number;
140
+ * }} opts
141
+ * @param {string} previousOffer
142
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
143
+ */
144
+ declare function makeCloseOffer({ brand }: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand">, opts: {
145
+ offerId: string;
146
+ collateralBrandKey?: string;
147
+ giveMinted: number;
148
+ }, previousOffer: string): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
149
+ /**
150
+ * @param {Pick<
151
+ * import('@agoric/vats/tools/board-utils.js').AgoricNamesRemotes,
152
+ * 'brand'
153
+ * >} agoricNames
154
+ * @param {{
155
+ * offerId: string;
156
+ * give: number;
157
+ * collateralBrandKey: string;
158
+ * }} opts
159
+ * @returns {import('@agoric/smart-wallet/src/offers.js').OfferSpec}
160
+ */
161
+ declare function makeAddCollateralOffer({ brand }: Pick<import("@agoric/vats/tools/board-utils.js").AgoricNamesRemotes, "brand">, opts: {
162
+ offerId: string;
163
+ give: number;
164
+ collateralBrandKey: string;
165
+ }): import("@agoric/smart-wallet/src/offers.js").OfferSpec;
166
+ export {};
167
+ //# sourceMappingURL=clientSupport.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"clientSupport.d.ts","sourceRoot":"","sources":["clientSupport.js"],"names":[],"mappings":"AAsKO,+CANI,MAAM,YACN,OAAO,CACjB,OAAW,yCAAyC,EAAE,mBAAmB,CACtE,GACS,OAAO,CAAC,MAAM,CAAC,CAW3B;AAmFM,6CAPI,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,GAAG,YAAY,CACvB,cACO,CAAC,GAAG,EAAE,MAAM,KAAK,KAAK,GACpB,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC,KAAK,CAAC,CAmCtC;;;;;;;;;;;;;;;;;;;;AAEH;;;;;;;;;;;;;;;;;;;GAmBG;AACH,2CAnBW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,GAAG,YAAY,CACvB,QACO;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,IAAQ,EAAE,MAAM,CAAC;IACjB,MAAU,EAAE,MAAM,CAAC;IACnB,WAAe,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,CACA;IACN,KAAa,EAAE,MAAM,CAAC;CACf,GACD;IACN,QAAgB,EAAE,MAAM,CAAC;CAClB,CACJ,GACS,OAAO,oCAAoC,EAAE,SAAS,CAuDlE;AAqCD;;;;;;;;;GASG;AACH,kDATW,OAAO,QACP;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,OAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAa,EAAE,MAAM,CAAC;CACnB,iBACO,MAAM,GACJ,OAAO,oCAAoC,EAAE,SAAS,CAelE;AAxND;;;;;;;;;;;GAWG;AACH,6CAXW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,CACR,YACO,QAAQ,QACR;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAAE,GAAG,CACnE;IAAE,UAAU,EAAE,MAAM,CAAA;CAAE,GACtB;IAAE,UAAU,EAAE,MAAM,CAAA;CAAE,CACzB,GACS,OAAO,oCAAoC,EAAE,SAAS,CA4BlE;AAzLD;;;;;;;;;;;;GAYG;AACH,0CAZW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,CACR,QACO;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,UAAc,EAAE,MAAM,CAAC;IACvB,cAAkB,EAAE,MAAM,CAAC;IAC3B,kBAAsB,EAAE,MAAM,CAAC;CAC5B,GACS,OAAO,oCAAoC,EAAE,SAAS,CAuBlE;AAED;;;;;;;;;;;;;;;GAeG;AACH,4CAfW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,CACR,QACO;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,kBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,cAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,cAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,UAAc,CAAC,EAAE,MAAM,CAAC;IACxB,UAAc,CAAC,EAAE,MAAM,CAAC;CACrB,iBACO,MAAM,GACJ,OAAO,oCAAoC,EAAE,SAAS,CAiBlE;AAED;;;;;;;;;;;;GAYG;AACH,2CAZW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,CACR,QACO;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,kBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,UAAc,EAAE,MAAM,CAAC;CACpB,iBACO,MAAM,GACJ,OAAO,oCAAoC,EAAE,SAAS,CAclE;AAmND;;;;;;;;;;;GAWG;AACH,mDAXW,IAAI,CACd,OAAW,mCAAmC,EAAE,kBAAkB,EAClE,OAAW,CACR,QACO;IACV,OAAW,EAAE,MAAM,CAAC;IACpB,IAAQ,EAAE,MAAM,CAAC;IACjB,kBAAsB,EAAE,MAAM,CAAC;CAC5B,GACS,OAAO,oCAAoC,EAAE,SAAS,CAuBlE"}