opentool 0.8.9 → 0.8.11
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 +3 -9
- package/dist/cli/index.d.ts +3 -3
- package/dist/cli/index.js +37 -45
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +7 -5
- package/dist/index.js.map +1 -1
- package/dist/{validate-M_QdV0J3.d.ts → validate-CilU0rkD.d.ts} +21 -19
- package/package.json +1 -1
- package/templates/base/package.json +1 -1
- package/templates/base/tools/aave-stake.ts +1 -4
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Server } from '@modelcontextprotocol/sdk/server/index.js';
|
|
2
|
-
import { I as InternalToolDefinition, T as ToolResponse } from './validate-
|
|
3
|
-
export { B as BuildConfig, m as BuildMetadata, C as CronSpec, q as GetHandler, H as HTTP_METHODS, f as HttpHandlerDefinition, e as HttpMethod, h as McpConfig, M as Metadata, N as NormalizedSchedule, P as PaymentConfig, r as PostHandler, S as ScheduleType, i as ServerConfig, j as Tool, n as ToolCategory, d as ToolContent, k as ToolMetadataOverrides, u as ToolModule, s as ToolModuleGET, t as ToolModulePOST,
|
|
2
|
+
import { I as InternalToolDefinition, T as ToolResponse } from './validate-CilU0rkD.js';
|
|
3
|
+
export { B as BuildConfig, m as BuildMetadata, o as ConnectedApp, C as CronSpec, q as GetHandler, H as HTTP_METHODS, f as HttpHandlerDefinition, e as HttpMethod, h as McpConfig, M as Metadata, N as NormalizedSchedule, P as PaymentConfig, r as PostHandler, S as ScheduleType, i as ServerConfig, j as Tool, n as ToolCategory, d as ToolContent, k as ToolMetadataOverrides, u as ToolModule, s as ToolModuleGET, t as ToolModulePOST, p as ToolProfile, b as generateMetadata, g as generateMetadataCommand, l as loadAndValidateTools, v as validateCommand } from './validate-CilU0rkD.js';
|
|
4
4
|
export { CurrencySpec, DEFAULT_FACILITATOR, DefineX402PaymentConfig, EIP3009Authorization, PAYMENT_HEADERS, RequireX402PaymentOptions, RequireX402PaymentOutcome, RequireX402PaymentSuccess, SUPPORTED_CURRENCIES, X402BrowserClient, X402BrowserClientConfig, X402Client, X402ClientConfig, X402FacilitatorConfig, X402PayRequest, X402PayResult, X402Payment, X402PaymentContext, X402PaymentDefinition, X402PaymentRequiredError, X402VerificationResult, defineX402Payment, getX402PaymentContext, payX402, payX402WithWallet, requireX402Payment, withX402Payment } from './x402/index.js';
|
|
5
5
|
export { DEFAULT_CHAIN, DEFAULT_TOKENS, chains, getRpcUrl, registry, tokens, wallet, walletToolkit } from './wallet/index.js';
|
|
6
6
|
export { HyperliquidApiError, HyperliquidApproveBuilderFeeOptions, HyperliquidApproveBuilderFeeResponse, HyperliquidBuilderApprovalError, HyperliquidBuilderApprovalRecordInput, HyperliquidBuilderFee, HyperliquidClearinghouseState, HyperliquidDepositResult, HyperliquidEnvironment, HyperliquidExchangeClient, HyperliquidExchangeResponse, HyperliquidGrouping, HyperliquidGuardError, HyperliquidInfoClient, HyperliquidOrderIntent, HyperliquidOrderOptions, HyperliquidOrderResponse, HyperliquidOrderStatus, HyperliquidTermsError, HyperliquidTermsRecordInput, HyperliquidTriggerOptions, HyperliquidTriggerType, HyperliquidWithdrawResult, NonceSource, __hyperliquidInternals, approveHyperliquidBuilderFee, batchModifyHyperliquidOrders, cancelAllHyperliquidOrders, cancelHyperliquidOrders, cancelHyperliquidOrdersByCloid, cancelHyperliquidTwapOrder, createHyperliquidSubAccount, createMonotonicNonceFactory, depositToHyperliquidBridge, fetchHyperliquidAssetCtxs, fetchHyperliquidClearinghouseState, fetchHyperliquidFrontendOpenOrders, fetchHyperliquidHistoricalOrders, fetchHyperliquidMeta, fetchHyperliquidMetaAndAssetCtxs, fetchHyperliquidOpenOrders, fetchHyperliquidOrderStatus, fetchHyperliquidPreTransferCheck, fetchHyperliquidSpotAssetCtxs, fetchHyperliquidSpotClearinghouseState, fetchHyperliquidSpotMeta, fetchHyperliquidSpotMetaAndAssetCtxs, fetchHyperliquidUserFills, fetchHyperliquidUserFillsByTime, fetchHyperliquidUserRateLimit, getHyperliquidMaxBuilderFee, modifyHyperliquidOrder, placeHyperliquidOrder, placeHyperliquidTwapOrder, recordHyperliquidBuilderApproval, recordHyperliquidTermsAcceptance, reserveHyperliquidRequestWeight, scheduleHyperliquidCancel, sendHyperliquidSpot, setHyperliquidPortfolioMargin, transferHyperliquidSubAccount, updateHyperliquidIsolatedMargin, updateHyperliquidLeverage, withdrawFromHyperliquid } from './adapters/hyperliquid/index.js';
|
package/dist/index.js
CHANGED
|
@@ -4872,7 +4872,7 @@ var DiscoveryMetadataSchema = z.object({
|
|
|
4872
4872
|
compatibility: z.record(z.string(), z.any()).optional(),
|
|
4873
4873
|
documentation: z.union([z.string(), z.array(z.string())]).optional()
|
|
4874
4874
|
}).catchall(z.any());
|
|
4875
|
-
var ToolCategorySchema = z.enum(["strategy", "tracker", "
|
|
4875
|
+
var ToolCategorySchema = z.enum(["strategy", "tracker", "orchestrator"]);
|
|
4876
4876
|
var ToolMetadataOverridesSchema = z.object({
|
|
4877
4877
|
name: z.string().optional(),
|
|
4878
4878
|
description: z.string().optional(),
|
|
@@ -5029,9 +5029,10 @@ var METADATA_ENTRY = "metadata.ts";
|
|
|
5029
5029
|
async function loadMetadata2(projectRoot) {
|
|
5030
5030
|
const absPath = path6.join(projectRoot, METADATA_ENTRY);
|
|
5031
5031
|
if (!fs2.existsSync(absPath)) {
|
|
5032
|
-
|
|
5033
|
-
|
|
5034
|
-
|
|
5032
|
+
return {
|
|
5033
|
+
metadata: MetadataSchema.parse({}),
|
|
5034
|
+
sourcePath: "smart defaults (metadata.ts missing)"
|
|
5035
|
+
};
|
|
5035
5036
|
}
|
|
5036
5037
|
const tempDir = path6.join(projectRoot, ".opentool-temp");
|
|
5037
5038
|
if (fs2.existsSync(tempDir)) {
|
|
@@ -5387,7 +5388,7 @@ async function loadAndValidateTools(toolsDir, options = {}) {
|
|
|
5387
5388
|
const schedule = toolModule?.profile?.schedule;
|
|
5388
5389
|
const profileNotifyEmail = typeof toolModule?.profile?.notifyEmail === "boolean" ? toolModule.profile.notifyEmail : void 0;
|
|
5389
5390
|
const profileCategoryRaw = typeof toolModule?.profile?.category === "string" ? toolModule.profile.category : void 0;
|
|
5390
|
-
const allowedProfileCategories = /* @__PURE__ */ new Set(["strategy", "tracker", "
|
|
5391
|
+
const allowedProfileCategories = /* @__PURE__ */ new Set(["strategy", "tracker", "orchestrator"]);
|
|
5391
5392
|
if (profileCategoryRaw && !allowedProfileCategories.has(profileCategoryRaw)) {
|
|
5392
5393
|
throw new Error(
|
|
5393
5394
|
`${file}: profile.category must be one of ${Array.from(allowedProfileCategories).join(", ")}`
|
|
@@ -5462,6 +5463,7 @@ async function loadAndValidateTools(toolsDir, options = {}) {
|
|
|
5462
5463
|
handler: async (params) => adapter(params),
|
|
5463
5464
|
payment: paymentExport ?? null,
|
|
5464
5465
|
schedule: normalizedSchedule,
|
|
5466
|
+
profile: toolModule?.profile && typeof toolModule.profile === "object" ? toolModule.profile : null,
|
|
5465
5467
|
...profileNotifyEmail !== void 0 ? { notifyEmail: profileNotifyEmail } : {},
|
|
5466
5468
|
profileDescription: typeof toolModule?.profile?.description === "string" ? toolModule.profile?.description ?? null : null,
|
|
5467
5469
|
...profileCategoryRaw ? { profileCategory: profileCategoryRaw } : {}
|