@compass-labs/api-sdk 1.5.2 → 2.0.1

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 (75) hide show
  1. package/bin/mcp-server.js +49 -61
  2. package/bin/mcp-server.js.map +11 -11
  3. package/dist/commonjs/lib/config.d.ts +2 -2
  4. package/dist/commonjs/lib/config.js +2 -2
  5. package/dist/commonjs/mcp-server/mcp-server.js +1 -1
  6. package/dist/commonjs/mcp-server/server.js +1 -1
  7. package/dist/commonjs/models/components/aavevenue.d.ts +25 -0
  8. package/dist/commonjs/models/components/aavevenue.d.ts.map +1 -0
  9. package/dist/commonjs/models/components/{aavemarket.js → aavevenue.js} +10 -10
  10. package/dist/commonjs/models/components/aavevenue.js.map +1 -0
  11. package/dist/commonjs/models/components/earnmanagerequest.d.ts +19 -19
  12. package/dist/commonjs/models/components/earnmanagerequest.d.ts.map +1 -1
  13. package/dist/commonjs/models/components/earnmanagerequest.js +27 -22
  14. package/dist/commonjs/models/components/earnmanagerequest.js.map +1 -1
  15. package/dist/commonjs/models/components/index.d.ts +2 -2
  16. package/dist/commonjs/models/components/index.d.ts.map +1 -1
  17. package/dist/commonjs/models/components/index.js +2 -2
  18. package/dist/commonjs/models/components/index.js.map +1 -1
  19. package/dist/commonjs/models/components/vaultinfo.d.ts +0 -20
  20. package/dist/commonjs/models/components/vaultinfo.d.ts.map +1 -1
  21. package/dist/commonjs/models/components/vaultinfo.js +0 -17
  22. package/dist/commonjs/models/components/vaultinfo.js.map +1 -1
  23. package/dist/commonjs/models/components/vaultvenue.d.ts +25 -0
  24. package/dist/commonjs/models/components/vaultvenue.d.ts.map +1 -0
  25. package/dist/commonjs/models/components/{vaultmarket.js → vaultvenue.js} +10 -10
  26. package/dist/commonjs/models/components/vaultvenue.js.map +1 -0
  27. package/dist/esm/lib/config.d.ts +2 -2
  28. package/dist/esm/lib/config.js +2 -2
  29. package/dist/esm/mcp-server/mcp-server.js +1 -1
  30. package/dist/esm/mcp-server/server.js +1 -1
  31. package/dist/esm/models/components/aavevenue.d.ts +25 -0
  32. package/dist/esm/models/components/aavevenue.d.ts.map +1 -0
  33. package/dist/esm/models/components/aavevenue.js +22 -0
  34. package/dist/esm/models/components/aavevenue.js.map +1 -0
  35. package/dist/esm/models/components/earnmanagerequest.d.ts +19 -19
  36. package/dist/esm/models/components/earnmanagerequest.d.ts.map +1 -1
  37. package/dist/esm/models/components/earnmanagerequest.js +24 -19
  38. package/dist/esm/models/components/earnmanagerequest.js.map +1 -1
  39. package/dist/esm/models/components/index.d.ts +2 -2
  40. package/dist/esm/models/components/index.d.ts.map +1 -1
  41. package/dist/esm/models/components/index.js +2 -2
  42. package/dist/esm/models/components/index.js.map +1 -1
  43. package/dist/esm/models/components/vaultinfo.d.ts +0 -20
  44. package/dist/esm/models/components/vaultinfo.d.ts.map +1 -1
  45. package/dist/esm/models/components/vaultinfo.js +0 -17
  46. package/dist/esm/models/components/vaultinfo.js.map +1 -1
  47. package/dist/esm/models/components/vaultvenue.d.ts +25 -0
  48. package/dist/esm/models/components/vaultvenue.d.ts.map +1 -0
  49. package/dist/esm/models/components/{vaultmarket.js → vaultvenue.js} +7 -7
  50. package/dist/esm/models/components/vaultvenue.js.map +1 -0
  51. package/examples/node_modules/.package-lock.json +1 -1
  52. package/examples/package-lock.json +1 -1
  53. package/jsr.json +1 -1
  54. package/package.json +1 -1
  55. package/src/lib/config.ts +2 -2
  56. package/src/mcp-server/mcp-server.ts +1 -1
  57. package/src/mcp-server/server.ts +1 -1
  58. package/src/models/components/{aavemarket.ts → aavevenue.ts} +14 -14
  59. package/src/models/components/earnmanagerequest.ts +55 -54
  60. package/src/models/components/index.ts +2 -2
  61. package/src/models/components/vaultinfo.ts +0 -43
  62. package/src/models/components/{vaultmarket.ts → vaultvenue.ts} +14 -14
  63. package/dist/commonjs/models/components/aavemarket.d.ts +0 -25
  64. package/dist/commonjs/models/components/aavemarket.d.ts.map +0 -1
  65. package/dist/commonjs/models/components/aavemarket.js.map +0 -1
  66. package/dist/commonjs/models/components/vaultmarket.d.ts +0 -25
  67. package/dist/commonjs/models/components/vaultmarket.d.ts.map +0 -1
  68. package/dist/commonjs/models/components/vaultmarket.js.map +0 -1
  69. package/dist/esm/models/components/aavemarket.d.ts +0 -25
  70. package/dist/esm/models/components/aavemarket.d.ts.map +0 -1
  71. package/dist/esm/models/components/aavemarket.js +0 -22
  72. package/dist/esm/models/components/aavemarket.js.map +0 -1
  73. package/dist/esm/models/components/vaultmarket.d.ts +0 -25
  74. package/dist/esm/models/components/vaultmarket.d.ts.map +0 -1
  75. package/dist/esm/models/components/vaultmarket.js.map +0 -1
