@compass-labs/api-sdk 0.2.2 → 0.2.3
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.
- package/README.md +2 -2
- package/bin/mcp-server.js +40 -114
- package/bin/mcp-server.js.map +14 -16
- package/dist/commonjs/funcs/universalAllowanceSet.d.ts +1 -1
- package/dist/commonjs/funcs/universalAllowanceSet.js +1 -1
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/mcp-server/tools/universalAllowanceSet.js +1 -1
- package/dist/commonjs/models/components/increaseallowanceparams.d.ts +29 -10
- package/dist/commonjs/models/components/increaseallowanceparams.d.ts.map +1 -1
- package/dist/commonjs/models/components/increaseallowanceparams.js +26 -3
- package/dist/commonjs/models/components/increaseallowanceparams.js.map +1 -1
- package/dist/commonjs/models/components/increaseallowancerequest.d.ts +29 -10
- package/dist/commonjs/models/components/increaseallowancerequest.d.ts.map +1 -1
- package/dist/commonjs/models/components/increaseallowancerequest.js +26 -3
- package/dist/commonjs/models/components/increaseallowancerequest.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +0 -2
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +0 -2
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/multicallactiontype.d.ts +0 -3
- package/dist/commonjs/models/components/multicallactiontype.d.ts.map +1 -1
- package/dist/commonjs/models/components/multicallactiontype.js +0 -1
- package/dist/commonjs/models/components/multicallactiontype.js.map +1 -1
- package/dist/commonjs/models/components/tokentransferrequest.d.ts +11 -11
- package/dist/commonjs/models/components/tokentransferrequest.d.ts.map +1 -1
- package/dist/commonjs/models/components/tokentransferrequest.js +16 -17
- package/dist/commonjs/models/components/tokentransferrequest.js.map +1 -1
- package/dist/commonjs/models/components/useroperation.d.ts +4 -5
- package/dist/commonjs/models/components/useroperation.d.ts.map +1 -1
- package/dist/commonjs/models/components/useroperation.js +0 -5
- package/dist/commonjs/models/components/useroperation.js.map +1 -1
- package/dist/commonjs/sdk/universal.d.ts +1 -1
- package/dist/commonjs/sdk/universal.js +1 -1
- package/dist/esm/funcs/universalAllowanceSet.d.ts +1 -1
- package/dist/esm/funcs/universalAllowanceSet.js +1 -1
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/mcp-server/tools/universalAllowanceSet.js +1 -1
- package/dist/esm/models/components/increaseallowanceparams.d.ts +29 -10
- package/dist/esm/models/components/increaseallowanceparams.d.ts.map +1 -1
- package/dist/esm/models/components/increaseallowanceparams.js +23 -2
- package/dist/esm/models/components/increaseallowanceparams.js.map +1 -1
- package/dist/esm/models/components/increaseallowancerequest.d.ts +29 -10
- package/dist/esm/models/components/increaseallowancerequest.d.ts.map +1 -1
- package/dist/esm/models/components/increaseallowancerequest.js +23 -2
- package/dist/esm/models/components/increaseallowancerequest.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +0 -2
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +0 -2
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/multicallactiontype.d.ts +0 -3
- package/dist/esm/models/components/multicallactiontype.d.ts.map +1 -1
- package/dist/esm/models/components/multicallactiontype.js +0 -1
- package/dist/esm/models/components/multicallactiontype.js.map +1 -1
- package/dist/esm/models/components/tokentransferrequest.d.ts +11 -11
- package/dist/esm/models/components/tokentransferrequest.d.ts.map +1 -1
- package/dist/esm/models/components/tokentransferrequest.js +13 -14
- package/dist/esm/models/components/tokentransferrequest.js.map +1 -1
- package/dist/esm/models/components/useroperation.d.ts +4 -5
- package/dist/esm/models/components/useroperation.d.ts.map +1 -1
- package/dist/esm/models/components/useroperation.js +0 -5
- package/dist/esm/models/components/useroperation.js.map +1 -1
- package/dist/esm/sdk/universal.d.ts +1 -1
- package/dist/esm/sdk/universal.js +1 -1
- package/docs/sdks/universal/README.md +3 -3
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/universalAllowanceSet.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/mcp-server/tools/universalAllowanceSet.ts +1 -1
- package/src/models/components/increaseallowanceparams.ts +62 -12
- package/src/models/components/increaseallowancerequest.ts +62 -12
- package/src/models/components/index.ts +0 -2
- package/src/models/components/multicallactiontype.ts +0 -1
- package/src/models/components/tokentransferrequest.ts +27 -20
- package/src/models/components/useroperation.ts +0 -14
- package/src/sdk/universal.ts +1 -1
- package/dist/commonjs/models/components/contractname.d.ts +0 -117
- package/dist/commonjs/models/components/contractname.d.ts.map +0 -1
- package/dist/commonjs/models/components/contractname.js +0 -92
- package/dist/commonjs/models/components/contractname.js.map +0 -1
- package/dist/commonjs/models/components/increaseallowanceanyparams.d.ts +0 -80
- package/dist/commonjs/models/components/increaseallowanceanyparams.d.ts.map +0 -1
- package/dist/commonjs/models/components/increaseallowanceanyparams.js +0 -107
- package/dist/commonjs/models/components/increaseallowanceanyparams.js.map +0 -1
- package/dist/esm/models/components/contractname.d.ts +0 -117
- package/dist/esm/models/components/contractname.d.ts.map +0 -1
- package/dist/esm/models/components/contractname.js +0 -56
- package/dist/esm/models/components/contractname.js.map +0 -1
- package/dist/esm/models/components/increaseallowanceanyparams.d.ts +0 -80
- package/dist/esm/models/components/increaseallowanceanyparams.d.ts.map +0 -1
- package/dist/esm/models/components/increaseallowanceanyparams.js +0 -67
- package/dist/esm/models/components/increaseallowanceanyparams.js.map +0 -1
- package/src/models/components/contractname.ts +0 -71
- package/src/models/components/increaseallowanceanyparams.ts +0 -169
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod";
|
|
6
|
-
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
-
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
-
import {
|
|
11
|
-
ContractName,
|
|
12
|
-
ContractName$inboundSchema,
|
|
13
|
-
ContractName$outboundSchema,
|
|
14
|
-
} from "./contractname.js";
|
|
15
|
-
import {
|
|
16
|
-
TokenEnum,
|
|
17
|
-
TokenEnum$inboundSchema,
|
|
18
|
-
TokenEnum$outboundSchema,
|
|
19
|
-
} from "./tokenenum.js";
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* The amount of tokens to increase the allowance by.
|
|
23
|
-
*/
|
|
24
|
-
export type IncreaseAllowanceAnyParamsAmount = number | string;
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Parameters model for increasing allowance for any arbitrary ERC20 address.
|
|
28
|
-
*/
|
|
29
|
-
export type IncreaseAllowanceAnyParams = {
|
|
30
|
-
/**
|
|
31
|
-
* A class representing the token.
|
|
32
|
-
*
|
|
33
|
-
* @remarks
|
|
34
|
-
*
|
|
35
|
-
* This class is used to represent the token in the system. Notice individual
|
|
36
|
-
* endpoints' documentation where per chain tokens are presented.
|
|
37
|
-
*/
|
|
38
|
-
token: TokenEnum;
|
|
39
|
-
/**
|
|
40
|
-
* Select the protocol.
|
|
41
|
-
*
|
|
42
|
-
* @remarks
|
|
43
|
-
*
|
|
44
|
-
* E.g. for increasing ERC-20 allowance.
|
|
45
|
-
*/
|
|
46
|
-
contractName: ContractName;
|
|
47
|
-
/**
|
|
48
|
-
* The amount of tokens to increase the allowance by.
|
|
49
|
-
*/
|
|
50
|
-
amount: number | string;
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
/** @internal */
|
|
54
|
-
export const IncreaseAllowanceAnyParamsAmount$inboundSchema: z.ZodType<
|
|
55
|
-
IncreaseAllowanceAnyParamsAmount,
|
|
56
|
-
z.ZodTypeDef,
|
|
57
|
-
unknown
|
|
58
|
-
> = z.union([z.number(), z.string()]);
|
|
59
|
-
|
|
60
|
-
/** @internal */
|
|
61
|
-
export type IncreaseAllowanceAnyParamsAmount$Outbound = number | string;
|
|
62
|
-
|
|
63
|
-
/** @internal */
|
|
64
|
-
export const IncreaseAllowanceAnyParamsAmount$outboundSchema: z.ZodType<
|
|
65
|
-
IncreaseAllowanceAnyParamsAmount$Outbound,
|
|
66
|
-
z.ZodTypeDef,
|
|
67
|
-
IncreaseAllowanceAnyParamsAmount
|
|
68
|
-
> = z.union([z.number(), z.string()]);
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* @internal
|
|
72
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
73
|
-
*/
|
|
74
|
-
export namespace IncreaseAllowanceAnyParamsAmount$ {
|
|
75
|
-
/** @deprecated use `IncreaseAllowanceAnyParamsAmount$inboundSchema` instead. */
|
|
76
|
-
export const inboundSchema = IncreaseAllowanceAnyParamsAmount$inboundSchema;
|
|
77
|
-
/** @deprecated use `IncreaseAllowanceAnyParamsAmount$outboundSchema` instead. */
|
|
78
|
-
export const outboundSchema = IncreaseAllowanceAnyParamsAmount$outboundSchema;
|
|
79
|
-
/** @deprecated use `IncreaseAllowanceAnyParamsAmount$Outbound` instead. */
|
|
80
|
-
export type Outbound = IncreaseAllowanceAnyParamsAmount$Outbound;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
export function increaseAllowanceAnyParamsAmountToJSON(
|
|
84
|
-
increaseAllowanceAnyParamsAmount: IncreaseAllowanceAnyParamsAmount,
|
|
85
|
-
): string {
|
|
86
|
-
return JSON.stringify(
|
|
87
|
-
IncreaseAllowanceAnyParamsAmount$outboundSchema.parse(
|
|
88
|
-
increaseAllowanceAnyParamsAmount,
|
|
89
|
-
),
|
|
90
|
-
);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
export function increaseAllowanceAnyParamsAmountFromJSON(
|
|
94
|
-
jsonString: string,
|
|
95
|
-
): SafeParseResult<IncreaseAllowanceAnyParamsAmount, SDKValidationError> {
|
|
96
|
-
return safeParse(
|
|
97
|
-
jsonString,
|
|
98
|
-
(x) => IncreaseAllowanceAnyParamsAmount$inboundSchema.parse(JSON.parse(x)),
|
|
99
|
-
`Failed to parse 'IncreaseAllowanceAnyParamsAmount' from JSON`,
|
|
100
|
-
);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
/** @internal */
|
|
104
|
-
export const IncreaseAllowanceAnyParams$inboundSchema: z.ZodType<
|
|
105
|
-
IncreaseAllowanceAnyParams,
|
|
106
|
-
z.ZodTypeDef,
|
|
107
|
-
unknown
|
|
108
|
-
> = z.object({
|
|
109
|
-
token: TokenEnum$inboundSchema,
|
|
110
|
-
contract_name: ContractName$inboundSchema,
|
|
111
|
-
amount: z.union([z.number(), z.string()]),
|
|
112
|
-
}).transform((v) => {
|
|
113
|
-
return remap$(v, {
|
|
114
|
-
"contract_name": "contractName",
|
|
115
|
-
});
|
|
116
|
-
});
|
|
117
|
-
|
|
118
|
-
/** @internal */
|
|
119
|
-
export type IncreaseAllowanceAnyParams$Outbound = {
|
|
120
|
-
token: string;
|
|
121
|
-
contract_name: string;
|
|
122
|
-
amount: number | string;
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
/** @internal */
|
|
126
|
-
export const IncreaseAllowanceAnyParams$outboundSchema: z.ZodType<
|
|
127
|
-
IncreaseAllowanceAnyParams$Outbound,
|
|
128
|
-
z.ZodTypeDef,
|
|
129
|
-
IncreaseAllowanceAnyParams
|
|
130
|
-
> = z.object({
|
|
131
|
-
token: TokenEnum$outboundSchema,
|
|
132
|
-
contractName: ContractName$outboundSchema,
|
|
133
|
-
amount: z.union([z.number(), z.string()]),
|
|
134
|
-
}).transform((v) => {
|
|
135
|
-
return remap$(v, {
|
|
136
|
-
contractName: "contract_name",
|
|
137
|
-
});
|
|
138
|
-
});
|
|
139
|
-
|
|
140
|
-
/**
|
|
141
|
-
* @internal
|
|
142
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
143
|
-
*/
|
|
144
|
-
export namespace IncreaseAllowanceAnyParams$ {
|
|
145
|
-
/** @deprecated use `IncreaseAllowanceAnyParams$inboundSchema` instead. */
|
|
146
|
-
export const inboundSchema = IncreaseAllowanceAnyParams$inboundSchema;
|
|
147
|
-
/** @deprecated use `IncreaseAllowanceAnyParams$outboundSchema` instead. */
|
|
148
|
-
export const outboundSchema = IncreaseAllowanceAnyParams$outboundSchema;
|
|
149
|
-
/** @deprecated use `IncreaseAllowanceAnyParams$Outbound` instead. */
|
|
150
|
-
export type Outbound = IncreaseAllowanceAnyParams$Outbound;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
export function increaseAllowanceAnyParamsToJSON(
|
|
154
|
-
increaseAllowanceAnyParams: IncreaseAllowanceAnyParams,
|
|
155
|
-
): string {
|
|
156
|
-
return JSON.stringify(
|
|
157
|
-
IncreaseAllowanceAnyParams$outboundSchema.parse(increaseAllowanceAnyParams),
|
|
158
|
-
);
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export function increaseAllowanceAnyParamsFromJSON(
|
|
162
|
-
jsonString: string,
|
|
163
|
-
): SafeParseResult<IncreaseAllowanceAnyParams, SDKValidationError> {
|
|
164
|
-
return safeParse(
|
|
165
|
-
jsonString,
|
|
166
|
-
(x) => IncreaseAllowanceAnyParams$inboundSchema.parse(JSON.parse(x)),
|
|
167
|
-
`Failed to parse 'IncreaseAllowanceAnyParams' from JSON`,
|
|
168
|
-
);
|
|
169
|
-
}
|