@gearbox-protocol/sdk 18.2.0-next.6 → 18.2.0-next.7
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,4 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_model_primitives_schema = require("../../../model/primitives.schema.js");
|
|
2
3
|
const require_permissionless_api_chains_schemas = require("../chains/schemas.js");
|
|
3
4
|
const require_permissionless_api_schemas = require("../schemas.js");
|
|
4
5
|
let zod_v4 = require("zod/v4");
|
|
@@ -130,7 +131,8 @@ const assetSummarySchema = zod_v4.z.looseObject({
|
|
|
130
131
|
symbol: zod_v4.z.string(),
|
|
131
132
|
underlyingMarketCount: zod_v4.z.number(),
|
|
132
133
|
quotaLimitUsd: zod_v4.z.number().nullable(),
|
|
133
|
-
quotaUsedUsd: zod_v4.z.number().nullable()
|
|
134
|
+
quotaUsedUsd: zod_v4.z.number().nullable(),
|
|
135
|
+
assetType: require_model_primitives_schema.assetTypeSchema.nullable().default(null)
|
|
134
136
|
});
|
|
135
137
|
/** The list of {@link PermissionlessAssetSummary}, already ordered. */
|
|
136
138
|
const assetSummariesSchema = zod_v4.z.array(assetSummarySchema);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { assetTypeSchema } from "../../../model/primitives.schema.js";
|
|
1
2
|
import { chainSchema } from "../chains/schemas.js";
|
|
2
3
|
import { addressRecord, addressSchema } from "../schemas.js";
|
|
3
4
|
import { z } from "zod/v4";
|
|
@@ -129,7 +130,8 @@ const assetSummarySchema = z.looseObject({
|
|
|
129
130
|
symbol: z.string(),
|
|
130
131
|
underlyingMarketCount: z.number(),
|
|
131
132
|
quotaLimitUsd: z.number().nullable(),
|
|
132
|
-
quotaUsedUsd: z.number().nullable()
|
|
133
|
+
quotaUsedUsd: z.number().nullable(),
|
|
134
|
+
assetType: assetTypeSchema.nullable().default(null)
|
|
133
135
|
});
|
|
134
136
|
/** The list of {@link PermissionlessAssetSummary}, already ordered. */
|
|
135
137
|
const assetSummariesSchema = z.array(assetSummarySchema);
|
|
@@ -229,6 +229,7 @@ export declare const assetSummarySchema: z.ZodObject<{
|
|
|
229
229
|
underlyingMarketCount: z.ZodNumber;
|
|
230
230
|
quotaLimitUsd: z.ZodNullable<z.ZodNumber>;
|
|
231
231
|
quotaUsedUsd: z.ZodNullable<z.ZodNumber>;
|
|
232
|
+
assetType: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodLiteral<"Stable">, z.ZodLiteral<"ETH">, z.ZodLiteral<"BTC">]>>>;
|
|
232
233
|
}, z.core.$loose>;
|
|
233
234
|
/** The list of {@link PermissionlessAssetSummary}, already ordered. */
|
|
234
235
|
export declare const assetSummariesSchema: z.ZodArray<z.ZodObject<{
|
|
@@ -238,5 +239,6 @@ export declare const assetSummariesSchema: z.ZodArray<z.ZodObject<{
|
|
|
238
239
|
underlyingMarketCount: z.ZodNumber;
|
|
239
240
|
quotaLimitUsd: z.ZodNullable<z.ZodNumber>;
|
|
240
241
|
quotaUsedUsd: z.ZodNullable<z.ZodNumber>;
|
|
242
|
+
assetType: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodLiteral<"Stable">, z.ZodLiteral<"ETH">, z.ZodLiteral<"BTC">]>>>;
|
|
241
243
|
}, z.core.$loose>>;
|
|
242
244
|
//#endregion
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AssetType } from "../../../model/primitives.js";
|
|
1
2
|
import { PermissionlessChain } from "../chains/types.js";
|
|
2
3
|
import { PriceFeed } from "../../core/pricefeed.js";
|
|
3
4
|
import "../../core/index.js";
|
|
@@ -278,6 +279,16 @@ export interface PermissionlessAssetSummary {
|
|
|
278
279
|
underlyingMarketCount: number;
|
|
279
280
|
quotaLimitUsd: number | null;
|
|
280
281
|
quotaUsedUsd: number | null;
|
|
282
|
+
/**
|
|
283
|
+
* What the asset is, where the SDK's curated tables say so.
|
|
284
|
+
*
|
|
285
|
+
* `null` for anything they do not name, which is most of a store: the
|
|
286
|
+
* tables classify the tokens markets are built on, and a store carries
|
|
287
|
+
* everything those markets will take as collateral. A filter over this
|
|
288
|
+
* sorts the assets worth sorting and leaves the rest in one heap, which is
|
|
289
|
+
* the honest answer rather than a guess from the symbol.
|
|
290
|
+
*/
|
|
291
|
+
assetType: AssetType | null;
|
|
281
292
|
}
|
|
282
293
|
/**
|
|
283
294
|
* Market caps of one feed's assets, keyed by the lowercased asset address.
|