@@ -0,0 +1,25 @@
1
+ import * as z from "zod/v3";
2
+ import { Result as SafeParseResult } from "../../types/fp.js";
3
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
+ export type VaultVenue = {
5
+ /**
6
+ * The venue type discriminator.
7
+ */
8
+ type?: "VAULT" | undefined;
9
+ /**
10
+ * The vault address you are interacting with for this action.
11
+ */
12
+ vaultAddress: string;
13
+ };
14
+ /** @internal */
15
+ export declare const VaultVenue$inboundSchema: z.ZodType<VaultVenue, z.ZodTypeDef, unknown>;
16
+ /** @internal */
17
+ export type VaultVenue$Outbound = {
18
+ type: "VAULT";
19
+ vault_address: string;
20
+ };
21
+ /** @internal */
22
+ export declare const VaultVenue$outboundSchema: z.ZodType<VaultVenue$Outbound, z.ZodTypeDef, VaultVenue>;
23
+ export declare function vaultVenueToJSON(vaultVenue: VaultVenue): string;
24
+ export declare function vaultVenueFromJSON(jsonString: string): SafeParseResult<VaultVenue, SDKValidationError>;
25
+ //# sourceMappingURL=vaultvenue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vaultvenue.d.ts","sourceRoot":"","sources":["../../../../src/models/components/vaultvenue.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAG5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,MAAM,MAAM,UAAU,GAAG;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC3B;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,wBAAwB,EAAE,CAAC,CAAC,OAAO,CAC9C,UAAU,EACV,CAAC,CAAC,UAAU,EACZ,OAAO,CAQP,CAAC;AACH,gBAAgB;AAChB,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,OAAO,CAAC;IACd,aAAa,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAC/C,mBAAmB,EACnB,CAAC,CAAC,UAAU,EACZ,UAAU,CAQV,CAAC;AAEH,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,UAAU,GAAG,MAAM,CAE/D;AACD,wBAAgB,kBAAkB,CAChC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,UAAU,EAAE,kBAAkB,CAAC,CAMjD"}
@@ -5,7 +5,7 @@ import * as z from "zod/v3";
5
5
  import { remap as remap$ } from "../../lib/primitives.js";
6
6
  import { safeParse } from "../../lib/schemas.js";
7
7
  /** @internal */
