@runpod/mcp-server 4.5.0 → 4.6.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.
- package/CHANGELOG.md +17 -0
- package/README.md +4 -4
- package/dist/http.cjs +322 -62
- package/dist/http.cjs.map +1 -1
- package/dist/http.d.cts +6 -1
- package/dist/http.d.ts +6 -1
- package/dist/http.mjs +321 -62
- package/dist/http.mjs.map +1 -1
- package/dist/stdio.cjs +305 -57
- package/dist/stdio.cjs.map +1 -1
- package/dist/stdio.mjs +305 -57
- package/dist/stdio.mjs.map +1 -1
- package/package.json +2 -1
package/dist/stdio.cjs
CHANGED
|
@@ -1183,7 +1183,7 @@ var import_stdio = require("@modelcontextprotocol/sdk/server/stdio.js");
|
|
|
1183
1183
|
|
|
1184
1184
|
// src/server.ts
|
|
1185
1185
|
var SERVER_NAME = "Runpod API Server";
|
|
1186
|
-
var SERVER_VERSION = true ? "4.
|
|
1186
|
+
var SERVER_VERSION = true ? "4.6.0" : "dev";
|
|
1187
1187
|
|
|
1188
1188
|
// src/specgen/server.ts
|
|
1189
1189
|
var import_server3 = require("@modelcontextprotocol/sdk/server/index.js");
|
|
@@ -1513,6 +1513,7 @@ var generatedTools = [
|
|
|
1513
1513
|
title: "Create cluster",
|
|
1514
1514
|
operationId: "createCluster",
|
|
1515
1515
|
description: "Create an instant cluster (multiple pods with high-speed interconnect). BILLABLE from creation for every pod in the cluster: it rents compute.podCount identical pods at once, each with compute.gpuCountPerPod GPUs of compute.gpuTypeId \u2014 state the hourly price for the total GPU count (podCount * gpuCountPerPod, priced from the catalog tools) and create only after the user's explicit go on that quoted shape and total hourly price. Verify GPU stock first via the catalog tools. The compute shape and type are fixed at creation; only the name can be changed later. The container configuration applies to every pod, and templateId is the only private-image path \u2014 a bare registry property is rejected. Delete with delete-cluster when finished.",
|
|
1516
|
+
directoryDescription: "Create an Instant Cluster: compute.podCount identical Pods joined by a high-speed interconnect, each with compute.gpuCountPerPod GPUs of compute.gpuTypeId. Billable from creation for every Pod in the cluster, at the GPU type's hourly price times the total GPU count. The compute shape and type are fixed at creation; only the name can change later. The container configuration applies to every Pod, and templateId is the only way to use a private image; a bare registry property is rejected.",
|
|
1516
1517
|
method: "POST",
|
|
1517
1518
|
path: "/v2/clusters",
|
|
1518
1519
|
params: [],
|
|
@@ -1528,7 +1529,8 @@ var generatedTools = [
|
|
|
1528
1529
|
type: "object",
|
|
1529
1530
|
properties: {
|
|
1530
1531
|
body: {
|
|
1531
|
-
$ref: "#/$defs/CreateClusterRequest"
|
|
1532
|
+
$ref: "#/$defs/CreateClusterRequest",
|
|
1533
|
+
type: "object"
|
|
1532
1534
|
}
|
|
1533
1535
|
},
|
|
1534
1536
|
required: ["body"],
|
|
@@ -1765,7 +1767,8 @@ var generatedTools = [
|
|
|
1765
1767
|
type: "object",
|
|
1766
1768
|
properties: {
|
|
1767
1769
|
body: {
|
|
1768
|
-
$ref: "#/$defs/CreateDelegationRequest"
|
|
1770
|
+
$ref: "#/$defs/CreateDelegationRequest",
|
|
1771
|
+
type: "object"
|
|
1769
1772
|
}
|
|
1770
1773
|
},
|
|
1771
1774
|
required: ["body"],
|
|
@@ -1797,6 +1800,7 @@ var generatedTools = [
|
|
|
1797
1800
|
title: "Create endpoint",
|
|
1798
1801
|
operationId: "createEndpoint",
|
|
1799
1802
|
description: "Create a serverless endpoint. BILLABLE: state the worker's hourly price (from the catalog tools) before creating. Worker hardware is one of two choices: the gpu object (gpu.pools takes serverless pool ids from the catalog, e.g. ADA_24, never display names; gpu.count sets GPUs per worker) or the cpu array of CPU flavor configurations for a CPU endpoint. type and scaling are required and fix the request-routing model. Workers cold-start on the first job: expect minutes, poll with get-job-status wait.",
|
|
1803
|
+
directoryDescription: "Create a Serverless endpoint. Billable while its workers run, at the worker's hourly price. Worker hardware is either the gpu object (gpu.pools takes Serverless pool ids such as ADA_24, and gpu.count sets GPUs per worker) or the cpu array of CPU flavor configurations. type and scaling are required and set the request-routing model. Workers cold-start on their first job, which commonly takes minutes.",
|
|
1800
1804
|
method: "POST",
|
|
1801
1805
|
path: "/v2/serverless",
|
|
1802
1806
|
params: [],
|
|
@@ -1812,7 +1816,8 @@ var generatedTools = [
|
|
|
1812
1816
|
type: "object",
|
|
1813
1817
|
properties: {
|
|
1814
1818
|
body: {
|
|
1815
|
-
$ref: "#/$defs/CreateEndpointRequest"
|
|
1819
|
+
$ref: "#/$defs/CreateEndpointRequest",
|
|
1820
|
+
type: "object"
|
|
1816
1821
|
}
|
|
1817
1822
|
},
|
|
1818
1823
|
required: ["body"],
|
|
@@ -2257,7 +2262,8 @@ var generatedTools = [
|
|
|
2257
2262
|
type: "object",
|
|
2258
2263
|
properties: {
|
|
2259
2264
|
body: {
|
|
2260
|
-
$ref: "#/$defs/CreateGlobalVolumeRequest"
|
|
2265
|
+
$ref: "#/$defs/CreateGlobalVolumeRequest",
|
|
2266
|
+
type: "object"
|
|
2261
2267
|
}
|
|
2262
2268
|
},
|
|
2263
2269
|
required: ["body"],
|
|
@@ -2299,7 +2305,8 @@ var generatedTools = [
|
|
|
2299
2305
|
type: "object",
|
|
2300
2306
|
properties: {
|
|
2301
2307
|
body: {
|
|
2302
|
-
$ref: "#/$defs/CreateNetworkVolumeRequest"
|
|
2308
|
+
$ref: "#/$defs/CreateNetworkVolumeRequest",
|
|
2309
|
+
type: "object"
|
|
2303
2310
|
}
|
|
2304
2311
|
},
|
|
2305
2312
|
required: ["body"],
|
|
@@ -2351,6 +2358,7 @@ var generatedTools = [
|
|
|
2351
2358
|
title: "Create Pod",
|
|
2352
2359
|
operationId: "createPod",
|
|
2353
2360
|
description: 'Rent a GPU/CPU pod. BILLABLE from creation until stop/terminate: state the hourly price before creating. GPU selection is the gpu object: gpu.id takes a catalog GPU type id (e.g. "NVIDIA GeForce RTX 4090"), verified via list-gpu-types, and gpu.count sets the GPU count; cloud/data-center choice constrains stock.',
|
|
2361
|
+
directoryDescription: 'Create a GPU or CPU Pod. Billable from creation until it is stopped or terminated. GPU selection is the gpu object: gpu.id takes a GPU type id such as "NVIDIA GeForce RTX 4090", and gpu.count sets the number of GPUs. Cloud tier and data center choices limit which machines can host it.',
|
|
2354
2362
|
method: "POST",
|
|
2355
2363
|
path: "/v2/pods",
|
|
2356
2364
|
params: [],
|
|
@@ -2366,7 +2374,8 @@ var generatedTools = [
|
|
|
2366
2374
|
type: "object",
|
|
2367
2375
|
properties: {
|
|
2368
2376
|
body: {
|
|
2369
|
-
$ref: "#/$defs/CreatePodRequest"
|
|
2377
|
+
$ref: "#/$defs/CreatePodRequest",
|
|
2378
|
+
type: "object"
|
|
2370
2379
|
}
|
|
2371
2380
|
},
|
|
2372
2381
|
required: ["body"],
|
|
@@ -2733,7 +2742,8 @@ var generatedTools = [
|
|
|
2733
2742
|
type: "object",
|
|
2734
2743
|
properties: {
|
|
2735
2744
|
body: {
|
|
2736
|
-
$ref: "#/$defs/CreateRegistryRequest"
|
|
2745
|
+
$ref: "#/$defs/CreateRegistryRequest",
|
|
2746
|
+
type: "object"
|
|
2737
2747
|
}
|
|
2738
2748
|
},
|
|
2739
2749
|
required: ["body"],
|
|
@@ -2778,7 +2788,7 @@ var generatedTools = [
|
|
|
2778
2788
|
annotations: {
|
|
2779
2789
|
readOnlyHint: false,
|
|
2780
2790
|
destructiveHint: false,
|
|
2781
|
-
idempotentHint:
|
|
2791
|
+
idempotentHint: true,
|
|
2782
2792
|
openWorldHint: true
|
|
2783
2793
|
},
|
|
2784
2794
|
schemaOnDemand: true,
|
|
@@ -2786,7 +2796,8 @@ var generatedTools = [
|
|
|
2786
2796
|
type: "object",
|
|
2787
2797
|
properties: {
|
|
2788
2798
|
body: {
|
|
2789
|
-
$ref: "#/$defs/CreateSecretRequest"
|
|
2799
|
+
$ref: "#/$defs/CreateSecretRequest",
|
|
2800
|
+
type: "object"
|
|
2790
2801
|
}
|
|
2791
2802
|
},
|
|
2792
2803
|
required: ["body"],
|
|
@@ -2841,7 +2852,8 @@ var generatedTools = [
|
|
|
2841
2852
|
type: "object",
|
|
2842
2853
|
properties: {
|
|
2843
2854
|
body: {
|
|
2844
|
-
$ref: "#/$defs/CreateTemplateRequest"
|
|
2855
|
+
$ref: "#/$defs/CreateTemplateRequest",
|
|
2856
|
+
type: "object"
|
|
2845
2857
|
}
|
|
2846
2858
|
},
|
|
2847
2859
|
required: ["body"],
|
|
@@ -3028,6 +3040,7 @@ var generatedTools = [
|
|
|
3028
3040
|
title: "Delete cluster",
|
|
3029
3041
|
operationId: "deleteCluster",
|
|
3030
3042
|
description: "Delete a cluster permanently: it terminates every member pod. Verify the id with get-cluster, and list-cluster-pods for what the delete takes down, before deleting; delete only clusters your own tool calls created in this conversation, or the one the user asked you to delete by id \u2014 a name found by listing is not attribution.",
|
|
3043
|
+
directoryDescription: "Delete an Instant Cluster permanently. Every member Pod is terminated and its container disk is lost.",
|
|
3031
3044
|
method: "DELETE",
|
|
3032
3045
|
path: "/v2/clusters/{id}",
|
|
3033
3046
|
params: [
|
|
@@ -3059,6 +3072,7 @@ var generatedTools = [
|
|
|
3059
3072
|
title: "Delete endpoint",
|
|
3060
3073
|
operationId: "deleteEndpoint",
|
|
3061
3074
|
description: "Delete a serverless endpoint permanently and immediately. Verify the id belongs to the intended endpoint (get-endpoint) before deleting; delete only endpoints your own tool calls created in this conversation, or the one the user asked you to delete by id \u2014 a name found by listing is not attribution.",
|
|
3075
|
+
directoryDescription: "Delete a Serverless endpoint permanently and immediately.",
|
|
3062
3076
|
method: "DELETE",
|
|
3063
3077
|
path: "/v2/serverless/{id}",
|
|
3064
3078
|
params: [
|
|
@@ -3152,6 +3166,7 @@ var generatedTools = [
|
|
|
3152
3166
|
title: "Delete Pod",
|
|
3153
3167
|
operationId: "deletePod",
|
|
3154
3168
|
description: "Terminate a pod permanently \u2014 its container disk is lost. Distinguish from stopping (pod-action stop) which releases the GPU but keeps volume data. Verify the id with get-pod first; terminate only pods your own tool calls created in this conversation, or the one the user asked you to terminate by id \u2014 a name found by listing is not attribution.",
|
|
3169
|
+
directoryDescription: "Terminate a Pod permanently. Its container disk is lost; data on an attached network volume is kept. Stopping a Pod instead releases its compute but keeps its disk.",
|
|
3155
3170
|
method: "DELETE",
|
|
3156
3171
|
path: "/v2/pods/{id}",
|
|
3157
3172
|
params: [
|
|
@@ -3213,6 +3228,7 @@ var generatedTools = [
|
|
|
3213
3228
|
title: "Delete secret",
|
|
3214
3229
|
operationId: "deleteSecret",
|
|
3215
3230
|
description: "Delete a secret permanently. Environment variables referencing its name ({{ RUNPOD_SECRET_<name> }}) stop resolving at the next pod or worker boot; running instances keep the value they started with. Verify the id with get-secret first; delete only secrets your own tool calls created in this conversation, or the one the user asked you to delete by id \u2014 a name found by listing is not attribution.",
|
|
3231
|
+
directoryDescription: "Delete a secret permanently. Environment variables that reference it ({{ RUNPOD_SECRET_<name> }}) stop resolving at the next Pod or worker boot; running instances keep the value they started with.",
|
|
3216
3232
|
method: "DELETE",
|
|
3217
3233
|
path: "/v2/account/secrets/{id}",
|
|
3218
3234
|
params: [
|
|
@@ -3244,6 +3260,7 @@ var generatedTools = [
|
|
|
3244
3260
|
title: "Delete template",
|
|
3245
3261
|
operationId: "deleteTemplate",
|
|
3246
3262
|
description: "Delete a template permanently. Verify with get-template first; a template referenced by a live endpoint should not be deleted.",
|
|
3263
|
+
directoryDescription: "Delete a template permanently. An endpoint that references the template can stop working once it is deleted.",
|
|
3247
3264
|
method: "DELETE",
|
|
3248
3265
|
path: "/v2/templates/{id}",
|
|
3249
3266
|
params: [
|
|
@@ -3609,7 +3626,8 @@ var generatedTools = [
|
|
|
3609
3626
|
},
|
|
3610
3627
|
cloud: {
|
|
3611
3628
|
$ref: "#/$defs/GpuCloudFilter",
|
|
3612
|
-
description: "Cloud type for availability and lowest-price calculations. Valid only with include=AVAILABILITY. Supported values: SECURE, COMMUNITY. Upstream default when omitted: SECURE."
|
|
3629
|
+
description: "Cloud type for availability and lowest-price calculations. Valid only with include=AVAILABILITY. Supported values: SECURE, COMMUNITY. Upstream default when omitted: SECURE.",
|
|
3630
|
+
type: "string"
|
|
3613
3631
|
},
|
|
3614
3632
|
countryCodes: {
|
|
3615
3633
|
type: "array",
|
|
@@ -3893,7 +3911,8 @@ var generatedTools = [
|
|
|
3893
3911
|
},
|
|
3894
3912
|
bucketSize: {
|
|
3895
3913
|
$ref: "#/$defs/BillingBucketSize",
|
|
3896
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
3914
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
3915
|
+
type: "string"
|
|
3897
3916
|
},
|
|
3898
3917
|
lastN: {
|
|
3899
3918
|
type: "integer",
|
|
@@ -3970,7 +3989,8 @@ var generatedTools = [
|
|
|
3970
3989
|
},
|
|
3971
3990
|
bucketSize: {
|
|
3972
3991
|
$ref: "#/$defs/BillingBucketSize",
|
|
3973
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
3992
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
3993
|
+
type: "string"
|
|
3974
3994
|
},
|
|
3975
3995
|
lastN: {
|
|
3976
3996
|
type: "integer",
|
|
@@ -4336,7 +4356,8 @@ var generatedTools = [
|
|
|
4336
4356
|
},
|
|
4337
4357
|
bucketSize: {
|
|
4338
4358
|
$ref: "#/$defs/BillingBucketSize",
|
|
4339
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
4359
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
4360
|
+
type: "string"
|
|
4340
4361
|
},
|
|
4341
4362
|
lastN: {
|
|
4342
4363
|
type: "integer",
|
|
@@ -4608,7 +4629,8 @@ var generatedTools = [
|
|
|
4608
4629
|
},
|
|
4609
4630
|
cloud: {
|
|
4610
4631
|
$ref: "#/$defs/GpuCloudFilter",
|
|
4611
|
-
description: "Cloud type for availability and lowest-price calculations. Valid only with include=AVAILABILITY. Supported values: SECURE, COMMUNITY. Upstream default when omitted: SECURE."
|
|
4632
|
+
description: "Cloud type for availability and lowest-price calculations. Valid only with include=AVAILABILITY. Supported values: SECURE, COMMUNITY. Upstream default when omitted: SECURE.",
|
|
4633
|
+
type: "string"
|
|
4612
4634
|
},
|
|
4613
4635
|
countryCodes: {
|
|
4614
4636
|
type: "array",
|
|
@@ -4702,7 +4724,8 @@ var generatedTools = [
|
|
|
4702
4724
|
},
|
|
4703
4725
|
bucketSize: {
|
|
4704
4726
|
$ref: "#/$defs/BillingBucketSize",
|
|
4705
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
4727
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
4728
|
+
type: "string"
|
|
4706
4729
|
},
|
|
4707
4730
|
lastN: {
|
|
4708
4731
|
type: "integer",
|
|
@@ -4824,7 +4847,8 @@ var generatedTools = [
|
|
|
4824
4847
|
},
|
|
4825
4848
|
bucketSize: {
|
|
4826
4849
|
$ref: "#/$defs/BillingBucketSize",
|
|
4827
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
4850
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
4851
|
+
type: "string"
|
|
4828
4852
|
},
|
|
4829
4853
|
lastN: {
|
|
4830
4854
|
type: "integer",
|
|
@@ -4991,6 +5015,7 @@ var generatedTools = [
|
|
|
4991
5015
|
title: "List Serverless billing",
|
|
4992
5016
|
operationId: "listServerlessBilling",
|
|
4993
5017
|
description: "Get serverless billing history, split into time buckets. SIZE WARNING: with defaults this emits one record per endpoint PER BUCKET \u2014 on an account with many endpoints the response overflows the tool-result limit and becomes unusable. Always pass lastN: 1 (or a bucketSize spanning the whole window) for one record per endpoint, and serverlessId when you need one endpoint. Distinct from pod billing, which covers standalone pods.",
|
|
5018
|
+
directoryDescription: "Get Serverless billing history, split into time buckets. By default the response has one record per endpoint per bucket, which can be very large on accounts with many endpoints; lastN: 1 (or one bucket spanning the whole window) returns one record per endpoint, and serverlessId narrows it to a single endpoint. Pod billing is reported separately.",
|
|
4994
5019
|
method: "GET",
|
|
4995
5020
|
path: "/v2/billing/serverless",
|
|
4996
5021
|
params: [
|
|
@@ -5037,7 +5062,8 @@ var generatedTools = [
|
|
|
5037
5062
|
},
|
|
5038
5063
|
bucketSize: {
|
|
5039
5064
|
$ref: "#/$defs/BillingBucketSize",
|
|
5040
|
-
description: "Length of each billing time bucket. Defaults to day."
|
|
5065
|
+
description: "Length of each billing time bucket. Defaults to day.",
|
|
5066
|
+
type: "string"
|
|
5041
5067
|
},
|
|
5042
5068
|
lastN: {
|
|
5043
5069
|
type: "integer",
|
|
@@ -5094,7 +5120,8 @@ var generatedTools = [
|
|
|
5094
5120
|
type: "string"
|
|
5095
5121
|
},
|
|
5096
5122
|
body: {
|
|
5097
|
-
$ref: "#/$defs/PodActionRequest"
|
|
5123
|
+
$ref: "#/$defs/PodActionRequest",
|
|
5124
|
+
type: "object"
|
|
5098
5125
|
}
|
|
5099
5126
|
},
|
|
5100
5127
|
required: ["id", "body"],
|
|
@@ -5164,7 +5191,7 @@ var generatedTools = [
|
|
|
5164
5191
|
annotations: {
|
|
5165
5192
|
readOnlyHint: false,
|
|
5166
5193
|
destructiveHint: false,
|
|
5167
|
-
idempotentHint:
|
|
5194
|
+
idempotentHint: true,
|
|
5168
5195
|
openWorldHint: true
|
|
5169
5196
|
},
|
|
5170
5197
|
inputSchema: {
|
|
@@ -5175,7 +5202,8 @@ var generatedTools = [
|
|
|
5175
5202
|
description: "Cluster identifier"
|
|
5176
5203
|
},
|
|
5177
5204
|
body: {
|
|
5178
|
-
$ref: "#/$defs/UpdateClusterRequest"
|
|
5205
|
+
$ref: "#/$defs/UpdateClusterRequest",
|
|
5206
|
+
type: "object"
|
|
5179
5207
|
}
|
|
5180
5208
|
},
|
|
5181
5209
|
required: ["id", "body"],
|
|
@@ -5201,6 +5229,7 @@ var generatedTools = [
|
|
|
5201
5229
|
title: "Update endpoint",
|
|
5202
5230
|
operationId: "updateEndpoint",
|
|
5203
5231
|
description: "Partially update a serverless endpoint (PATCH): only fields present in the body change, omitted ones are untouched, with one exception. DESTRUCTIVE GOTCHA: gpu.pools and gpu.excludedTypes are a single selection, so sending pools without excludedTypes clears any exclusions pinned elsewhere (the console or set-endpoint-gpus) \u2014 read the endpoint first with get-endpoint and resend excludedTypes if you still want them. An exclusion naming a type outside pools returns 400. A CUDA-only or count-only change does not need pools at all, so omit it unless you mean to replace the selection. Mutable fields: name, gpu, cpu, workers (min/max/idleTimeout), scaling (type plus queueDelay or requestCount), dataCenterIds, networkVolumes, timeout, flashboot, and the container settings (image, args, disk, ports, env, registry). cpu completely replaces a CPU endpoint's flavor selection. Compute family is immutable: gpu on a CPU endpoint, cpu on a GPU one, or both, returns 400. Effect timing differs by field \u2014 workers/scaling/timeout reach the autoscaler promptly, while container changes (image, env) cut a new release that rolls out as workers cycle, so in-flight workers keep the previous version. Track rollout with list-endpoint-releases.",
|
|
5232
|
+
directoryDescription: "Partially update a Serverless endpoint (PATCH): only fields present in the body change. gpu.pools and gpu.excludedTypes are one selection, so sending pools without excludedTypes clears existing exclusions; an exclusion naming a type outside pools returns 400, and a CUDA-only or count-only change does not need pools. Mutable fields: name, gpu, cpu, workers (min/max/idleTimeout), scaling (type plus queueDelay or requestCount), dataCenterIds, networkVolumes, timeout, flashboot, and the container settings (image, args, disk, ports, env, registry). cpu replaces a CPU endpoint's whole flavor selection. The compute family is fixed: gpu on a CPU endpoint, cpu on a GPU one, or both returns 400. Worker, scaling and timeout changes apply promptly; container changes (image, env) create a new release that rolls out as workers cycle, so in-flight workers keep the previous version.",
|
|
5204
5233
|
method: "PATCH",
|
|
5205
5234
|
path: "/v2/serverless/{id}",
|
|
5206
5235
|
params: [
|
|
@@ -5212,7 +5241,7 @@ var generatedTools = [
|
|
|
5212
5241
|
hasBody: true,
|
|
5213
5242
|
annotations: {
|
|
5214
5243
|
readOnlyHint: false,
|
|
5215
|
-
destructiveHint:
|
|
5244
|
+
destructiveHint: true,
|
|
5216
5245
|
idempotentHint: false,
|
|
5217
5246
|
openWorldHint: true
|
|
5218
5247
|
},
|
|
@@ -5225,7 +5254,8 @@ var generatedTools = [
|
|
|
5225
5254
|
description: "Serverless endpoint identifier"
|
|
5226
5255
|
},
|
|
5227
5256
|
body: {
|
|
5228
|
-
$ref: "#/$defs/UpdateEndpointRequest"
|
|
5257
|
+
$ref: "#/$defs/UpdateEndpointRequest",
|
|
5258
|
+
type: "object"
|
|
5229
5259
|
}
|
|
5230
5260
|
},
|
|
5231
5261
|
required: ["id", "body"],
|
|
@@ -5604,7 +5634,7 @@ var generatedTools = [
|
|
|
5604
5634
|
annotations: {
|
|
5605
5635
|
readOnlyHint: false,
|
|
5606
5636
|
destructiveHint: false,
|
|
5607
|
-
idempotentHint:
|
|
5637
|
+
idempotentHint: true,
|
|
5608
5638
|
openWorldHint: true
|
|
5609
5639
|
},
|
|
5610
5640
|
inputSchema: {
|
|
@@ -5615,7 +5645,8 @@ var generatedTools = [
|
|
|
5615
5645
|
description: "Global volume identifier"
|
|
5616
5646
|
},
|
|
5617
5647
|
body: {
|
|
5618
|
-
$ref: "#/$defs/UpdateGlobalVolumeRequest"
|
|
5648
|
+
$ref: "#/$defs/UpdateGlobalVolumeRequest",
|
|
5649
|
+
type: "object"
|
|
5619
5650
|
}
|
|
5620
5651
|
},
|
|
5621
5652
|
required: ["id", "body"],
|
|
@@ -5656,7 +5687,7 @@ var generatedTools = [
|
|
|
5656
5687
|
annotations: {
|
|
5657
5688
|
readOnlyHint: false,
|
|
5658
5689
|
destructiveHint: false,
|
|
5659
|
-
idempotentHint:
|
|
5690
|
+
idempotentHint: true,
|
|
5660
5691
|
openWorldHint: true
|
|
5661
5692
|
},
|
|
5662
5693
|
inputSchema: {
|
|
@@ -5667,7 +5698,8 @@ var generatedTools = [
|
|
|
5667
5698
|
description: "Network volume identifier"
|
|
5668
5699
|
},
|
|
5669
5700
|
body: {
|
|
5670
|
-
$ref: "#/$defs/UpdateNetworkVolumeRequest"
|
|
5701
|
+
$ref: "#/$defs/UpdateNetworkVolumeRequest",
|
|
5702
|
+
type: "object"
|
|
5671
5703
|
}
|
|
5672
5704
|
},
|
|
5673
5705
|
required: ["id", "body"],
|
|
@@ -5712,7 +5744,7 @@ var generatedTools = [
|
|
|
5712
5744
|
hasBody: true,
|
|
5713
5745
|
annotations: {
|
|
5714
5746
|
readOnlyHint: false,
|
|
5715
|
-
destructiveHint:
|
|
5747
|
+
destructiveHint: true,
|
|
5716
5748
|
idempotentHint: false,
|
|
5717
5749
|
openWorldHint: true
|
|
5718
5750
|
},
|
|
@@ -5725,7 +5757,8 @@ var generatedTools = [
|
|
|
5725
5757
|
description: "Pod identifier"
|
|
5726
5758
|
},
|
|
5727
5759
|
body: {
|
|
5728
|
-
$ref: "#/$defs/UpdatePodRequest"
|
|
5760
|
+
$ref: "#/$defs/UpdatePodRequest",
|
|
5761
|
+
type: "object"
|
|
5729
5762
|
}
|
|
5730
5763
|
},
|
|
5731
5764
|
required: ["id", "body"],
|
|
@@ -5954,7 +5987,7 @@ var generatedTools = [
|
|
|
5954
5987
|
hasBody: true,
|
|
5955
5988
|
annotations: {
|
|
5956
5989
|
readOnlyHint: false,
|
|
5957
|
-
destructiveHint:
|
|
5990
|
+
destructiveHint: true,
|
|
5958
5991
|
idempotentHint: false,
|
|
5959
5992
|
openWorldHint: true
|
|
5960
5993
|
},
|
|
@@ -5967,7 +6000,8 @@ var generatedTools = [
|
|
|
5967
6000
|
description: "Secret identifier"
|
|
5968
6001
|
},
|
|
5969
6002
|
body: {
|
|
5970
|
-
$ref: "#/$defs/UpdateSecretRequest"
|
|
6003
|
+
$ref: "#/$defs/UpdateSecretRequest",
|
|
6004
|
+
type: "object"
|
|
5971
6005
|
}
|
|
5972
6006
|
},
|
|
5973
6007
|
required: ["id", "body"],
|
|
@@ -6013,7 +6047,8 @@ var generatedTools = [
|
|
|
6013
6047
|
type: "object",
|
|
6014
6048
|
properties: {
|
|
6015
6049
|
body: {
|
|
6016
|
-
$ref: "#/$defs/UpdateSshKeysRequest"
|
|
6050
|
+
$ref: "#/$defs/UpdateSshKeysRequest",
|
|
6051
|
+
type: "object"
|
|
6017
6052
|
}
|
|
6018
6053
|
},
|
|
6019
6054
|
required: ["body"],
|
|
@@ -6058,7 +6093,7 @@ var generatedTools = [
|
|
|
6058
6093
|
annotations: {
|
|
6059
6094
|
readOnlyHint: false,
|
|
6060
6095
|
destructiveHint: false,
|
|
6061
|
-
idempotentHint:
|
|
6096
|
+
idempotentHint: true,
|
|
6062
6097
|
openWorldHint: true
|
|
6063
6098
|
},
|
|
6064
6099
|
schemaOnDemand: true,
|
|
@@ -6069,7 +6104,8 @@ var generatedTools = [
|
|
|
6069
6104
|
type: "string"
|
|
6070
6105
|
},
|
|
6071
6106
|
body: {
|
|
6072
|
-
$ref: "#/$defs/UpdateTemplateRequest"
|
|
6107
|
+
$ref: "#/$defs/UpdateTemplateRequest",
|
|
6108
|
+
type: "object"
|
|
6073
6109
|
}
|
|
6074
6110
|
},
|
|
6075
6111
|
required: ["id", "body"],
|
|
@@ -6238,6 +6274,142 @@ var generatedTools = [
|
|
|
6238
6274
|
}
|
|
6239
6275
|
];
|
|
6240
6276
|
|
|
6277
|
+
// src/specgen/profile.ts
|
|
6278
|
+
var IN = { include: true };
|
|
6279
|
+
var CREDENTIAL_INPUT = "Takes a secret or password as input; directories forbid collecting credentials.";
|
|
6280
|
+
var ALP = "Collects conversation-derived data beyond the task; the directory profile never serves it.";
|
|
6281
|
+
var DIRECTORY_TOOLS = {
|
|
6282
|
+
"cancel-job": IN,
|
|
6283
|
+
"create-cluster": IN,
|
|
6284
|
+
"create-delegation": IN,
|
|
6285
|
+
"create-endpoint": IN,
|
|
6286
|
+
"create-global-volume": IN,
|
|
6287
|
+
"create-network-volume": IN,
|
|
6288
|
+
"create-pod": IN,
|
|
6289
|
+
"create-template": IN,
|
|
6290
|
+
"delete-cluster": IN,
|
|
6291
|
+
"delete-endpoint": IN,
|
|
6292
|
+
"delete-global-volume": IN,
|
|
6293
|
+
"delete-network-volume": IN,
|
|
6294
|
+
"delete-pod": IN,
|
|
6295
|
+
"delete-registry": IN,
|
|
6296
|
+
"delete-secret": IN,
|
|
6297
|
+
"delete-template": IN,
|
|
6298
|
+
"deploy-hub-repo": IN,
|
|
6299
|
+
"endpoint-health": IN,
|
|
6300
|
+
"get-capacity": IN,
|
|
6301
|
+
"get-cluster": IN,
|
|
6302
|
+
"get-cpu-type": IN,
|
|
6303
|
+
"get-data-center": IN,
|
|
6304
|
+
"get-endpoint": IN,
|
|
6305
|
+
"get-endpoint-build": IN,
|
|
6306
|
+
"get-global-volume": IN,
|
|
6307
|
+
"get-gpu-type": IN,
|
|
6308
|
+
"get-job-status": IN,
|
|
6309
|
+
"get-network-volume": IN,
|
|
6310
|
+
"get-organization": IN,
|
|
6311
|
+
"get-pod": IN,
|
|
6312
|
+
"get-registry": IN,
|
|
6313
|
+
"get-secret": IN,
|
|
6314
|
+
"get-ssh-keys": IN,
|
|
6315
|
+
"get-template": IN,
|
|
6316
|
+
"list-billing": IN,
|
|
6317
|
+
"list-cluster-billing": IN,
|
|
6318
|
+
"list-cluster-pods": IN,
|
|
6319
|
+
"list-clusters": IN,
|
|
6320
|
+
"list-cpu-types": IN,
|
|
6321
|
+
"list-data-centers": IN,
|
|
6322
|
+
"list-delegations": IN,
|
|
6323
|
+
"list-endpoint-billing": IN,
|
|
6324
|
+
"list-endpoint-builds": IN,
|
|
6325
|
+
"list-endpoint-releases": IN,
|
|
6326
|
+
"list-endpoint-workers": IN,
|
|
6327
|
+
"list-endpoints": IN,
|
|
6328
|
+
"list-global-volumes": IN,
|
|
6329
|
+
"list-gpu-types": IN,
|
|
6330
|
+
"list-hub-repos": IN,
|
|
6331
|
+
"list-network-volume-billing": IN,
|
|
6332
|
+
"list-network-volumes": IN,
|
|
6333
|
+
"list-pod-billing": IN,
|
|
6334
|
+
"list-pods": IN,
|
|
6335
|
+
"list-public-endpoints": IN,
|
|
6336
|
+
"list-public-templates": IN,
|
|
6337
|
+
"list-registries": IN,
|
|
6338
|
+
"list-secrets": IN,
|
|
6339
|
+
"list-serverless-billing": IN,
|
|
6340
|
+
"list-templates": IN,
|
|
6341
|
+
"lookup-concept": IN,
|
|
6342
|
+
"pod-action": IN,
|
|
6343
|
+
"purge-endpoint-queue": IN,
|
|
6344
|
+
"retry-job": IN,
|
|
6345
|
+
"revoke-delegation": IN,
|
|
6346
|
+
"search-concepts": IN,
|
|
6347
|
+
"search-docs": IN,
|
|
6348
|
+
"set-endpoint-gpus": IN,
|
|
6349
|
+
"stream-job": IN,
|
|
6350
|
+
"stream-pod-logs": IN,
|
|
6351
|
+
"stream-worker-logs": IN,
|
|
6352
|
+
"update-cluster": IN,
|
|
6353
|
+
"update-endpoint": IN,
|
|
6354
|
+
"update-global-volume": IN,
|
|
6355
|
+
"update-network-volume": IN,
|
|
6356
|
+
"update-pod": IN,
|
|
6357
|
+
"update-ssh-keys": IN,
|
|
6358
|
+
"update-template": IN,
|
|
6359
|
+
"run-endpoint": { include: true, omitInputs: ["s3Config"] },
|
|
6360
|
+
"runsync-endpoint": { include: true, omitInputs: ["s3Config"] },
|
|
6361
|
+
"list-guides": {
|
|
6362
|
+
include: false,
|
|
6363
|
+
reason: "Serves playbooks that instruct the model how to behave."
|
|
6364
|
+
},
|
|
6365
|
+
"read-guide": {
|
|
6366
|
+
include: false,
|
|
6367
|
+
reason: "Serves playbooks that instruct the model how to behave."
|
|
6368
|
+
},
|
|
6369
|
+
"describe-tool": {
|
|
6370
|
+
include: false,
|
|
6371
|
+
reason: "Fetches schemas the directory already lists in full; directories reject schema fetching."
|
|
6372
|
+
},
|
|
6373
|
+
"create-secret": { include: false, reason: CREDENTIAL_INPUT },
|
|
6374
|
+
"update-secret": { include: false, reason: CREDENTIAL_INPUT },
|
|
6375
|
+
"create-registry": { include: false, reason: CREDENTIAL_INPUT },
|
|
6376
|
+
report_feedback: { include: false, reason: ALP },
|
|
6377
|
+
report_how_user_found_runpod: { include: false, reason: ALP },
|
|
6378
|
+
save_to_journal: { include: false, reason: ALP },
|
|
6379
|
+
read_journal: { include: false, reason: ALP },
|
|
6380
|
+
ask_question: { include: false, reason: ALP }
|
|
6381
|
+
};
|
|
6382
|
+
function directoryIncludes(name) {
|
|
6383
|
+
return DIRECTORY_TOOLS[name]?.include === true;
|
|
6384
|
+
}
|
|
6385
|
+
function directoryOmittedInputs(name) {
|
|
6386
|
+
const decision = DIRECTORY_TOOLS[name];
|
|
6387
|
+
return decision?.include ? decision.omitInputs ?? [] : [];
|
|
6388
|
+
}
|
|
6389
|
+
|
|
6390
|
+
// src/specgen/redact.ts
|
|
6391
|
+
var REDACTED = "[redacted]";
|
|
6392
|
+
var SECRET_KEY = /pass(word|wd)?|secret|token|api_?key|private_?key|credential|auth/i;
|
|
6393
|
+
var SECRET_REFERENCE = /^\s*\{\{\s*RUNPOD_SECRET_[^}]+\}\}\s*$/;
|
|
6394
|
+
function redactEnv(env) {
|
|
6395
|
+
return Object.fromEntries(
|
|
6396
|
+
Object.entries(env).map(([key, value]) => [
|
|
6397
|
+
key,
|
|
6398
|
+
typeof value === "string" && value !== "" && SECRET_KEY.test(key) && !SECRET_REFERENCE.test(value) ? REDACTED : value
|
|
6399
|
+
])
|
|
6400
|
+
);
|
|
6401
|
+
}
|
|
6402
|
+
function redactSecretEnv(payload) {
|
|
6403
|
+
if (Array.isArray(payload)) return payload.map(redactSecretEnv);
|
|
6404
|
+
if (!payload || typeof payload !== "object") return payload;
|
|
6405
|
+
return Object.fromEntries(
|
|
6406
|
+
Object.entries(payload).map(([key, value]) => [
|
|
6407
|
+
key,
|
|
6408
|
+
key === "env" && value && typeof value === "object" && !Array.isArray(value) ? redactEnv(value) : redactSecretEnv(value)
|
|
6409
|
+
])
|
|
6410
|
+
);
|
|
6411
|
+
}
|
|
6412
|
+
|
|
6241
6413
|
// src/specgen/pagination.ts
|
|
6242
6414
|
var DEFAULT_LIST_LIMIT = 20;
|
|
6243
6415
|
var MAX_LIST_LIMIT = 100;
|
|
@@ -6437,6 +6609,12 @@ var destructive = {
|
|
|
6437
6609
|
idempotentHint: true,
|
|
6438
6610
|
openWorldHint: true
|
|
6439
6611
|
};
|
|
6612
|
+
var destructiveWrite = {
|
|
6613
|
+
readOnlyHint: false,
|
|
6614
|
+
destructiveHint: true,
|
|
6615
|
+
idempotentHint: false,
|
|
6616
|
+
openWorldHint: true
|
|
6617
|
+
};
|
|
6440
6618
|
|
|
6441
6619
|
// src/specgen/tools/capacity.ts
|
|
6442
6620
|
var CUDA_VERSION_REGEX = /^\d{1,2}\.\d{1,2}$/;
|
|
@@ -6473,6 +6651,7 @@ function rankByStock(rows, stats, includeUnavailable) {
|
|
|
6473
6651
|
var getCapacity = {
|
|
6474
6652
|
name: "get-capacity",
|
|
6475
6653
|
title: "Get GPU capacity by CUDA version",
|
|
6654
|
+
directoryDescription: "GPU capacity across host CUDA versions, as a matrix. By default one call returns, for each GPU type, overall stock plus AVAILABLE or UNAVAILABLE per host CUDA version. With cudaVersions it checks each listed version and returns graded stock (High, Medium, Low, Out) and the lowest on-demand price per version; a check that fails transiently reports an error for that version only. Out-of-stock GPUs are included unless includeUnavailable is false. Live public catalog data, so page cursors can shift between calls.",
|
|
6476
6655
|
annotations: readOnly,
|
|
6477
6656
|
description: "GPU capacity across host CUDA versions, as a matrix. Use this to choose an endpoint's allowedCudaVersions/minCudaVersion (or diagnose/widen a capacity-starved one) and to distinguish capacity problems from compatibility problems. Default mode is one call returning, per GPU type, overall stock plus AVAILABLE/UNAVAILABLE per host-reported CUDA version. Pass cudaVersions to deep-probe instead: one stock lookup per listed version, returning graded stock (High/Medium/Low/Out) and the lowest on-demand price per version; a probe that fails transiently reports a per-version error instead of failing the call. Nothing is hidden by default \u2014 set includeUnavailable:false to drop GPUs with no stock on any listed version. Credential-free public catalog data. Stock is live, so page cursors can shift between calls.",
|
|
6478
6657
|
inputSchema: {
|
|
@@ -6675,7 +6854,9 @@ function formatGpuIds(gpu) {
|
|
|
6675
6854
|
var setEndpointGpus = {
|
|
6676
6855
|
name: "set-endpoint-gpus",
|
|
6677
6856
|
title: "Set endpoint GPUs",
|
|
6678
|
-
|
|
6857
|
+
directoryDescription: "Set which GPUs a Serverless endpoint's workers run on, including pinning specific GPU types. Takes either a raw gpuIds string, or pools plus optional excludeGpuTypeIds, from which the exclusion string is built: a pool allows every GPU type in it, and excluding all but one pins that type. Changes only GPU settings and keeps the endpoint's other settings.",
|
|
6858
|
+
// Replaces the whole GPU selection: exclusions not resent are cleared.
|
|
6859
|
+
annotations: destructive,
|
|
6679
6860
|
description: "Set which GPUs a Serverless endpoint's workers run on \u2014 including pinning specific GPU SKUs. Provide either a raw gpuIds string, or pools plus optional excludeGpuTypeIds (GPU type ids from list-gpu-types) and the exclusion string is built for you: a pool allows every SKU in it, and excluding all but one SKU pins that SKU exactly. Updates only GPU settings through REST v2, preserving other endpoint settings. create-endpoint/update-endpoint also support gpu.excludedTypes.",
|
|
6680
6861
|
inputSchema: {
|
|
6681
6862
|
type: "object",
|
|
@@ -6870,6 +7051,7 @@ function randomSuffix() {
|
|
|
6870
7051
|
var listHubRepos = {
|
|
6871
7052
|
name: "list-hub-repos",
|
|
6872
7053
|
title: "List Hub repos",
|
|
7054
|
+
directoryDescription: "List repos published to the Runpod Hub (prebuilt Serverless workers and Pod templates, such as vLLM and ComfyUI), sorted by deploy count. Public catalog; no sign-in needed. Each result includes the listed release with its hubReleaseId and image name. includeConfig: true adds each release's config (hardware requirements and environment-variable schema), which is large; repoOwner and searchTerm narrow the list.",
|
|
6873
7055
|
annotations: readOnly,
|
|
6874
7056
|
description: "List repos published to the Runpod Hub (prebuilt Serverless workers and Pod templates, e.g. vLLM, ComfyUI). Public catalog \u2014 no auth required. Each result includes the currently listed release with its hubReleaseId and prebuilt image name. Results are sorted by deploy count (most popular first). Set includeConfig:true to also return the release config (hardware requirements and environment-variable schema) \u2014 it is large, so prefer requesting it for a single repo via the repoOwner/searchTerm filters.",
|
|
6875
7057
|
inputSchema: {
|
|
@@ -6973,6 +7155,7 @@ var listHubRepos = {
|
|
|
6973
7155
|
var deployHubRepo = {
|
|
6974
7156
|
name: "deploy-hub-repo",
|
|
6975
7157
|
title: "Deploy Hub repo",
|
|
7158
|
+
directoryDescription: `Deploy a Runpod Hub repo's listed release as a new Serverless endpoint, the same as clicking Deploy on the Hub. Identifies the repo by repo ("owner/name") or hubReleaseId. The release supplies the image, container disk, CUDA constraints and environment-variable defaults; env overrides or fills in values, and keys the release requires without a default have to be supplied. GPUs come from the release config when it sets them, otherwise from gpuIds (pool names such as 'ADA_24'). Billable while the endpoint's workers run.`,
|
|
6976
7159
|
// Two sequential upstream calls: together they can outlast a client's request timeout.
|
|
6977
7160
|
holdsResponse: true,
|
|
6978
7161
|
annotations: write,
|
|
@@ -7434,6 +7617,7 @@ function validateWait(wait) {
|
|
|
7434
7617
|
var runEndpoint = {
|
|
7435
7618
|
name: "run-endpoint",
|
|
7436
7619
|
title: "Submit Serverless job",
|
|
7620
|
+
directoryDescription: "Submit an asynchronous job to a Serverless endpoint. Returns a job ID immediately; the result stays available for 30 minutes after the job completes.",
|
|
7437
7621
|
annotations: write,
|
|
7438
7622
|
description: "Submit an asynchronous job to a Serverless endpoint. Returns a job ID immediately \u2014 use get-job-status to poll for results (pass its `wait` to block through a cold start instead of tight-looping). Async results are available for 30 minutes after completion.",
|
|
7439
7623
|
inputSchema: {
|
|
@@ -7465,6 +7649,7 @@ var runEndpoint = {
|
|
|
7465
7649
|
var runsyncEndpoint = {
|
|
7466
7650
|
name: "runsync-endpoint",
|
|
7467
7651
|
title: "Run Serverless job and wait",
|
|
7652
|
+
directoryDescription: `Submit a synchronous job to a Serverless endpoint and wait up to ${HTTP_LONG_POLL_BUDGET_MS} ms for the result. If the job outlives the wait, the response carries the job ID and its current status (IN_QUEUE or IN_PROGRESS). Maximum payload 20 MB; results expire 1 minute after completion.`,
|
|
7468
7653
|
holdsResponse: true,
|
|
7469
7654
|
annotations: write,
|
|
7470
7655
|
description: "Submit a synchronous job to a Serverless endpoint and wait for the result. Best for fast tasks: if the job outlives the wait, the response returns a job ID and a non-terminal status (IN_QUEUE or IN_PROGRESS) to poll with get-job-status. Max payload 20 MB; results expire after 1 minute. The wait parameter extends the server-side wait" + (HOSTED ? ` \u2014 this server runs behind a 60-second gateway deadline, so waits clamp to ${HTTP_LONG_POLL_BUDGET_MS} ms, which is also the effective default. For longer jobs use run-endpoint + get-job-status.` : " to up to 5 minutes (300000 ms); it defaults to 90000 (90 seconds)."),
|
|
@@ -7511,6 +7696,7 @@ var runsyncEndpoint = {
|
|
|
7511
7696
|
var getJobStatus = {
|
|
7512
7697
|
name: "get-job-status",
|
|
7513
7698
|
title: "Get job status",
|
|
7699
|
+
directoryDescription: `Get the status of a Serverless job, and its output once it completes. Statuses: IN_QUEUE, IN_PROGRESS, COMPLETED, FAILED, CANCELLED, TIMED_OUT. With wait (milliseconds, up to ${HTTP_LONG_POLL_BUDGET_MS}) the server polls until the job reaches a final status or the wait runs out, in which case it returns the latest status with pollingTimedOut: true; without wait it returns the current status at once. An IN_QUEUE result includes a workerHealth summary of the endpoint's workers.`,
|
|
7514
7700
|
holdsResponse: true,
|
|
7515
7701
|
annotations: readOnly,
|
|
7516
7702
|
description: "Check the status of a Serverless job. Returns the current status and output when complete. Job statuses: IN_QUEUE, IN_PROGRESS, COMPLETED, FAILED, CANCELLED, TIMED_OUT. Pass `wait` (milliseconds, up to " + STATUS_WAIT_MAX_MS + ") to BLOCK server-side, polling until the job reaches a terminal status or the budget expires \u2014 use it to ride out a cold start (a first job on a fresh worker pulls the image and loads the model, commonly 1\u20135+ minutes) in a single call instead of returning on the first IN_QUEUE and tight-looping the tool. Without `wait` it returns the current status immediately (a single check). If the budget expires before a terminal status, it returns the latest non-terminal status with pollingTimedOut:true \u2014 call again (with `wait`) to keep blocking. IMPORTANT: a job stuck IN_QUEUE does not necessarily mean a capacity shortage \u2014 a worker may have spun up and crash-looped. When the job is IN_QUEUE this tool attaches a workerHealth summary and a hint. To dig deeper call list-endpoint-workers, then read stream-worker-logs regardless of the status a worker reports: a container failing to start loops while its worker still shows RUNNING or THROTTLED and unhealthy stays 0, so UNHEALTHY is one symptom of a crash loop and not a test for it. The logs are the authority.",
|
|
@@ -7561,8 +7747,11 @@ var getJobStatus = {
|
|
|
7561
7747
|
var streamJob = {
|
|
7562
7748
|
name: "stream-job",
|
|
7563
7749
|
title: "Stream job output",
|
|
7750
|
+
directoryDescription: `Collect streaming output from a Serverless job whose worker streams its output. Polls the job's stream until it reaches COMPLETED, FAILED, CANCELLED or TIMED_OUT, for up to ${formatBudget(HTTP_LONG_POLL_BUDGET_MS)}; if time runs out first, it returns the chunks collected so far with pollingTimedOut: true, and a later call resumes where it left off.`,
|
|
7564
7751
|
holdsResponse: true,
|
|
7565
|
-
|
|
7752
|
+
// Not a read: /stream hands out each chunk once, so a chunk collected by a
|
|
7753
|
+
// call whose response is lost cannot be fetched again.
|
|
7754
|
+
annotations: destructiveWrite,
|
|
7566
7755
|
description: `Retrieve streaming output from a Serverless job. The worker must support streaming output. Polls /stream/{jobId} and collects chunks until the status is COMPLETED, FAILED, CANCELLED, or TIMED_OUT, for up to ${formatBudget(STREAM_BUDGET_MS)}. If the budget expires first, returns the chunks collected so far with pollingTimedOut: true \u2014 call stream-job again to resume where it left off, or get-job-status to check without streaming.`,
|
|
7567
7756
|
inputSchema: {
|
|
7568
7757
|
type: "object",
|
|
@@ -7620,7 +7809,8 @@ var cancelJob = {
|
|
|
7620
7809
|
var retryJob = {
|
|
7621
7810
|
name: "retry-job",
|
|
7622
7811
|
title: "Retry job",
|
|
7623
|
-
|
|
7812
|
+
// Removes the previous output before requeueing.
|
|
7813
|
+
annotations: destructiveWrite,
|
|
7624
7814
|
description: "Retry a failed or timed-out Serverless job. Only works for jobs with FAILED or TIMED_OUT status. The previous output is removed and the job is requeued.",
|
|
7625
7815
|
inputSchema: {
|
|
7626
7816
|
type: "object",
|
|
@@ -7646,6 +7836,7 @@ var retryJob = {
|
|
|
7646
7836
|
var endpointHealth = {
|
|
7647
7837
|
name: "endpoint-health",
|
|
7648
7838
|
title: "Get endpoint health",
|
|
7839
|
+
directoryDescription: "Get the health rollup for a Serverless endpoint: worker counts by state and job queue statistics. The rollup can lag the per-worker state, and a worker whose container keeps failing to start can still report RUNNING or THROTTLED here. Zero workers means the endpoint is waiting for GPU capacity.",
|
|
7649
7840
|
annotations: readOnly,
|
|
7650
7841
|
description: "Get the endpoint-level health rollup for a Serverless endpoint: worker counts by state plus job queue statistics. This is the runtime plane's own /health view and it can lag or disagree with the per-worker truth \u2014 when a job is stuck IN_QUEUE, prefer list-endpoint-workers over this rollup for per-worker state \u2014 but treat neither as the authority on crash loops, because a container failing to start loops while its worker reports RUNNING or THROTTLED and unhealthy stays 0; stream-worker-logs is what settles it, and note that get-job-status already attaches that worker summary and a hint on every IN_QUEUE result. Zero workers here means the endpoint is waiting for GPU capacity.",
|
|
7651
7842
|
inputSchema: {
|
|
@@ -7667,6 +7858,7 @@ var endpointHealth = {
|
|
|
7667
7858
|
var purgeEndpointQueue = {
|
|
7668
7859
|
name: "purge-endpoint-queue",
|
|
7669
7860
|
title: "Purge endpoint queue",
|
|
7861
|
+
directoryDescription: "Remove all queued jobs from a Serverless endpoint. Jobs already in progress keep running.",
|
|
7670
7862
|
annotations: destructive,
|
|
7671
7863
|
description: "Remove all pending jobs from a Serverless endpoint queue. Only affects queued jobs \u2014 in-progress jobs continue running. Use this for error recovery or clearing outdated requests.",
|
|
7672
7864
|
inputSchema: {
|
|
@@ -7704,6 +7896,7 @@ var jobTools = [
|
|
|
7704
7896
|
var listEndpoints = {
|
|
7705
7897
|
name: "list-endpoints",
|
|
7706
7898
|
title: "List endpoints",
|
|
7899
|
+
directoryDescription: "List the Serverless endpoints the account owns, trimmed to id, name, image, compute config, worker counts, scaling and data centers; environment variables and request URLs are left out. Returns one page at a time; cursor=nextCursor returns the next page.",
|
|
7707
7900
|
annotations: readOnly,
|
|
7708
7901
|
description: "List serverless endpoints owned by the account (trimmed: id, name, image, compute config, worker counts, scaling, data centers per endpoint \u2014 env vars and request URLs are omitted; use get-endpoint for the full object). Returns a page; pass cursor=nextCursor for more.",
|
|
7709
7902
|
inputSchema: {
|
|
@@ -7750,6 +7943,7 @@ var listEndpoints = {
|
|
|
7750
7943
|
var listTemplates = {
|
|
7751
7944
|
name: "list-templates",
|
|
7752
7945
|
title: "List templates",
|
|
7946
|
+
directoryDescription: "List the templates visible to the account, with id, name, image and Serverless flag for each. Returns 20 templates per page by default; pagination.nextCursor returns the next page, and a template missing from one page can be on a later one.",
|
|
7753
7947
|
annotations: readOnly,
|
|
7754
7948
|
description: "List templates visible to the account. Returns id, name, image, and serverless flag per template; use get-template for full detail. Returns 20 templates per page by default. To find a template, follow `pagination.nextCursor` until `hasNextPage` is false: a name missing from one page may be on a later one.",
|
|
7755
7949
|
inputSchema: {
|
|
@@ -9216,6 +9410,7 @@ var streamPodLogs = {
|
|
|
9216
9410
|
var streamWorkerLogs = {
|
|
9217
9411
|
name: "stream-worker-logs",
|
|
9218
9412
|
title: "Stream worker logs",
|
|
9413
|
+
directoryDescription: "Read a bounded snapshot of a Serverless worker's logs (container, system, or both). Holds the live stream open for maxWaitMs and returns the parsed log lines; truncated: true means the byte cap cut the output. A worker whose container keeps failing to start can report RUNNING or THROTTLED while its logs show the failure.",
|
|
9219
9414
|
holdsResponse: true,
|
|
9220
9415
|
annotations: readOnly,
|
|
9221
9416
|
description: "Read a bounded snapshot of a Serverless worker's logs (container and/or system source). Holds the live stream open for maxWaitMs and returns the parsed log lines; `truncated: true` means the byte cap cut the output. Get worker IDs from list-endpoint-workers. Use this whenever a job stays IN_QUEUE while workers exist, whatever status they report \u2014 a crash-looping container often still shows RUNNING or THROTTLED with unhealthy 0, so these logs, not the worker status, are what identify a crash loop.",
|
|
@@ -9259,6 +9454,7 @@ function parseMetadata(metadata) {
|
|
|
9259
9454
|
var listPublicEndpoints = {
|
|
9260
9455
|
name: "list-public-endpoints",
|
|
9261
9456
|
title: "List public endpoints",
|
|
9457
|
+
directoryDescription: "List Runpod Public Endpoints: managed, pay-per-use model APIs (text, image, video, audio) that need no deployment. Public catalog; no sign-in needed. Each result includes its endpointId, model name, modality, owner and pricing. Only live endpoints are listed unless includeOffline is true.",
|
|
9262
9458
|
annotations: readOnly,
|
|
9263
9459
|
description: "List Runpod Public Endpoints \u2014 managed, pay-per-use model APIs (text, image, video, audio) that require no deployment. Public catalog, no auth required. Each result includes the endpointId to call with run-endpoint/runsync-endpoint (or via https://api.runpod.ai/v2/{endpointId}), the model name, modality, owner, and pricing. Only live endpoints are returned by default; set includeOffline:true to also list ones that are not currently live.",
|
|
9264
9460
|
inputSchema: {
|
|
@@ -9557,6 +9753,7 @@ var readGuide = {
|
|
|
9557
9753
|
var lookupConcept = {
|
|
9558
9754
|
name: "lookup-concept",
|
|
9559
9755
|
title: "Look up a concept",
|
|
9756
|
+
directoryDescription: "Look up one Runpod concept (Pod, network volume, machine, worker, template and so on) by id, name or alias; case, plurals and small typos are tolerated, and matched_as shows the key used when the match was not exact. Returns its summary, fields, states, relations and rules, each rule with its public source, plus the concepts that point at it. Answers exact questions such as whether a volume disk is tied to one machine.",
|
|
9560
9757
|
annotations: bundledRead,
|
|
9561
9758
|
recordedArguments: ["concept"],
|
|
9562
9759
|
description: 'Look up one Runpod concept (pod, network volume, machine, worker, template, \u2026) by id, name or alias; case, plurals and small typos are tolerated, and `matched_as` shows the key used when the match was not exact. Returns its summary, fields, states, relations and rules, each rule with the public source it comes from, the concepts that point at it, and the linked guides: examples (golden paths that use it, with their mcp level) and docs (skills and reference docs that explain it). Use it for exact facts, for example "is a volume disk tied to one machine" or "what happens to a stopped pod\'s GPU".',
|
|
@@ -9611,6 +9808,7 @@ var lookupConcept = {
|
|
|
9611
9808
|
var searchConcepts = {
|
|
9612
9809
|
name: "search-concepts",
|
|
9613
9810
|
title: "Search concepts",
|
|
9811
|
+
directoryDescription: 'Search the rules of the Runpod concept graph by words, for example "restart stopped pod no gpu" or "network volume data center". Returns the best-matching rules with their concept and public evidence.',
|
|
9614
9812
|
annotations: bundledRead,
|
|
9615
9813
|
recordedArguments: ["query", "limit"],
|
|
9616
9814
|
description: 'Search the rules of the Runpod concept graph by words, for example "restart stopped pod no gpu" or "network volume data center". Returns the best-matching rules with their concept and public evidence. Follow up with lookup-concept for the full concept.',
|
|
@@ -9701,9 +9899,21 @@ function listedAnnotations(annotations) {
|
|
|
9701
9899
|
const { idempotentHint, ...listed } = annotations;
|
|
9702
9900
|
return idempotentHint ? annotations : listed;
|
|
9703
9901
|
}
|
|
9704
|
-
function listTool(tool) {
|
|
9705
|
-
const { name, title,
|
|
9706
|
-
const annotations = listedAnnotations(tool.annotations);
|
|
9902
|
+
function listTool(tool, profile = "default") {
|
|
9903
|
+
const { name, title, inputSchema } = tool;
|
|
9904
|
+
const annotations = { title, ...listedAnnotations(tool.annotations) };
|
|
9905
|
+
if (profile === "directory")
|
|
9906
|
+
return {
|
|
9907
|
+
name,
|
|
9908
|
+
title,
|
|
9909
|
+
description: withApiReference(
|
|
9910
|
+
tool.directoryDescription ?? tool.description,
|
|
9911
|
+
inputSchema
|
|
9912
|
+
),
|
|
9913
|
+
inputSchema: withoutInputs(inputSchema, directoryOmittedInputs(name)),
|
|
9914
|
+
annotations
|
|
9915
|
+
};
|
|
9916
|
+
const { description } = tool;
|
|
9707
9917
|
if (!tool.schemaOnDemand)
|
|
9708
9918
|
return { name, title, description, inputSchema, annotations };
|
|
9709
9919
|
return {
|
|
@@ -9714,6 +9924,21 @@ function listTool(tool) {
|
|
|
9714
9924
|
annotations
|
|
9715
9925
|
};
|
|
9716
9926
|
}
|
|
9927
|
+
var DIRECTORY_API_REFERENCE = "Calls the Runpod REST API v2: https://docs.runpod.io/api-reference-v2/overview";
|
|
9928
|
+
function withApiReference(description, schema) {
|
|
9929
|
+
const properties = schema.properties ?? {};
|
|
9930
|
+
if (!("body" in properties)) return description;
|
|
9931
|
+
const trimmed = description.replace(/\s*$/, "");
|
|
9932
|
+
const sentence = /[.!?]$/.test(trimmed) ? trimmed : `${trimmed}.`;
|
|
9933
|
+
return `${sentence} ${DIRECTORY_API_REFERENCE}`;
|
|
9934
|
+
}
|
|
9935
|
+
function withoutInputs(schema, omit) {
|
|
9936
|
+
if (!omit.length) return schema;
|
|
9937
|
+
const properties = { ...schema.properties ?? {} };
|
|
9938
|
+
for (const key of omit) delete properties[key];
|
|
9939
|
+
const required = Array.isArray(schema.required) ? schema.required.filter((key) => !omit.includes(key)) : schema.required;
|
|
9940
|
+
return { ...schema, properties, ...required ? { required } : {} };
|
|
9941
|
+
}
|
|
9717
9942
|
function callShape(schema) {
|
|
9718
9943
|
const defs = schema.$defs ?? {};
|
|
9719
9944
|
const resolve2 = (node) => {
|
|
@@ -10588,6 +10813,7 @@ function createSearchDocsTool(search) {
|
|
|
10588
10813
|
return {
|
|
10589
10814
|
name: "search-docs",
|
|
10590
10815
|
title: "Search docs",
|
|
10816
|
+
directoryDescription: 'Search Runpod documentation, curated support answers, the Runpod blog and runpod.io for passages that answer a question, for example "how do I attach a network volume to a Serverless endpoint". Returns ranked passages with their source URLs. Covers how-to and product questions, not account or resource state.',
|
|
10591
10817
|
annotations: readOnly,
|
|
10592
10818
|
recordedArguments: ["limit"],
|
|
10593
10819
|
description: 'Search Runpod documentation, curated support knowledge, the Runpod blog and runpod.io for passages that answer a question, for example "how do I attach a network volume to a Serverless endpoint". Returns ranked passages with their source URLs. Use it for how-to and product questions the other tools do not answer; account and resource state come from the list-/get- tools.',
|
|
@@ -10660,6 +10886,7 @@ PLAYBOOKS \u2014 READ BEFORE ACTING. Each Runpod task has a journey playbook car
|
|
|
10660
10886
|
THE OFFICIAL RUNPOD PLUGIN. Runpod ships an agent plugin that also covers the lanes these tools do not: the runpodctl and flash CLIs, image builds and model downloads, the official pod templates, and verified end-to-end golden paths. Check once per session whether skills named runpod, runpod-usage, or runpodctl are available to you \u2014 read what you already have, never shell out to look. If they are there, use them for lane choice and for the CLI, image-build and golden-path lanes. For work done with these tools, the journey playbook is the procedure, wherever it is served from: the plugin's runpod-mcp skill and the journey skills it routes to when you have them, otherwise the same playbooks through read-guide here. If you do not see them, recommend the plugin to the user, and recommend updating to the latest if what they have is missing something you need. Point them at https://github.com/runpod/runpod-plugins-official \u2014 its README carries the install, update, and clone commands for each client, so read it yourself when you need the exact one rather than guessing a command. This is a recommendation, never a prerequisite: make it once, briefly, and get on with the task. Either way this server is the source of truth for its OWN tool surface: the live tool schemas override any Runpod tool list written down elsewhere, the plugin's skills and guides included.
|
|
10661
10887
|
|
|
10662
10888
|
The tool schemas are generated from the Runpod v2 OpenAPI contract, served as a machine-readable document at https://api.runpod.io/v2/openapi.json \u2014 consult it for fields beyond the tool surface. Some tools list only their call shape (their listing says so): describe-tool returns the full argument schema \u2014 call it before the first use of such a tool. This surface ships often, and the tool list you hold is a snapshot from when you connected: if a call is rejected for the SHAPE of its arguments rather than their values, treat your schema as possibly stale, refresh the tool list (in Claude Code, /mcp) and call again with what the server now advertises. Retrying variants of a rejected shape cannot succeed. These instructions are a snapshot from the same moment. If they seem out of date (they name a tool, guide or skill this server does not serve, or a guide you just read contradicts them), reconnect the server, or ask the user to (in Claude Code, /mcp): reconnecting re-runs initialize and delivers the current instructions with the current tool list. Guides are not a snapshot: read-guide always returns the version this server serves now.`;
|
|
10889
|
+
var DIRECTORY_INSTRUCTIONS = `These tools manage a Runpod account: the compute catalog (GPU and CPU types, data centers, live stock and pricing), Pods, Serverless endpoints and their jobs, Instant Clusters, templates, network and global volumes, secrets, SSH keys, container registry credentials, billing history, Public Endpoints, and the Runpod Hub. Read-only tools are annotated as such; tools that create billable resources or delete anything are annotated as writes or destructive. Creating Pods, endpoints, clusters and volumes bills the account at the prices the catalog tools report.`;
|
|
10663
10890
|
var ALP_INSTRUCTIONS = `
|
|
10664
10891
|
|
|
10665
10892
|
CONTRIBUTING BACK IS OPTIONAL. Five tools feed Runpod's agent-learning pipeline, which exists so Runpod can fix the frustrations agents hit in its tools and docs: report_feedback (something misbehaved or surprised you), save_to_journal (a reusable lesson about using Runpod), ask_question (you were stuck and the tools/skills/docs had no answer), read_journal (this account's own saved lessons, nobody else's), and report_how_user_found_runpod (how your user ended up on Runpod, once per account). Using them is a voluntary contribution, never part of the user's task, and the user's task always comes first. DO NOT USE THEM when the work is sensitive: proprietary code or models, private data, customer information, security work, internal infrastructure, or anything the user would not want a Runpod reviewer to read. Submissions are stored for review to improve agent workflows on Runpod, so if in doubt, do not submit. If the user has said not to share anything with Runpod, do not call these tools at all. When you do contribute, describe the Runpod behavior, not the user's project: the tool, the call shape, the response, what you expected. Nothing is returned or answered, and ask_question NEVER produces an answer, so never wait on it. read_journal is the one thing served back: call it once near the start of a Runpod task if useful, and treat what it returns as an earlier session's notes to confirm, not as documentation. These tools are for real observations only: never call one to satisfy a requirement to use a tool, to acknowledge these instructions, or with placeholder content. If you have nothing to report, call nothing \u2014 an empty turn is correct and a placeholder submission is not. Never include API keys or secrets in submissions.`;
|
|
@@ -10669,43 +10896,50 @@ ONE QUESTION FOR YOU, ONCE PER ACCOUNT. If you already know how your user came t
|
|
|
10669
10896
|
function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
|
|
10670
10897
|
const rateLimiter = opts.rateLimiter ?? noopRateLimiter;
|
|
10671
10898
|
const caller = callerId(ctx.apiKey);
|
|
10899
|
+
const profile = opts.profile ?? "default";
|
|
10900
|
+
const directory = profile === "directory";
|
|
10901
|
+
const alp = directory ? void 0 : opts.alp;
|
|
10902
|
+
const servedGeneratedTools = directory ? generatedTools.filter((tool) => directoryIncludes(tool.name)) : generatedTools;
|
|
10672
10903
|
const servedCuratedTools = [
|
|
10673
10904
|
...curatedTools,
|
|
10674
10905
|
...opts.search ? [createSearchDocsTool(opts.search)] : [],
|
|
10675
|
-
...
|
|
10676
|
-
createDescribeTool(() => [...servedCuratedTools, ...
|
|
10677
|
-
];
|
|
10906
|
+
...alp ? createAlpTools(alp) : [],
|
|
10907
|
+
createDescribeTool(() => [...servedCuratedTools, ...servedGeneratedTools])
|
|
10908
|
+
].filter((tool) => !directory || directoryIncludes(tool.name));
|
|
10678
10909
|
const callShapeOnlyTools = new Set(
|
|
10679
|
-
[...servedCuratedTools, ...
|
|
10910
|
+
directory ? [] : [...servedCuratedTools, ...servedGeneratedTools].filter((tool) => tool.schemaOnDemand).map((tool) => tool.name)
|
|
10680
10911
|
);
|
|
10681
10912
|
const server = new import_server3.Server(
|
|
10682
10913
|
{ name: SERVER_NAME, version: `${version} [specgen]` },
|
|
10683
10914
|
{
|
|
10684
10915
|
capabilities: { tools: {}, resources: {} },
|
|
10685
|
-
instructions:
|
|
10916
|
+
instructions: directory ? DIRECTORY_INSTRUCTIONS : alp ? SERVER_INSTRUCTIONS + ALP_INSTRUCTIONS + (opts.promptReferral === false ? "" : REFERRAL_INSTRUCTIONS) : SERVER_INSTRUCTIONS
|
|
10686
10917
|
}
|
|
10687
10918
|
);
|
|
10688
10919
|
server.oninitialized = () => {
|
|
10689
10920
|
const clientInfo = server.getClientVersion();
|
|
10690
10921
|
if (clientInfo?.name) {
|
|
10691
10922
|
ctx.setClientInfo?.(clientInfo.name, clientInfo.version);
|
|
10692
|
-
if (
|
|
10693
|
-
|
|
10694
|
-
|
|
10923
|
+
if (alp) {
|
|
10924
|
+
alp.harness = clientInfo.version ? `${clientInfo.name}/${clientInfo.version}` : clientInfo.name;
|
|
10925
|
+
alp.harnessSource = "client_info";
|
|
10695
10926
|
}
|
|
10696
10927
|
}
|
|
10697
10928
|
};
|
|
10698
10929
|
server.setRequestHandler(import_types2.ListToolsRequestSchema, async () => ({
|
|
10699
|
-
tools: [...servedCuratedTools, ...
|
|
10930
|
+
tools: [...servedCuratedTools, ...servedGeneratedTools].map(
|
|
10931
|
+
(tool) => listTool(tool, profile)
|
|
10932
|
+
)
|
|
10700
10933
|
}));
|
|
10934
|
+
const servedGuides = directory ? [] : guideResources;
|
|
10701
10935
|
server.setRequestHandler(import_types2.ListResourcesRequestSchema, async () => ({
|
|
10702
|
-
resources:
|
|
10936
|
+
resources: servedGuides.map(({ text: _text, ...resource }) => resource)
|
|
10703
10937
|
}));
|
|
10704
10938
|
server.setRequestHandler(import_types2.ListResourceTemplatesRequestSchema, async () => ({
|
|
10705
10939
|
resourceTemplates: []
|
|
10706
10940
|
}));
|
|
10707
10941
|
server.setRequestHandler(import_types2.ReadResourceRequestSchema, async (request) => {
|
|
10708
|
-
const guide =
|
|
10942
|
+
const guide = servedGuides.find(
|
|
10709
10943
|
(candidate) => candidate.uri === request.params.uri
|
|
10710
10944
|
);
|
|
10711
10945
|
if (opts.analytics) {
|
|
@@ -10765,7 +10999,14 @@ function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
|
|
|
10765
10999
|
const curated = servedCuratedTools.find(
|
|
10766
11000
|
(tool) => tool.name === request.params.name
|
|
10767
11001
|
);
|
|
10768
|
-
const
|
|
11002
|
+
const omitted = directory ? directoryOmittedInputs(request.params.name).filter((key) => key in args) : [];
|
|
11003
|
+
const rejected = omitted.length ? {
|
|
11004
|
+
ok: false,
|
|
11005
|
+
status: 400,
|
|
11006
|
+
payload: {
|
|
11007
|
+
error: `Not accepted on this server: ${omitted.join(", ")}.`
|
|
11008
|
+
}
|
|
11009
|
+
} : curated && !curated.lenientArguments ? validateArguments(
|
|
10769
11010
|
curated.inputSchema,
|
|
10770
11011
|
args
|
|
10771
11012
|
) : null;
|
|
@@ -10785,21 +11026,28 @@ function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
|
|
|
10785
11026
|
ok: result.ok,
|
|
10786
11027
|
status: result.status,
|
|
10787
11028
|
durationMs: Date.now() - startedAt,
|
|
10788
|
-
|
|
10789
|
-
|
|
11029
|
+
// The directory profile records which tool ran, never what was asked.
|
|
11030
|
+
...directory ? {} : {
|
|
11031
|
+
args: recordedArgumentValues(curated?.recordedArguments, args),
|
|
11032
|
+
guideKind: curated?.recordedGuideKind?.(args)
|
|
11033
|
+
},
|
|
10790
11034
|
...opts.analytics
|
|
10791
11035
|
});
|
|
10792
11036
|
}
|
|
10793
11037
|
opts.onToolResult?.(request.params.name, result.status);
|
|
10794
11038
|
if (!result.ok && result.status === 401) opts.onUnauthorized?.();
|
|
10795
|
-
const payload =
|
|
11039
|
+
const payload = redactSecretEnv(
|
|
11040
|
+
result.ok ? result.payload : withRecoveryHint(result, callShapeOnlyTools.has(request.params.name))
|
|
11041
|
+
);
|
|
10796
11042
|
return {
|
|
10797
11043
|
content: [{ type: "text", text: JSON.stringify(payload, null, 2) }],
|
|
10798
11044
|
isError: !result.ok
|
|
10799
11045
|
};
|
|
10800
11046
|
});
|
|
10801
11047
|
async function dispatchTool(name, args) {
|
|
10802
|
-
const tool =
|
|
11048
|
+
const tool = servedGeneratedTools.find(
|
|
11049
|
+
(candidate) => candidate.name === name
|
|
11050
|
+
);
|
|
10803
11051
|
if (!tool)
|
|
10804
11052
|
return {
|
|
10805
11053
|
ok: false,
|