8
- export const VaultMarket$inboundSchema = z.object({
8
+ export const VaultVenue$inboundSchema = z.object({
9
9
  type: z.literal("VAULT").default("VAULT").optional(),
10
10
  vault_address: z.string(),
11
11
  }).transform((v) => {
@@ -14,7 +14,7 @@ export const VaultMarket$inboundSchema = z.object({
14
14
  });
15
15
  });
16
16
  /** @internal */
17
- export const VaultMarket$outboundSchema = z.object({
17
+ export const VaultVenue$outboundSchema = z.object({
18
18
  type: z.literal("VAULT"),
19
19
  vaultAddress: z.string(),
20
20
  }).transform((v) => {
@@ -22,10 +22,10 @@ export const VaultMarket$outboundSchema = z.object({
22
22
  vaultAddress: "vault_address",
23
23
  });
24
24
  });
25
- export function vaultMarketToJSON(vaultMarket) {
26
- return JSON.stringify(VaultMarket$outboundSchema.parse(vaultMarket));
25
+ export function vaultVenueToJSON(vaultVenue) {
26
+ return JSON.stringify(VaultVenue$outboundSchema.parse(vaultVenue));
27
27
  }
28
- export function vaultMarketFromJSON(jsonString) {
29
- return safeParse(jsonString, (x) => VaultMarket$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'VaultMarket' from JSON`);
28
+ export function vaultVenueFromJSON(jsonString) {
29
+ return safeParse(jsonString, (x) => VaultVenue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'VaultVenue' from JSON`);
30
30
  }
31
- //# sourceMappingURL=vaultmarket.js.map
31
+ //# sourceMappingURL=vaultvenue.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vaultvenue.js","sourceRoot":"","sources":["../../../../src/models/components/vaultvenue.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,KAAK,IAAI,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAejD,gBAAgB;AAChB,MAAM,CAAC,MAAM,wBAAwB,GAIjC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE;IACpD,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;CAC1B,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,MAAM,CAAC,CAAC,EAAE;QACf,eAAe,EAAE,cAAc;KAChC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAOH,gBAAgB;AAChB,MAAM,CAAC,MAAM,yBAAyB,GAIlC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;IACxB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE;CACzB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,MAAM,CAAC,CAAC,EAAE;QACf,YAAY,EAAE,eAAe;KAC9B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH,MAAM,UAAU,gBAAgB,CAAC,UAAsB;IACrD,OAAO,IAAI,CAAC,SAAS,CAAC,yBAAyB,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC;AACrE,CAAC;AACD,MAAM,UAAU,kBAAkB,CAChC,UAAkB;IAElB,OAAO,SAAS,CACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,wBAAwB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACpD,wCAAwC,CACzC,CAAC;AACJ,CAAC"}
@@ -6,7 +6,7 @@
6
6
  "packages": {
7
7
  "..": {
8
8
  "name": "@compass-labs/api-sdk",
9
- "version": "1.1.3",
9
+ "version": "2.0.0",
10
10
  "dependencies": {
11
11
  "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0",
12
12
  "zod": "^3.25.0 || ^4.0.0"
@@ -18,7 +18,7 @@
18
18
  },
19
19
  "..": {
20
20
  "name": "@compass-labs/api-sdk",
21
- "version": "1.1.3",
21
+ "version": "2.0.0",
22
22
  "dependencies": {
23
23
  "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0",
24
24
  "zod": "^3.25.0 || ^4.0.0"
package/jsr.json CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  {
4
4
  "name": "@compass-labs/api-sdk",
5
- "version": "1.1.3",
5
+ "version": "2.0.1",
6
6
  "exports": {
7
7
  ".": "./src/index.ts",
8
8
  "./models/errors": "./src/models/errors/index.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@compass-labs/api-sdk",
3
- "version": "1.5.2",
3
+ "version": "2.0.1",
4
4
  "author": "royalnine",
5
5
  "type": "module",
6
6
  "bin": {
package/src/lib/config.ts CHANGED
@@ -61,8 +61,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
61
61
  export const SDK_METADATA = {
62
62
  language: "typescript",
63
63
  openapiDocVersion: "0.0.1",
64
- sdkVersion: "1.1.3",
64
+ sdkVersion: "2.0.1",
65
65
  genVersion: "2.755.6",
66
66
  userAgent:
67
- "speakeasy-sdk/typescript 1.1.3 2.755.6 0.0.1 @compass-labs/api-sdk",
67
+ "speakeasy-sdk/typescript 2.0.1 2.755.6 0.0.1 @compass-labs/api-sdk",
68
68
  } as const;
@@ -19,7 +19,7 @@ const routes = buildRouteMap({
19
19
  export const app = buildApplication(routes, {
20
20
  name: "mcp",
21
21
  versionInfo: {
22
- currentVersion: "1.1.3",
22
+ currentVersion: "2.0.1",
23
23
  },
24
24
  });
25
25
 
@@ -111,7 +111,7 @@ export function createMCPServer(deps: {
111
111
  }) {
112
112
  const server = new McpServer({
113
113
  name: "CompassApiSDK",
114
- version: "1.1.3",
114
+ version: "2.0.1",
115
115
  });
116
116
 
117
117
  const client = new CompassApiSDKCore({
@@ -7,9 +7,9 @@ import { safeParse } from "../../lib/schemas.js";
7
7
  import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
9
 
10
- export type AaveMarket = {
10
+ export type AaveVenue = {
11
11
  /**
12
- * The market type discriminator.
12
+ * The venue type discriminator.
13
13
  */
14
14
  type?: "AAVE" | undefined;
15
15
  /**
@@ -19,8 +19,8 @@ export type AaveMarket = {
19
19
  };
20
20
 
21
21
  /** @internal */
22
- export const AaveMarket$inboundSchema: z.ZodType<
23
- AaveMarket,
22
+ export const AaveVenue$inboundSchema: z.ZodType<
23
+ AaveVenue,
24
24
  z.ZodTypeDef,
25
25
  unknown
26
26
  > = z.object({
@@ -28,30 +28,30 @@ export const AaveMarket$inboundSchema: z.ZodType<
28
28
  token: z.string(),
29
29
  });
30
30
  /** @internal */
31
- export type AaveMarket$Outbound = {
31
+ export type AaveVenue$Outbound = {
32
32
  type: "AAVE";
33
33
  token: string;
34
34
  };
35
35
 
36
36
  /** @internal */
37
- export const AaveMarket$outboundSchema: z.ZodType<
38
- AaveMarket$Outbound,
37
+ export const AaveVenue$outboundSchema: z.ZodType<
38
+ AaveVenue$Outbound,
39
39
  z.ZodTypeDef,
40
- AaveMarket
40
+ AaveVenue
41
41
  > = z.object({
42
42
  type: z.literal("AAVE"),
43
43
  token: z.string(),
44
44
  });
45
45
 
46
- export function aaveMarketToJSON(aaveMarket: AaveMarket): string {
47
- return JSON.stringify(AaveMarket$outboundSchema.parse(aaveMarket));
46
+ export function aaveVenueToJSON(aaveVenue: AaveVenue): string {
47
+ return JSON.stringify(AaveVenue$outboundSchema.parse(aaveVenue));
48
48
  }
49
- export function aaveMarketFromJSON(
49
+ export function aaveVenueFromJSON(
50
50
  jsonString: string,
51
- ): SafeParseResult<AaveMarket, SDKValidationError> {
51
+ ): SafeParseResult<AaveVenue, SDKValidationError> {
52
52
  return safeParse(
53
53
  jsonString,
54
- (x) => AaveMarket$inboundSchema.parse(JSON.parse(x)),
55
- `Failed to parse 'AaveMarket' from JSON`,
54
+ (x) => AaveVenue$inboundSchema.parse(JSON.parse(x)),
55
+ `Failed to parse 'AaveVenue' from JSON`,
56
56
  );
57
57
  }
@@ -9,11 +9,11 @@ import { ClosedEnum } from "../../types/enums.js";
9
9
  import { Result as SafeParseResult } from "../../types/fp.js";
10
10
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
  import {
12
- AaveMarket,
13
- AaveMarket$inboundSchema,
14
- AaveMarket$Outbound,
15
- AaveMarket$outboundSchema,
16
- } from "./aavemarket.js";
12
+ AaveVenue,
13
+ AaveVenue$inboundSchema,
14
+ AaveVenue$Outbound,
15
+ AaveVenue$outboundSchema,
16
+ } from "./aavevenue.js";
17
17
  import { Chain, Chain$inboundSchema, Chain$outboundSchema } from "./chain.js";
18
18
  import {
19
19
  Fee,
@@ -22,28 +22,28 @@ import {
22
22
  Fee$outboundSchema,
23
23
  } from "./fee.js";
24
24
  import {
25
- VaultMarket,
26
- VaultMarket$inboundSchema,
27
- VaultMarket$Outbound,
28
- VaultMarket$outboundSchema,
29
- } from "./vaultmarket.js";
25
+ VaultVenue,
26
+ VaultVenue$inboundSchema,
27
+ VaultVenue$Outbound,
28
+ VaultVenue$outboundSchema,
29
+ } from "./vaultvenue.js";
30
30
 
31
31
  /**
32
- * The earn market.
32
+ * The earn venue.
33
33
  */
34
- export type MarketUnion =
35
- | (AaveMarket & { type: "AAVE" })
36
- | (VaultMarket & { type: "VAULT" });
34
+ export type Venue =
35
+ | (AaveVenue & { type: "AAVE" })
36
+ | (VaultVenue & { type: "VAULT" });
37
37
 
38
38
  /**
39
- * Whether you are depositing into or withdrawing from the given Earn `market`.
39
+ * Whether you are depositing into or withdrawing from the given Earn `venue`.
40
40
  */
41
41
  export const EarnManageRequestAction = {
42
42
  Deposit: "DEPOSIT",
43
43
  Withdraw: "WITHDRAW",
44
44
  } as const;
45
45
  /**
46
- * Whether you are depositing into or withdrawing from the given Earn `market`.
46
+ * Whether you are depositing into or withdrawing from the given Earn `venue`.
47
47
  */
48
48
  export type EarnManageRequestAction = ClosedEnum<
49
49
  typeof EarnManageRequestAction
@@ -59,11 +59,11 @@ export type EarnManageRequest = {
59
59
  */
60
60
  chain: Chain;
61
61
  /**
62
- * The earn market.
62
+ * The earn venue.
63
63
  */
64
- market: (AaveMarket & { type: "AAVE" }) | (VaultMarket & { type: "VAULT" });
64
+ venue: (AaveVenue & { type: "AAVE" }) | (VaultVenue & { type: "VAULT" });
65
65
  /**
66
- * Whether you are depositing into or withdrawing from the given Earn `market`.
66
+ * Whether you are depositing into or withdrawing from the given Earn `venue`.
67
67
  */
68
68
  action: EarnManageRequestAction;
69
69
  /**
@@ -81,47 +81,48 @@ export type EarnManageRequest = {
81
81
  };
82
82
 
83
83
  /** @internal */
84
- export const MarketUnion$inboundSchema: z.ZodType<
85
- MarketUnion,
86
- z.ZodTypeDef,
87
- unknown
88
- > = z.union([
89
- AaveMarket$inboundSchema.and(
90
- z.object({ type: z.literal("AAVE") }).transform((v) => ({ type: v.type })),
91
- ),
92
- VaultMarket$inboundSchema.and(
93
- z.object({ type: z.literal("VAULT") }).transform((v) => ({ type: v.type })),
94
- ),
95
- ]);
84
+ export const Venue$inboundSchema: z.ZodType<Venue, z.ZodTypeDef, unknown> = z
85
+ .union([
86
+ AaveVenue$inboundSchema.and(
87
+ z.object({ type: z.literal("AAVE") }).transform((v) => ({
88
+ type: v.type,
89
+ })),
90
+ ),
91
+ VaultVenue$inboundSchema.and(
92
+ z.object({ type: z.literal("VAULT") }).transform((v) => ({
93
+ type: v.type,
94
+ })),
95
+ ),
96
+ ]);
96
97
  /** @internal */
97
- export type MarketUnion$Outbound =
98
- | (AaveMarket$Outbound & { type: "AAVE" })
99
- | (VaultMarket$Outbound & { type: "VAULT" });
98
+ export type Venue$Outbound =
99
+ | (AaveVenue$Outbound & { type: "AAVE" })
100
+ | (VaultVenue$Outbound & { type: "VAULT" });
100
101
 
101
102
  /** @internal */
102
- export const MarketUnion$outboundSchema: z.ZodType<
103
- MarketUnion$Outbound,
103
+ export const Venue$outboundSchema: z.ZodType<
104
+ Venue$Outbound,
104
105
  z.ZodTypeDef,
105
- MarketUnion
106
+ Venue
106
107
  > = z.union([
107
- AaveMarket$outboundSchema.and(
108
+ AaveVenue$outboundSchema.and(
108
109
  z.object({ type: z.literal("AAVE") }).transform((v) => ({ type: v.type })),
109
110
  ),
110
- VaultMarket$outboundSchema.and(
111
+ VaultVenue$outboundSchema.and(
111
112
  z.object({ type: z.literal("VAULT") }).transform((v) => ({ type: v.type })),
112
113
  ),
113
114
  ]);
114
115
 
115
- export function marketUnionToJSON(marketUnion: MarketUnion): string {
116
- return JSON.stringify(MarketUnion$outboundSchema.parse(marketUnion));
116
+ export function venueToJSON(venue: Venue): string {
117
+ return JSON.stringify(Venue$outboundSchema.parse(venue));
117
118
  }
118
- export function marketUnionFromJSON(
119
+ export function venueFromJSON(
119
120
  jsonString: string,
120
- ): SafeParseResult<MarketUnion, SDKValidationError> {
121
+ ): SafeParseResult<Venue, SDKValidationError> {
121
122
  return safeParse(
122
123
  jsonString,
123
- (x) => MarketUnion$inboundSchema.parse(JSON.parse(x)),
124
- `Failed to parse 'MarketUnion' from JSON`,
124
+ (x) => Venue$inboundSchema.parse(JSON.parse(x)),
125
+ `Failed to parse 'Venue' from JSON`,
125
126
  );
126
127
  }
127
128
 
@@ -142,13 +143,13 @@ export const EarnManageRequest$inboundSchema: z.ZodType<
142
143
  > = z.object({
143
144
  owner: z.string(),
144
145
  chain: Chain$inboundSchema,
145
- market: z.union([
146
- AaveMarket$inboundSchema.and(
146
+ venue: z.union([
147
+ AaveVenue$inboundSchema.and(
147
148
  z.object({ type: z.literal("AAVE") }).transform((v) => ({
148
149
  type: v.type,
149
150
  })),
150
151
  ),
151
- VaultMarket$inboundSchema.and(
152
+ VaultVenue$inboundSchema.and(
152
153
  z.object({ type: z.literal("VAULT") }).transform((v) => ({
153
154
  type: v.type,
154
155
  })),
@@ -167,9 +168,9 @@ export const EarnManageRequest$inboundSchema: z.ZodType<
167
168
  export type EarnManageRequest$Outbound = {
168
169
  owner: string;
169
170
  chain: string;
170
- market:
171
- | (AaveMarket$Outbound & { type: "AAVE" })
172
- | (VaultMarket$Outbound & { type: "VAULT" });
171
+ venue:
172
+ | (AaveVenue$Outbound & { type: "AAVE" })
173
+ | (VaultVenue$Outbound & { type: "VAULT" });
173
174
  action: string;
174
175
  amount?: any | undefined;
175
176
  gas_sponsorship?: boolean | undefined;
@@ -184,13 +185,13 @@ export const EarnManageRequest$outboundSchema: z.ZodType<
184
185
  > = z.object({
185
186
  owner: z.string(),
186
187
  chain: Chain$outboundSchema,
187
- market: z.union([
188
- AaveMarket$outboundSchema.and(
188
+ venue: z.union([
189
+ AaveVenue$outboundSchema.and(
189
190
  z.object({ type: z.literal("AAVE") }).transform((v) => ({
190
191
  type: v.type,
191
192
  })),
192
193
  ),
193
- VaultMarket$outboundSchema.and(
194
+ VaultVenue$outboundSchema.and(
194
195
  z.object({ type: z.literal("VAULT") }).transform((v) => ({
195
196
  type: v.type,
196
197
  })),
@@ -8,7 +8,6 @@ export * from "./aaveborrowrequest.js";
8
8
  export * from "./aavehistoricaltransactionsresponse.js";
9
9
  export * from "./aaveliquiditychangeresponse.js";
10
10
  export * from "./aavelooprequest.js";
11
- export * from "./aavemarket.js";
12
11
  export * from "./aaveposition.js";
13
12
  export * from "./aaverateresponse.js";
14
13
  export * from "./aaverepayparams.js";
@@ -22,6 +21,7 @@ export * from "./aavesupportedtokensresponse.js";
22
21
  export * from "./aavetokenpriceresponse.js";
23
22
  export * from "./aaveuserpositionpertokenresponse.js";
24
23
  export * from "./aaveuserpositionsummaryresponse.js";
24
+ export * from "./aavevenue.js";
25
25
  export * from "./aavewithdrawparams.js";
26
26
  export * from "./aavewithdrawrequest.js";
27
27
  export * from "./aerodromelppositionsresponse.js";
@@ -218,8 +218,8 @@ export * from "./vaultdepositparams.js";
218
218
  export * from "./vaultdepositrequest.js";
219
219
  export * from "./vaultgetvaultresponse.js";
220
220
  export * from "./vaultinfo.js";
221
- export * from "./vaultmarket.js";
222
221
  export * from "./vaultslistresponse.js";
222
+ export * from "./vaultvenue.js";
223
223
  export * from "./vaultwithdrawparams.js";
224
224
  export * from "./vaultwithdrawrequest.js";
225
225
  export * from "./weeklyapys.js";
@@ -156,22 +156,6 @@ export type VaultInfo = {
156
156
  * List of vault features and capabilities.
157
157
  */
158
158
  features?: Array<string> | null | undefined;
159
- /**
160
- * Vault start date (first deposit).
161
- */
162
- startDate?: Date | null | undefined;
163
- /**
164
- * Vault end date (if applicable).
165
- */
166
- endDate?: Date | null | undefined;
167
- /**
168
- * Last update timestamp.
169
- */
170
- lastUpdatedAt?: Date | null | undefined;
171
- /**
172
- * Block number of last update.
173
- */
174
- lastUpdatedBlock?: number | null | undefined;
175
159
  };
176
160
 
177
161
  /** @internal */
@@ -216,16 +200,6 @@ export const VaultInfo$inboundSchema: z.ZodType<
216
200
  years: z.nullable(z.string()).optional(),
217
201
  event_count: z.nullable(z.number().int()).optional(),
218
202
  features: z.nullable(z.array(z.string())).optional(),
219
- start_date: z.nullable(
220
- z.string().datetime({ offset: true }).transform(v => new Date(v)),
221
- ).optional(),
222
- end_date: z.nullable(
223
- z.string().datetime({ offset: true }).transform(v => new Date(v)),
224
- ).optional(),
225
- last_updated_at: z.nullable(
226
- z.string().datetime({ offset: true }).transform(v => new Date(v)),
227
- ).optional(),
228
- last_updated_block: z.nullable(z.number().int()).optional(),
229
203
  }).transform((v) => {
230
204
  return remap$(v, {
231
205
  "chain_id": "chainId",
@@ -253,10 +227,6 @@ export const VaultInfo$inboundSchema: z.ZodType<
253
227
  "deposit_fee": "depositFee",
254
228
  "withdraw_fee": "withdrawFee",
255
229
  "event_count": "eventCount",
256
- "start_date": "startDate",
257
- "end_date": "endDate",
258
- "last_updated_at": "lastUpdatedAt",
259
- "last_updated_block": "lastUpdatedBlock",
260
230
  });
261
231
  });
262
232
  /** @internal */
@@ -297,10 +267,6 @@ export type VaultInfo$Outbound = {
297
267
  years?: string | null | undefined;
298
268
  event_count?: number | null | undefined;
299
269
  features?: Array<string> | null | undefined;
300
- start_date?: string | null | undefined;
301
- end_date?: string | null | undefined;
302
- last_updated_at?: string | null | undefined;
303
- last_updated_block?: number | null | undefined;
304
270
  };
305
271
 
306
272
  /** @internal */
@@ -345,11 +311,6 @@ export const VaultInfo$outboundSchema: z.ZodType<
345
311
  years: z.nullable(z.string()).optional(),
346
312
  eventCount: z.nullable(z.number().int()).optional(),
347
313
  features: z.nullable(z.array(z.string())).optional(),
348
- startDate: z.nullable(z.date().transform(v => v.toISOString())).optional(),
349
- endDate: z.nullable(z.date().transform(v => v.toISOString())).optional(),
350
- lastUpdatedAt: z.nullable(z.date().transform(v => v.toISOString()))
351
- .optional(),
352
- lastUpdatedBlock: z.nullable(z.number().int()).optional(),
353
314
  }).transform((v) => {
354
315
  return remap$(v, {
355
316
  chainId: "chain_id",
@@ -377,10 +338,6 @@ export const VaultInfo$outboundSchema: z.ZodType<
377
338
  depositFee: "deposit_fee",
378
339
  withdrawFee: "withdraw_fee",
379
340
  eventCount: "event_count",
380
- startDate: "start_date",
381
- endDate: "end_date",
382
- lastUpdatedAt: "last_updated_at",
383
- lastUpdatedBlock: "last_updated_block",
384
341
  });
385
342
  });
386
343
 
@@ -8,9 +8,9 @@ import { safeParse } from "../../lib/schemas.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
 
11
- export type VaultMarket = {
11
+ export type VaultVenue = {
12
12
  /**
13
- * The market type discriminator.
13
+ * The venue type discriminator.
14
14
  */
15
15
  type?: "VAULT" | undefined;
16
16
  /**
@@ -20,8 +20,8 @@ export type VaultMarket = {
20
20
  };
21
21
 
22
22
  /** @internal */
23
- export const VaultMarket$inboundSchema: z.ZodType<
24
- VaultMarket,
23
+ export const VaultVenue$inboundSchema: z.ZodType<
24
+ VaultVenue,
25
25
  z.ZodTypeDef,
26
26
  unknown
27
27
  > = z.object({
@@ -33,16 +33,16 @@ export const VaultMarket$inboundSchema: z.ZodType<
33
33
  });
34
34
  });
35
35
  /** @internal */
36
- export type VaultMarket$Outbound = {
36
+ export type VaultVenue$Outbound = {
37
37
  type: "VAULT";
38
38
  vault_address: string;
39
39
  };
40
40
 
41
41
  /** @internal */
42
- export const VaultMarket$outboundSchema: z.ZodType<
43
- VaultMarket$Outbound,
42
+ export const VaultVenue$outboundSchema: z.ZodType<
43
+ VaultVenue$Outbound,
44
44
  z.ZodTypeDef,
45
- VaultMarket
45
+ VaultVenue
46
46
  > = z.object({
47
47
  type: z.literal("VAULT"),
48
48
  vaultAddress: z.string(),
@@ -52,15 +52,15 @@ export const VaultMarket$outboundSchema: z.ZodType<
52
52
  });
53
53
  });
54
54
 
55
- export function vaultMarketToJSON(vaultMarket: VaultMarket): string {
56
- return JSON.stringify(VaultMarket$outboundSchema.parse(vaultMarket));
55
+ export function vaultVenueToJSON(vaultVenue: VaultVenue): string {
56
+ return JSON.stringify(VaultVenue$outboundSchema.parse(vaultVenue));
57
57
  }
58
- export function vaultMarketFromJSON(
58
+ export function vaultVenueFromJSON(
59
59
  jsonString: string,
60
- ): SafeParseResult<VaultMarket, SDKValidationError> {
60
+ ): SafeParseResult<VaultVenue, SDKValidationError> {
61
61
  return safeParse(
62
62
  jsonString,
63
- (x) => VaultMarket$inboundSchema.parse(JSON.parse(x)),
64
- `Failed to parse 'VaultMarket' from JSON`,
63
+ (x) => VaultVenue$inboundSchema.parse(JSON.parse(x)),
64
+ `Failed to parse 'VaultVenue' from JSON`,
65
65
  );
66
66
  }
@@ -1,25 +0,0 @@
1
- import * as z from "zod/v3";
2
- import { Result as SafeParseResult } from "../../types/fp.js";
3
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
- export type AaveMarket = {
5
- /**
6
- * The market type discriminator.
7
- */
8
- type?: "AAVE" | undefined;
9
- /**
10
- * The reserve token for the Aave pool you are interacting with.
11
- */
12
- token: string;
13
- };
14
- /** @internal */
15
- export declare const AaveMarket$inboundSchema: z.ZodType<AaveMarket, z.ZodTypeDef, unknown>;
16
- /** @internal */
17
- export type AaveMarket$Outbound = {
18
- type: "AAVE";
19
- token: string;
20
- };
21
- /** @internal */
22
- export declare const AaveMarket$outboundSchema: z.ZodType<AaveMarket$Outbound, z.ZodTypeDef, AaveMarket>;
23
- export declare function aaveMarketToJSON(aaveMarket: AaveMarket): string;
24
- export declare function aaveMarketFromJSON(jsonString: string): SafeParseResult<AaveMarket, SDKValidationError>;
25
- //# sourceMappingURL=aavemarket.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"aavemarket.d.ts","sourceRoot":"","sources":["../../../../src/models/components/aavemarket.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,MAAM,MAAM,UAAU,GAAG;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC1B;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,wBAAwB,EAAE,CAAC,CAAC,OAAO,CAC9C,UAAU,EACV,CAAC,CAAC,UAAU,EACZ,OAAO,CAIP,CAAC;AACH,gBAAgB;AAChB,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAC/C,mBAAmB,EACnB,CAAC,CAAC,UAAU,EACZ,UAAU,CAIV,CAAC;AAEH,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,UAAU,GAAG,MAAM,CAE/D;AACD,wBAAgB,kBAAkB,CAChC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,UAAU,EAAE,kBAAkB,CAAC,CAMjD"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"aavemarket.js","sourceRoot":"","sources":["../../../../src/models/components/aavemarket.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2CH,4CAEC;AACD,gDAQC;AApDD,0CAA4B;AAC5B,qDAAiD;AAejD,gBAAgB;AACH,QAAA,wBAAwB,GAIjC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE;IAClD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE;CAClB,CAAC,CAAC;AAOH,gBAAgB;AACH,QAAA,yBAAyB,GAIlC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC;IACvB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE;CAClB,CAAC,CAAC;AAEH,SAAgB,gBAAgB,CAAC,UAAsB;IACrD,OAAO,IAAI,CAAC,SAAS,CAAC,iCAAyB,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC;AACrE,CAAC;AACD,SAAgB,kBAAkB,CAChC,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,gCAAwB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACpD,wCAAwC,CACzC,CAAC;AACJ,CAAC"}
@@ -1,25 +0,0 @@
1
- import * as z from "zod/v3";
2
- import { Result as SafeParseResult } from "../../types/fp.js";
3
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
- export type VaultMarket = {
5
- /**
6
- * The market type discriminator.
7
- */
8
- type?: "VAULT" | undefined;
9
- /**
10
- * The vault address you are interacting with for this action.
11
- */
12
- vaultAddress: string;
13
- };
14
- /** @internal */
15
- export declare const VaultMarket$inboundSchema: z.ZodType<VaultMarket, z.ZodTypeDef, unknown>;
16
- /** @internal */
17
- export type VaultMarket$Outbound = {
18
- type: "VAULT";
19
- vault_address: string;
20
- };
21
- /** @internal */
22
- export declare const VaultMarket$outboundSchema: z.ZodType<VaultMarket$Outbound, z.ZodTypeDef, VaultMarket>;
23
- export declare function vaultMarketToJSON(vaultMarket: VaultMarket): string;
24
- export declare function vaultMarketFromJSON(jsonString: string): SafeParseResult<VaultMarket, SDKValidationError>;
25
- //# sourceMappingURL=vaultmarket.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"vaultmarket.d.ts","sourceRoot":"","sources":["../../../../src/models/components/vaultmarket.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAG5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,MAAM,MAAM,WAAW,GAAG;IACxB;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC3B;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAC/C,WAAW,EACX,CAAC,CAAC,UAAU,EACZ,OAAO,CAQP,CAAC;AACH,gBAAgB;AAChB,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,OAAO,CAAC;IACd,aAAa,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,0BAA0B,EAAE,CAAC,CAAC,OAAO,CAChD,oBAAoB,EACpB,CAAC,CAAC,UAAU,EACZ,WAAW,CAQX,CAAC;AAEH,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,WAAW,GAAG,MAAM,CAElE;AACD,wBAAgB,mBAAmB,CACjC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,WAAW,EAAE,kBAAkB,CAAC,CAMlD"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"vaultmarket.js","sourceRoot":"","sources":["../../../../src/models/components/vaultmarket.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoDH,8CAEC;AACD,kDAQC;AA7DD,0CAA4B;AAC5B,2DAA0D;AAC1D,qDAAiD;AAejD,gBAAgB;AACH,QAAA,yBAAyB,GAIlC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE;IACpD,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE;CAC1B,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,eAAe,EAAE,cAAc;KAChC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAOH,gBAAgB;AACH,QAAA,0BAA0B,GAInC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;IACxB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE;CACzB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,YAAY,EAAE,eAAe;KAC9B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH,SAAgB,iBAAiB,CAAC,WAAwB;IACxD,OAAO,IAAI,CAAC,SAAS,CAAC,kCAA0B,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC;AACvE,CAAC;AACD,SAAgB,mBAAmB,CACjC,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,iCAAyB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACrD,yCAAyC,CAC1C,CAAC;AACJ,CAAC"}