@runpod/mcp-server 4.4.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/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.4.0" : "dev";
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");
@@ -1510,8 +1510,10 @@ function coerceScalars(value, schema, defs, depth = 0) {
1510
1510
  var generatedTools = [
1511
1511
  {
1512
1512
  name: "create-cluster",
1513
+ title: "Create cluster",
1513
1514
  operationId: "createCluster",
1514
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.",
1515
1517
  method: "POST",
1516
1518
  path: "/v2/clusters",
1517
1519
  params: [],
@@ -1527,7 +1529,8 @@ var generatedTools = [
1527
1529
  type: "object",
1528
1530
  properties: {
1529
1531
  body: {
1530
- $ref: "#/$defs/CreateClusterRequest"
1532
+ $ref: "#/$defs/CreateClusterRequest",
1533
+ type: "object"
1531
1534
  }
1532
1535
  },
1533
1536
  required: ["body"],
@@ -1747,6 +1750,7 @@ var generatedTools = [
1747
1750
  },
1748
1751
  {
1749
1752
  name: "create-delegation",
1753
+ title: "Create ECR delegation",
1750
1754
  operationId: "createDelegation",
1751
1755
  description: "Register an ECR delegation",
1752
1756
  method: "POST",
@@ -1763,7 +1767,8 @@ var generatedTools = [
1763
1767
  type: "object",
1764
1768
  properties: {
1765
1769
  body: {
1766
- $ref: "#/$defs/CreateDelegationRequest"
1770
+ $ref: "#/$defs/CreateDelegationRequest",
1771
+ type: "object"
1767
1772
  }
1768
1773
  },
1769
1774
  required: ["body"],
@@ -1792,8 +1797,10 @@ var generatedTools = [
1792
1797
  },
1793
1798
  {
1794
1799
  name: "create-endpoint",
1800
+ title: "Create endpoint",
1795
1801
  operationId: "createEndpoint",
1796
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.",
1797
1804
  method: "POST",
1798
1805
  path: "/v2/serverless",
1799
1806
  params: [],
@@ -1809,7 +1816,8 @@ var generatedTools = [
1809
1816
  type: "object",
1810
1817
  properties: {
1811
1818
  body: {
1812
- $ref: "#/$defs/CreateEndpointRequest"
1819
+ $ref: "#/$defs/CreateEndpointRequest",
1820
+ type: "object"
1813
1821
  }
1814
1822
  },
1815
1823
  required: ["body"],
@@ -2237,6 +2245,7 @@ var generatedTools = [
2237
2245
  },
2238
2246
  {
2239
2247
  name: "create-global-volume",
2248
+ title: "Create global volume",
2240
2249
  operationId: "createGlobalVolume",
2241
2250
  description: "Create a global volume. Provisions a new global volume \u2014 storage that mounts into workloads in any data center. Only a `name` is required; storage is provisioned for you. Accounts have a cap on how many global volumes they can hold; creating one past it fails with `400`. Returns `201` with the created global volume, including its assigned `id`.",
2242
2251
  method: "POST",
@@ -2253,7 +2262,8 @@ var generatedTools = [
2253
2262
  type: "object",
2254
2263
  properties: {
2255
2264
  body: {
2256
- $ref: "#/$defs/CreateGlobalVolumeRequest"
2265
+ $ref: "#/$defs/CreateGlobalVolumeRequest",
2266
+ type: "object"
2257
2267
  }
2258
2268
  },
2259
2269
  required: ["body"],
@@ -2278,6 +2288,7 @@ var generatedTools = [
2278
2288
  },
2279
2289
  {
2280
2290
  name: "create-network-volume",
2291
+ title: "Create network volume",
2281
2292
  operationId: "createNetworkVolume",
2282
2293
  description: "Create a network volume. Provisions a new network volume \u2014 persistent, network-attached storage that can be mounted into pods and serverless workers. Required inputs are `name`, `size` (in GB), and `dataCenter`; an optional `type` selects the storage tier and is immutable after creation. See `CreateNetworkVolumeRequest` for the size bounds and tier options. This creates a billable persistent resource that keeps incurring storage charges until it is deleted. Returns `201` with the created network volume, including its assigned `id`.",
2283
2294
  method: "POST",
@@ -2294,7 +2305,8 @@ var generatedTools = [
2294
2305
  type: "object",
2295
2306
  properties: {
2296
2307
  body: {
2297
- $ref: "#/$defs/CreateNetworkVolumeRequest"
2308
+ $ref: "#/$defs/CreateNetworkVolumeRequest",
2309
+ type: "object"
2298
2310
  }
2299
2311
  },
2300
2312
  required: ["body"],
@@ -2343,8 +2355,10 @@ var generatedTools = [
2343
2355
  },
2344
2356
  {
2345
2357
  name: "create-pod",
2358
+ title: "Create Pod",
2346
2359
  operationId: "createPod",
2347
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.',
2348
2362
  method: "POST",
2349
2363
  path: "/v2/pods",
2350
2364
  params: [],
@@ -2360,7 +2374,8 @@ var generatedTools = [
2360
2374
  type: "object",
2361
2375
  properties: {
2362
2376
  body: {
2363
- $ref: "#/$defs/CreatePodRequest"
2377
+ $ref: "#/$defs/CreatePodRequest",
2378
+ type: "object"
2364
2379
  }
2365
2380
  },
2366
2381
  required: ["body"],
@@ -2710,6 +2725,7 @@ var generatedTools = [
2710
2725
  },
2711
2726
  {
2712
2727
  name: "create-registry",
2728
+ title: "Create registry credential",
2713
2729
  operationId: "createRegistry",
2714
2730
  description: "Create a container registry credential. Stores credentials for a private container registry. Credentials are write-only.",
2715
2731
  method: "POST",
@@ -2726,7 +2742,8 @@ var generatedTools = [
2726
2742
  type: "object",
2727
2743
  properties: {
2728
2744
  body: {
2729
- $ref: "#/$defs/CreateRegistryRequest"
2745
+ $ref: "#/$defs/CreateRegistryRequest",
2746
+ type: "object"
2730
2747
  }
2731
2748
  },
2732
2749
  required: ["body"],
@@ -2761,6 +2778,7 @@ var generatedTools = [
2761
2778
  },
2762
2779
  {
2763
2780
  name: "create-secret",
2781
+ title: "Create secret",
2764
2782
  operationId: "createSecret",
2765
2783
  description: "Create a secret. Stores a new account-scoped encrypted string. `name` must be unique across the account's secrets and is immutable; `value` is write-only and can never be read back through the API. Use the secret from pods, serverless endpoints, and templates by setting an environment variable's value to `{{ RUNPOD_SECRET_<name> }}` \u2014 Runpod substitutes the stored value when the pod or worker boots. Returns `201` with the created secret's metadata, or `409` when the name is already taken.",
2766
2784
  method: "POST",
@@ -2770,7 +2788,7 @@ var generatedTools = [
2770
2788
  annotations: {
2771
2789
  readOnlyHint: false,
2772
2790
  destructiveHint: false,
2773
- idempotentHint: false,
2791
+ idempotentHint: true,
2774
2792
  openWorldHint: true
2775
2793
  },
2776
2794
  schemaOnDemand: true,
@@ -2778,7 +2796,8 @@ var generatedTools = [
2778
2796
  type: "object",
2779
2797
  properties: {
2780
2798
  body: {
2781
- $ref: "#/$defs/CreateSecretRequest"
2799
+ $ref: "#/$defs/CreateSecretRequest",
2800
+ type: "object"
2782
2801
  }
2783
2802
  },
2784
2803
  required: ["body"],
@@ -2815,6 +2834,7 @@ var generatedTools = [
2815
2834
  },
2816
2835
  {
2817
2836
  name: "create-template",
2837
+ title: "Create template",
2818
2838
  operationId: "createTemplate",
2819
2839
  description: "Create a template. Creates a reusable container-configuration preset \u2014 image, disk, ports, env, registry, and mount settings \u2014 for pods and serverless endpoints. Pass its ID as `templateId` to `createPod` or `createEndpoint`, or spread its fields into the request body directly. Returns the created template.",
2820
2840
  method: "POST",
@@ -2832,7 +2852,8 @@ var generatedTools = [
2832
2852
  type: "object",
2833
2853
  properties: {
2834
2854
  body: {
2835
- $ref: "#/$defs/CreateTemplateRequest"
2855
+ $ref: "#/$defs/CreateTemplateRequest",
2856
+ type: "object"
2836
2857
  }
2837
2858
  },
2838
2859
  required: ["body"],
@@ -3016,8 +3037,10 @@ var generatedTools = [
3016
3037
  },
3017
3038
  {
3018
3039
  name: "delete-cluster",
3040
+ title: "Delete cluster",
3019
3041
  operationId: "deleteCluster",
3020
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.",
3021
3044
  method: "DELETE",
3022
3045
  path: "/v2/clusters/{id}",
3023
3046
  params: [
@@ -3046,8 +3069,10 @@ var generatedTools = [
3046
3069
  },
3047
3070
  {
3048
3071
  name: "delete-endpoint",
3072
+ title: "Delete endpoint",
3049
3073
  operationId: "deleteEndpoint",
3050
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.",
3051
3076
  method: "DELETE",
3052
3077
  path: "/v2/serverless/{id}",
3053
3078
  params: [
@@ -3076,6 +3101,7 @@ var generatedTools = [
3076
3101
  },
3077
3102
  {
3078
3103
  name: "delete-global-volume",
3104
+ title: "Delete global volume",
3079
3105
  operationId: "deleteGlobalVolume",
3080
3106
  description: "Delete a global volume. Permanently deletes a global volume and its stored data. Fails with `409` while the volume is still mounted: terminate every pod that mounts it (stopped pods count) and detach it from every serverless endpoint first. Nothing is detached or terminated on your behalf.",
3081
3107
  method: "DELETE",
@@ -3106,6 +3132,7 @@ var generatedTools = [
3106
3132
  },
3107
3133
  {
3108
3134
  name: "delete-network-volume",
3135
+ title: "Delete network volume",
3109
3136
  operationId: "deleteNetworkVolume",
3110
3137
  description: "Delete a network volume. Permanently deletes a network volume and releases its storage.",
3111
3138
  method: "DELETE",
@@ -3136,8 +3163,10 @@ var generatedTools = [
3136
3163
  },
3137
3164
  {
3138
3165
  name: "delete-pod",
3166
+ title: "Delete Pod",
3139
3167
  operationId: "deletePod",
3140
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.",
3141
3170
  method: "DELETE",
3142
3171
  path: "/v2/pods/{id}",
3143
3172
  params: [
@@ -3166,6 +3195,7 @@ var generatedTools = [
3166
3195
  },
3167
3196
  {
3168
3197
  name: "delete-registry",
3198
+ title: "Delete registry credential",
3169
3199
  operationId: "deleteRegistry",
3170
3200
  description: "Delete a container registry credential. Permanently deletes a container registry credential by ID. Rejected if any pod currently uses this credential to pull its image. Templates that reference it are not part of that check \u2014 they silently lose the reference (`registry` becomes null) instead of blocking the delete.",
3171
3201
  method: "DELETE",
@@ -3195,8 +3225,10 @@ var generatedTools = [
3195
3225
  },
3196
3226
  {
3197
3227
  name: "delete-secret",
3228
+ title: "Delete secret",
3198
3229
  operationId: "deleteSecret",
3199
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.",
3200
3232
  method: "DELETE",
3201
3233
  path: "/v2/account/secrets/{id}",
3202
3234
  params: [
@@ -3225,8 +3257,10 @@ var generatedTools = [
3225
3257
  },
3226
3258
  {
3227
3259
  name: "delete-template",
3260
+ title: "Delete template",
3228
3261
  operationId: "deleteTemplate",
3229
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.",
3230
3264
  method: "DELETE",
3231
3265
  path: "/v2/templates/{id}",
3232
3266
  params: [
@@ -3254,6 +3288,7 @@ var generatedTools = [
3254
3288
  },
3255
3289
  {
3256
3290
  name: "get-cluster",
3291
+ title: "Get cluster",
3257
3292
  operationId: "getCluster",
3258
3293
  description: "Get a cluster. Returns a single cluster by ID. The pods field is an aggregate summary (total + count by status); fetch the member pods themselves from /v2/clusters/{id}/pods.",
3259
3294
  method: "GET",
@@ -3284,6 +3319,7 @@ var generatedTools = [
3284
3319
  },
3285
3320
  {
3286
3321
  name: "get-cpu-type",
3322
+ title: "Get CPU type",
3287
3323
  operationId: "getCpuType",
3288
3324
  description: "Get a CPU type. Returns a single CPU type with pricing. Availability details are included only when requested with include=AVAILABILITY, which requires `product` \u2014 stock differs by product context.",
3289
3325
  method: "GET",
@@ -3360,6 +3396,7 @@ var generatedTools = [
3360
3396
  },
3361
3397
  {
3362
3398
  name: "get-data-center",
3399
+ title: "Get data center",
3363
3400
  operationId: "getDataCenter",
3364
3401
  description: "Get a data center. Returns a single data center. Availability is included only when requested with include=GPU_AVAILABILITY or include=CPU_AVAILABILITY.",
3365
3402
  method: "GET",
@@ -3409,6 +3446,7 @@ var generatedTools = [
3409
3446
  },
3410
3447
  {
3411
3448
  name: "get-endpoint",
3449
+ title: "Get endpoint",
3412
3450
  operationId: "getEndpoint",
3413
3451
  description: "Get a serverless endpoint. Returns a single serverless endpoint by ID.",
3414
3452
  method: "GET",
@@ -3439,6 +3477,7 @@ var generatedTools = [
3439
3477
  },
3440
3478
  {
3441
3479
  name: "get-endpoint-build",
3480
+ title: "Get endpoint build",
3442
3481
  operationId: "getEndpointBuild",
3443
3482
  description: "Get a serverless endpoint build. Returns one of the endpoint's GitHub builds by id, regardless of age \u2014 no need to page through `GET /v2/serverless/{id}/builds` to reach it.",
3444
3483
  method: "GET",
@@ -3477,6 +3516,7 @@ var generatedTools = [
3477
3516
  },
3478
3517
  {
3479
3518
  name: "get-global-volume",
3519
+ title: "Get global volume",
3480
3520
  operationId: "getGlobalVolume",
3481
3521
  description: "Get a global volume. Returns a single global volume by ID.",
3482
3522
  method: "GET",
@@ -3507,6 +3547,7 @@ var generatedTools = [
3507
3547
  },
3508
3548
  {
3509
3549
  name: "get-gpu-type",
3550
+ title: "Get GPU type",
3510
3551
  operationId: "getGpuType",
3511
3552
  description: "Get a GPU type. Returns a single GPU type with pricing. Availability details are included only when requested with include=AVAILABILITY, which requires `product` \u2014 stock differs by product context.",
3512
3553
  method: "GET",
@@ -3585,7 +3626,8 @@ var generatedTools = [
3585
3626
  },
3586
3627
  cloud: {
3587
3628
  $ref: "#/$defs/GpuCloudFilter",
3588
- 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"
3589
3631
  },
3590
3632
  countryCodes: {
3591
3633
  type: "array",
@@ -3631,6 +3673,7 @@ var generatedTools = [
3631
3673
  },
3632
3674
  {
3633
3675
  name: "get-network-volume",
3676
+ title: "Get network volume",
3634
3677
  operationId: "getNetworkVolume",
3635
3678
  description: "Get a network volume. Returns a single network volume by ID.",
3636
3679
  method: "GET",
@@ -3661,6 +3704,7 @@ var generatedTools = [
3661
3704
  },
3662
3705
  {
3663
3706
  name: "get-organization",
3707
+ title: "Get organization",
3664
3708
  operationId: "getOrganization",
3665
3709
  description: "Get your current organization. Returns the authenticated caller's current organization. Organization context comes from the caller's membership; no organization selector is required. Returns 404 when the caller does not belong to an organization, or 403 when organizations are unavailable to the caller.",
3666
3710
  method: "GET",
@@ -3680,6 +3724,7 @@ var generatedTools = [
3680
3724
  },
3681
3725
  {
3682
3726
  name: "get-pod",
3727
+ title: "Get Pod",
3683
3728
  operationId: "getPod",
3684
3729
  description: "Get a pod. Returns a single pod by ID.",
3685
3730
  method: "GET",
@@ -3710,6 +3755,7 @@ var generatedTools = [
3710
3755
  },
3711
3756
  {
3712
3757
  name: "get-registry",
3758
+ title: "Get registry credential",
3713
3759
  operationId: "getRegistry",
3714
3760
  description: "Get a container registry credential. Returns a single container registry credential by ID. `username` and `password` are never included in the response \u2014 credentials are write-only, matching `createRegistry`.",
3715
3761
  method: "GET",
@@ -3739,6 +3785,7 @@ var generatedTools = [
3739
3785
  },
3740
3786
  {
3741
3787
  name: "get-secret",
3788
+ title: "Get secret",
3742
3789
  operationId: "getSecret",
3743
3790
  description: "Get a secret. Returns a single secret's metadata by ID. The value is write-only and never returned.",
3744
3791
  method: "GET",
@@ -3769,6 +3816,7 @@ var generatedTools = [
3769
3816
  },
3770
3817
  {
3771
3818
  name: "get-ssh-keys",
3819
+ title: "Get SSH keys",
3772
3820
  operationId: "getSshKeys",
3773
3821
  description: "List registered SSH public keys. Returns the account's registered SSH public keys \u2014 the keys provisioned into pods created with `startSsh` and used to authenticate the SSH connections reported in a pod's `ssh` block.",
3774
3822
  method: "GET",
@@ -3788,6 +3836,7 @@ var generatedTools = [
3788
3836
  },
3789
3837
  {
3790
3838
  name: "get-template",
3839
+ title: "Get template",
3791
3840
  operationId: "getTemplate",
3792
3841
  description: "Get a template. Returns the full configuration of a single template by ID. Serves both templates you own and public catalog templates \u2014 everything you can read. Updates and deletes remain restricted to templates you own.",
3793
3842
  method: "GET",
@@ -3817,6 +3866,7 @@ var generatedTools = [
3817
3866
  },
3818
3867
  {
3819
3868
  name: "list-billing",
3869
+ title: "List billing",
3820
3870
  operationId: "listBilling",
3821
3871
  description: "Get aggregated billing history. Returns time-bucketed total spend across all billable Runpod resources for the authenticated user. Use startTime/endTime with bucketSize for an explicit range, or lastN with bucketSize for the most recent buckets. Each record reports one bucket's total plus pod, serverless, storage, public endpoint, and Instant Cluster cost components. The metadata block echoes the resolved query window, record count, and totals across all returned buckets.",
3822
3872
  method: "GET",
@@ -3861,7 +3911,8 @@ var generatedTools = [
3861
3911
  },
3862
3912
  bucketSize: {
3863
3913
  $ref: "#/$defs/BillingBucketSize",
3864
- description: "Length of each billing time bucket. Defaults to day."
3914
+ description: "Length of each billing time bucket. Defaults to day.",
3915
+ type: "string"
3865
3916
  },
3866
3917
  lastN: {
3867
3918
  type: "integer",
@@ -3889,6 +3940,7 @@ var generatedTools = [
3889
3940
  },
3890
3941
  {
3891
3942
  name: "list-cluster-billing",
3943
+ title: "List cluster billing",
3892
3944
  operationId: "listClusterBilling",
3893
3945
  description: "Get cluster billing history. Returns Cluster billing history for the authenticated user, split into time buckets by startTime/endTime with bucketSize or by lastN recent buckets. Use clusterId to filter to one cluster; without it, records are emitted per cluster per bucket. Each record includes GPU compute, disk, inter-node networking, and total amounts. Clusters are GPU-only, so no CPU cost component is returned.",
3894
3946
  method: "GET",
@@ -3937,7 +3989,8 @@ var generatedTools = [
3937
3989
  },
3938
3990
  bucketSize: {
3939
3991
  $ref: "#/$defs/BillingBucketSize",
3940
- description: "Length of each billing time bucket. Defaults to day."
3992
+ description: "Length of each billing time bucket. Defaults to day.",
3993
+ type: "string"
3941
3994
  },
3942
3995
  lastN: {
3943
3996
  type: "integer",
@@ -3969,6 +4022,7 @@ var generatedTools = [
3969
4022
  },
3970
4023
  {
3971
4024
  name: "list-cluster-pods",
4025
+ title: "List cluster Pods",
3972
4026
  operationId: "listClusterPods",
3973
4027
  description: "List a cluster's pods. Returns the full member pods of a cluster. The cluster summary (`GET /v2/clusters/{id}`) carries only aggregate pod counts; this endpoint returns each member as a complete Pod object.",
3974
4028
  method: "GET",
@@ -3999,6 +4053,7 @@ var generatedTools = [
3999
4053
  },
4000
4054
  {
4001
4055
  name: "list-clusters",
4056
+ title: "List clusters",
4002
4057
  operationId: "listClusters",
4003
4058
  description: "List clusters. Returns clusters owned by the authenticated user, cursor-paginated newest-first; an omitted `limit` defaults to 1000. Follow `pagination.nextCursor` until `hasNextPage` is false.",
4004
4059
  method: "GET",
@@ -4039,6 +4094,7 @@ var generatedTools = [
4039
4094
  },
4040
4095
  {
4041
4096
  name: "list-cpu-types",
4097
+ title: "List CPU types",
4042
4098
  operationId: "listCpuTypes",
4043
4099
  description: "List CPU types. Returns available CPU flavors. Availability is included only when requested with include=AVAILABILITY, which requires `product` \u2014 stock differs by product context.",
4044
4100
  method: "GET",
@@ -4107,6 +4163,7 @@ var generatedTools = [
4107
4163
  },
4108
4164
  {
4109
4165
  name: "list-data-centers",
4166
+ title: "List data centers",
4110
4167
  operationId: "listDataCenters",
4111
4168
  description: "List data centers. Returns available data center locations with region, compliance, supported network volume tiers, and global networking support. Use include=GPU_AVAILABILITY or include=CPU_AVAILABILITY to add per-resource availability arrays to each data center. The regions, networkVolumeTypes, compliance, and globalNetwork query parameters filter the list before it is returned.",
4112
4169
  method: "GET",
@@ -4234,6 +4291,7 @@ var generatedTools = [
4234
4291
  },
4235
4292
  {
4236
4293
  name: "list-delegations",
4294
+ title: "List ECR delegations",
4237
4295
  operationId: "listDelegations",
4238
4296
  description: "List all ECR delegations",
4239
4297
  method: "GET",
@@ -4253,6 +4311,7 @@ var generatedTools = [
4253
4311
  },
4254
4312
  {
4255
4313
  name: "list-endpoint-billing",
4314
+ title: "List endpoint billing",
4256
4315
  operationId: "listEndpointBilling",
4257
4316
  description: "Get public endpoint billing history. Returns Runpod public endpoint billing history for the authenticated user, split into time buckets by startTime/endTime with bucketSize or by lastN recent buckets. Each record reports the endpoint total for one bucket, and metadata echoes the resolved query window, record count, and total endpoint amount across all returned records.",
4258
4317
  method: "GET",
@@ -4297,7 +4356,8 @@ var generatedTools = [
4297
4356
  },
4298
4357
  bucketSize: {
4299
4358
  $ref: "#/$defs/BillingBucketSize",
4300
- description: "Length of each billing time bucket. Defaults to day."
4359
+ description: "Length of each billing time bucket. Defaults to day.",
4360
+ type: "string"
4301
4361
  },
4302
4362
  lastN: {
4303
4363
  type: "integer",
@@ -4325,6 +4385,7 @@ var generatedTools = [
4325
4385
  },
4326
4386
  {
4327
4387
  name: "list-endpoint-builds",
4388
+ title: "List endpoint builds",
4328
4389
  operationId: "listEndpointBuilds",
4329
4390
  description: "List serverless endpoint builds. Returns the endpoint's GitHub build history, newest first (Runpod GitHub-build integration), cursor-paginated; an omitted `limit` defaults to 100, so a bare request returns at most the 100 most recent builds. Any build can also be fetched by id via `GET /v2/serverless/{id}/builds/{buildId}`. Stream a build's logs via `/v2/serverless/{id}/builds/{buildId}/logs`.",
4330
4391
  method: "GET",
@@ -4374,6 +4435,7 @@ var generatedTools = [
4374
4435
  },
4375
4436
  {
4376
4437
  name: "list-endpoint-releases",
4438
+ title: "List endpoint releases",
4377
4439
  operationId: "listEndpointReleases",
4378
4440
  description: "List serverless endpoint releases. Returns the endpoint's release history (newest first) plus a rollout summary of how many workers are running the current version. Each release is a versioned configuration snapshot with a `diff` of what changed; build-driven releases carry a `buildId` (fetch build detail via the builds sub-routes). Releases are cursor-paginated newest-first; an omitted `limit` defaults to 1000. The rollout summary always describes the endpoint's current state, independent of the page requested.",
4379
4441
  method: "GET",
@@ -4423,6 +4485,7 @@ var generatedTools = [
4423
4485
  },
4424
4486
  {
4425
4487
  name: "list-endpoint-workers",
4488
+ title: "List endpoint workers",
4426
4489
  operationId: "listEndpointWorkers",
4427
4490
  description: "List serverless endpoint workers. Lists the active workers for a serverless endpoint. **Returns.** A `200` with a `ListEndpointWorkersResponse`: a `workers` array (one entry per active worker, each carrying its `id`, `status`, and runtime details) plus a `summary` of worker counts grouped by status. Only currently active workers are included; scaled-down workers are not returned. **How `status` is determined.** Each worker's `status` is derived by reconciling the worker pod's lifecycle status with the endpoint's live job-queue view (which workers are actively serving requests). When the job-queue view is unavailable, the response degrades gracefully: the shape is unchanged, but each `status` and the summary counts fall back to pod lifecycle alone.",
4428
4491
  method: "GET",
@@ -4453,6 +4516,7 @@ var generatedTools = [
4453
4516
  },
4454
4517
  {
4455
4518
  name: "list-global-volumes",
4519
+ title: "List global volumes",
4456
4520
  operationId: "listGlobalVolumes",
4457
4521
  description: "List global volumes. Returns global volumes owned by the authenticated user, cursor-paginated newest-first; an omitted `limit` defaults to 1000. Follow `pagination.nextCursor` until `hasNextPage` is false.",
4458
4522
  method: "GET",
@@ -4493,6 +4557,7 @@ var generatedTools = [
4493
4557
  },
4494
4558
  {
4495
4559
  name: "list-gpu-types",
4560
+ title: "List GPU types",
4496
4561
  operationId: "listGpuTypes",
4497
4562
  description: 'List GPU types. Returns available GPU types with pricing. Availability is included only when requested with include=AVAILABILITY, which requires `product` \u2014 stock differs by product context. With countryCodes, the list is narrowed to GPU types deployable in those countries, so "this geography + this chip" resolves in one read.',
4498
4563
  method: "GET",
@@ -4564,7 +4629,8 @@ var generatedTools = [
4564
4629
  },
4565
4630
  cloud: {
4566
4631
  $ref: "#/$defs/GpuCloudFilter",
4567
- 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"
4568
4634
  },
4569
4635
  countryCodes: {
4570
4636
  type: "array",
@@ -4609,6 +4675,7 @@ var generatedTools = [
4609
4675
  },
4610
4676
  {
4611
4677
  name: "list-network-volume-billing",
4678
+ title: "List network volume billing",
4612
4679
  operationId: "listNetworkVolumeBilling",
4613
4680
  description: "Get network volume billing history. Returns network volume billing history for the authenticated user, split into time buckets by startTime/endTime with bucketSize or by lastN recent buckets. Use networkVolumeId to filter to one volume; without it, records are emitted per volume per bucket. Each record includes standard storage, high-performance storage, and total amounts, while metadata reports the resolved query, distinct volume count, and totals across the returned records.",
4614
4681
  method: "GET",
@@ -4657,7 +4724,8 @@ var generatedTools = [
4657
4724
  },
4658
4725
  bucketSize: {
4659
4726
  $ref: "#/$defs/BillingBucketSize",
4660
- description: "Length of each billing time bucket. Defaults to day."
4727
+ description: "Length of each billing time bucket. Defaults to day.",
4728
+ type: "string"
4661
4729
  },
4662
4730
  lastN: {
4663
4731
  type: "integer",
@@ -4689,6 +4757,7 @@ var generatedTools = [
4689
4757
  },
4690
4758
  {
4691
4759
  name: "list-network-volumes",
4760
+ title: "List network volumes",
4692
4761
  operationId: "listNetworkVolumes",
4693
4762
  description: "List network volumes. Returns network volumes owned by the authenticated user, cursor-paginated newest-first; an omitted `limit` defaults to 1000. Follow `pagination.nextCursor` until `hasNextPage` is false.",
4694
4763
  method: "GET",
@@ -4729,6 +4798,7 @@ var generatedTools = [
4729
4798
  },
4730
4799
  {
4731
4800
  name: "list-pod-billing",
4801
+ title: "List Pod billing",
4732
4802
  operationId: "listPodBilling",
4733
4803
  description: "Get pod billing history. Returns pod-only billing detail for the authenticated user, split into time buckets by startTime/endTime with bucketSize or by lastN recent buckets. Use podId to narrow the response to one GPU or CPU pod; without it, records are emitted per pod per bucket. Each record includes podId, GPU, CPU, disk, and total amounts, while metadata echoes the resolved query and totals across the pod records. Use listBilling when you need aggregate spend across every billable resource family.",
4734
4804
  method: "GET",
@@ -4777,7 +4847,8 @@ var generatedTools = [
4777
4847
  },
4778
4848
  bucketSize: {
4779
4849
  $ref: "#/$defs/BillingBucketSize",
4780
- description: "Length of each billing time bucket. Defaults to day."
4850
+ description: "Length of each billing time bucket. Defaults to day.",
4851
+ type: "string"
4781
4852
  },
4782
4853
  lastN: {
4783
4854
  type: "integer",
@@ -4809,6 +4880,7 @@ var generatedTools = [
4809
4880
  },
4810
4881
  {
4811
4882
  name: "list-pods",
4883
+ title: "List Pods",
4812
4884
  operationId: "listPods",
4813
4885
  description: "List pods. Returns pods owned by the authenticated user. Cluster member pods are excluded by default; set `includeClusterPods=true` to include them (each carries a non-null `cluster` membership block). Results are cursor-paginated newest-first; an omitted `limit` defaults to 1000. The cluster-member exclusion is applied before the page is cut, so a page holds `limit` pods whenever that many remain. Follow `pagination.nextCursor` until `hasNextPage` is false.",
4814
4886
  method: "GET",
@@ -4858,6 +4930,7 @@ var generatedTools = [
4858
4930
  },
4859
4931
  {
4860
4932
  name: "list-public-templates",
4933
+ title: "List public templates",
4861
4934
  operationId: "listPublicTemplates",
4862
4935
  description: "List public templates. Returns the public template catalog. `source` selects which slice: `official` (the default) is Runpod-curated templates, `verified` is community templates Runpod has verified, and `community` is everything else other users have shared publicly. Both pod and serverless templates appear \u2014 use each entry's `serverless` flag to tell them apart. `registry` is always null for templates you don't own. Your own templates (public or private) are managed under `/v2/templates`; fetch any individual template \u2014 catalog or owned \u2014 via `/v2/templates/{id}`. At most 100 templates are returned. Cursor pagination is not yet supported here; `pagination` is always the exhausted marker (`nextCursor: null`, `hasNextPage: false`).",
4863
4936
  method: "GET",
@@ -4889,6 +4962,7 @@ var generatedTools = [
4889
4962
  },
4890
4963
  {
4891
4964
  name: "list-registries",
4965
+ title: "List registry credentials",
4892
4966
  operationId: "listRegistries",
4893
4967
  description: "List container registries. Returns all container registry credentials owned by the authenticated user.",
4894
4968
  method: "GET",
@@ -4908,6 +4982,7 @@ var generatedTools = [
4908
4982
  },
4909
4983
  {
4910
4984
  name: "list-secrets",
4985
+ title: "List secrets",
4911
4986
  operationId: "listSecrets",
4912
4987
  description: "List secrets. Returns the account's secrets \u2014 encrypted strings referenced from pod, serverless, and template environment variables with the `{{ RUNPOD_SECRET_<name> }}` placeholder syntax, substituted with the secret's value when the pod or worker boots. Secret values are write-only and are never returned.",
4913
4988
  method: "GET",
@@ -4937,8 +5012,10 @@ var generatedTools = [
4937
5012
  },
4938
5013
  {
4939
5014
  name: "list-serverless-billing",
5015
+ title: "List Serverless billing",
4940
5016
  operationId: "listServerlessBilling",
4941
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.",
4942
5019
  method: "GET",
4943
5020
  path: "/v2/billing/serverless",
4944
5021
  params: [
@@ -4985,7 +5062,8 @@ var generatedTools = [
4985
5062
  },
4986
5063
  bucketSize: {
4987
5064
  $ref: "#/$defs/BillingBucketSize",
4988
- description: "Length of each billing time bucket. Defaults to day."
5065
+ description: "Length of each billing time bucket. Defaults to day.",
5066
+ type: "string"
4989
5067
  },
4990
5068
  lastN: {
4991
5069
  type: "integer",
@@ -5017,6 +5095,7 @@ var generatedTools = [
5017
5095
  },
5018
5096
  {
5019
5097
  name: "pod-action",
5098
+ title: "Start, stop, restart, or terminate a Pod",
5020
5099
  operationId: "podAction",
5021
5100
  description: "Trigger a pod state transition. Triggers a state transition on a pod. Send a JSON body with a single `action` field, e.g. `{ \"action\": \"stop\" }`. Valid actions: - `start` \u2014 boot a stopped pod (`EXITED` or `ERROR`) back toward `RUNNING`. - `stop` \u2014 stop a running or provisioning pod, releasing GPU/CPU compute while keeping its disk. The pod moves to `EXITED`. - `restart` \u2014 restart a `RUNNING` pod's container in place. - `terminate` \u2014 permanently delete the pod and release its resources (equivalent to `deletePod`). Which actions are valid depends on the pod's current status, and the currently permitted set is published in the pod's `actions` field: `RUNNING` allows `stop`/`restart`/`terminate`; `EXITED` and `ERROR` allow `start`/`terminate`; `PROVISIONING` and `STARTING` allow `stop`/`terminate`. `start`, `stop`, and `restart` return `200` with the updated pod. `terminate` returns `204` with no body. Requesting an action that is not valid for the pod's current status returns `409`.",
5022
5101
  method: "POST",
@@ -5041,7 +5120,8 @@ var generatedTools = [
5041
5120
  type: "string"
5042
5121
  },
5043
5122
  body: {
5044
- $ref: "#/$defs/PodActionRequest"
5123
+ $ref: "#/$defs/PodActionRequest",
5124
+ type: "object"
5045
5125
  }
5046
5126
  },
5047
5127
  required: ["id", "body"],
@@ -5066,6 +5146,7 @@ var generatedTools = [
5066
5146
  },
5067
5147
  {
5068
5148
  name: "revoke-delegation",
5149
+ title: "Revoke ECR delegation",
5069
5150
  operationId: "revokeDelegation",
5070
5151
  description: "Revoke an ECR delegation",
5071
5152
  method: "DELETE",
@@ -5095,6 +5176,7 @@ var generatedTools = [
5095
5176
  },
5096
5177
  {
5097
5178
  name: "update-cluster",
5179
+ title: "Update cluster",
5098
5180
  operationId: "updateCluster",
5099
5181
  description: "Rename a cluster. Renames a cluster. This endpoint only changes the cluster name \u2014 compute shape, type, and container configuration are fixed at creation and cannot be updated.",
5100
5182
  method: "PATCH",
@@ -5109,7 +5191,7 @@ var generatedTools = [
5109
5191
  annotations: {
5110
5192
  readOnlyHint: false,
5111
5193
  destructiveHint: false,
5112
- idempotentHint: false,
5194
+ idempotentHint: true,
5113
5195
  openWorldHint: true
5114
5196
  },
5115
5197
  inputSchema: {
@@ -5120,7 +5202,8 @@ var generatedTools = [
5120
5202
  description: "Cluster identifier"
5121
5203
  },
5122
5204
  body: {
5123
- $ref: "#/$defs/UpdateClusterRequest"
5205
+ $ref: "#/$defs/UpdateClusterRequest",
5206
+ type: "object"
5124
5207
  }
5125
5208
  },
5126
5209
  required: ["id", "body"],
@@ -5143,8 +5226,10 @@ var generatedTools = [
5143
5226
  },
5144
5227
  {
5145
5228
  name: "update-endpoint",
5229
+ title: "Update endpoint",
5146
5230
  operationId: "updateEndpoint",
5147
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.",
5148
5233
  method: "PATCH",
5149
5234
  path: "/v2/serverless/{id}",
5150
5235
  params: [
@@ -5156,7 +5241,7 @@ var generatedTools = [
5156
5241
  hasBody: true,
5157
5242
  annotations: {
5158
5243
  readOnlyHint: false,
5159
- destructiveHint: false,
5244
+ destructiveHint: true,
5160
5245
  idempotentHint: false,
5161
5246
  openWorldHint: true
5162
5247
  },
@@ -5169,7 +5254,8 @@ var generatedTools = [
5169
5254
  description: "Serverless endpoint identifier"
5170
5255
  },
5171
5256
  body: {
5172
- $ref: "#/$defs/UpdateEndpointRequest"
5257
+ $ref: "#/$defs/UpdateEndpointRequest",
5258
+ type: "object"
5173
5259
  }
5174
5260
  },
5175
5261
  required: ["id", "body"],
@@ -5533,6 +5619,7 @@ var generatedTools = [
5533
5619
  },
5534
5620
  {
5535
5621
  name: "update-global-volume",
5622
+ title: "Update global volume",
5536
5623
  operationId: "updateGlobalVolume",
5537
5624
  description: "Update a global volume. Updates mutable fields on a global volume. Only provided fields are changed.",
5538
5625
  method: "PATCH",
@@ -5547,7 +5634,7 @@ var generatedTools = [
5547
5634
  annotations: {
5548
5635
  readOnlyHint: false,
5549
5636
  destructiveHint: false,
5550
- idempotentHint: false,
5637
+ idempotentHint: true,
5551
5638
  openWorldHint: true
5552
5639
  },
5553
5640
  inputSchema: {
@@ -5558,7 +5645,8 @@ var generatedTools = [
5558
5645
  description: "Global volume identifier"
5559
5646
  },
5560
5647
  body: {
5561
- $ref: "#/$defs/UpdateGlobalVolumeRequest"
5648
+ $ref: "#/$defs/UpdateGlobalVolumeRequest",
5649
+ type: "object"
5562
5650
  }
5563
5651
  },
5564
5652
  required: ["id", "body"],
@@ -5584,6 +5672,7 @@ var generatedTools = [
5584
5672
  },
5585
5673
  {
5586
5674
  name: "update-network-volume",
5675
+ title: "Update network volume",
5587
5676
  operationId: "updateNetworkVolume",
5588
5677
  description: "Update a network volume. Updates mutable fields on a network volume. Only provided fields are changed. Note: `size` may only increase; attempts to reduce size will be rejected.",
5589
5678
  method: "PATCH",
@@ -5598,7 +5687,7 @@ var generatedTools = [
5598
5687
  annotations: {
5599
5688
  readOnlyHint: false,
5600
5689
  destructiveHint: false,
5601
- idempotentHint: false,
5690
+ idempotentHint: true,
5602
5691
  openWorldHint: true
5603
5692
  },
5604
5693
  inputSchema: {
@@ -5609,7 +5698,8 @@ var generatedTools = [
5609
5698
  description: "Network volume identifier"
5610
5699
  },
5611
5700
  body: {
5612
- $ref: "#/$defs/UpdateNetworkVolumeRequest"
5701
+ $ref: "#/$defs/UpdateNetworkVolumeRequest",
5702
+ type: "object"
5613
5703
  }
5614
5704
  },
5615
5705
  required: ["id", "body"],
@@ -5640,6 +5730,7 @@ var generatedTools = [
5640
5730
  },
5641
5731
  {
5642
5732
  name: "update-pod",
5733
+ title: "Update Pod",
5643
5734
  operationId: "updatePod",
5644
5735
  description: "Update a pod. Partially updates a pod's configuration. This is a PATCH: only the fields present in the body are changed, and omitted fields are left untouched. Use empty values only when you explicitly mean to clear a field (for example, set `registry` to `null` or set `ports` to `[]`). See `UpdatePodRequest` for the full body. Mutable fields: `name`, `image`, `args`, `disk`, `ports`, `env`, `registry`, `mounts`, `locked`, and `globalNetworking`. Some changes apply immediately while others (e.g. `globalNetworking`) take effect on the pod's next start/restart, as noted on the individual fields. Pods that belong to a Cluster cannot be updated here \u2014 manage them through `/v2/clusters/{id}`. Returns `200` with the full updated pod.",
5645
5736
  method: "PATCH",
@@ -5653,7 +5744,7 @@ var generatedTools = [
5653
5744
  hasBody: true,
5654
5745
  annotations: {
5655
5746
  readOnlyHint: false,
5656
- destructiveHint: false,
5747
+ destructiveHint: true,
5657
5748
  idempotentHint: false,
5658
5749
  openWorldHint: true
5659
5750
  },
@@ -5666,7 +5757,8 @@ var generatedTools = [
5666
5757
  description: "Pod identifier"
5667
5758
  },
5668
5759
  body: {
5669
- $ref: "#/$defs/UpdatePodRequest"
5760
+ $ref: "#/$defs/UpdatePodRequest",
5761
+ type: "object"
5670
5762
  }
5671
5763
  },
5672
5764
  required: ["id", "body"],
@@ -5881,6 +5973,7 @@ var generatedTools = [
5881
5973
  },
5882
5974
  {
5883
5975
  name: "update-secret",
5976
+ title: "Update secret",
5884
5977
  operationId: "updateSecret",
5885
5978
  description: "Update a secret. Rotates a secret's value and/or updates its description. Only the provided fields are changed and at least one field is required; the `name` is immutable. Pods and workers receive the new value at their next boot \u2014 running instances keep the value they were started with. When both fields are sent, the value is applied first, then the description. The two updates are not atomic: if the description update fails after the value was rotated, the response is an error but the new value has already taken effect. Send the fields in separate requests when that partial outcome matters.",
5886
5979
  method: "PATCH",
@@ -5894,7 +5987,7 @@ var generatedTools = [
5894
5987
  hasBody: true,
5895
5988
  annotations: {
5896
5989
  readOnlyHint: false,
5897
- destructiveHint: false,
5990
+ destructiveHint: true,
5898
5991
  idempotentHint: false,
5899
5992
  openWorldHint: true
5900
5993
  },
@@ -5907,7 +6000,8 @@ var generatedTools = [
5907
6000
  description: "Secret identifier"
5908
6001
  },
5909
6002
  body: {
5910
- $ref: "#/$defs/UpdateSecretRequest"
6003
+ $ref: "#/$defs/UpdateSecretRequest",
6004
+ type: "object"
5911
6005
  }
5912
6006
  },
5913
6007
  required: ["id", "body"],
@@ -5936,6 +6030,7 @@ var generatedTools = [
5936
6030
  },
5937
6031
  {
5938
6032
  name: "update-ssh-keys",
6033
+ title: "Update SSH keys",
5939
6034
  operationId: "updateSshKeys",
5940
6035
  description: "Replace registered SSH public keys. Replaces the account's full set of registered SSH public keys. Existing keys not present in the request are removed; send `[]` to remove all keys. Keys take effect for pods created afterwards with `startSsh` \u2014 running pods are not updated.",
5941
6036
  method: "PUT",
@@ -5952,7 +6047,8 @@ var generatedTools = [
5952
6047
  type: "object",
5953
6048
  properties: {
5954
6049
  body: {
5955
- $ref: "#/$defs/UpdateSshKeysRequest"
6050
+ $ref: "#/$defs/UpdateSshKeysRequest",
6051
+ type: "object"
5956
6052
  }
5957
6053
  },
5958
6054
  required: ["body"],
@@ -5982,6 +6078,7 @@ var generatedTools = [
5982
6078
  },
5983
6079
  {
5984
6080
  name: "update-template",
6081
+ title: "Update template",
5985
6082
  operationId: "updateTemplate",
5986
6083
  description: "Update a template. Partially updates a template. This is a PATCH: only the fields present in the body are changed; omitted fields are left untouched. See `UpdateTemplateRequest` for the full body. Mutable fields: `name`, `image`, `args`, `disk`, `ports`, `env`, `registry`, `mounts`, `serverless`, `public`, and `category`. Only the template's owner can update it (authenticated via the request's API key); public catalog templates are readable via GET but return `404` here. Returns `200` with the full updated template. Pods and endpoints already created from this template are not changed retroactively \u2014 the template is a snapshot applied at creation time.",
5987
6084
  method: "PATCH",
@@ -5996,7 +6093,7 @@ var generatedTools = [
5996
6093
  annotations: {
5997
6094
  readOnlyHint: false,
5998
6095
  destructiveHint: false,
5999
- idempotentHint: false,
6096
+ idempotentHint: true,
6000
6097
  openWorldHint: true
6001
6098
  },
6002
6099
  schemaOnDemand: true,
@@ -6007,7 +6104,8 @@ var generatedTools = [
6007
6104
  type: "string"
6008
6105
  },
6009
6106
  body: {
6010
- $ref: "#/$defs/UpdateTemplateRequest"
6107
+ $ref: "#/$defs/UpdateTemplateRequest",
6108
+ type: "object"
6011
6109
  }
6012
6110
  },
6013
6111
  required: ["id", "body"],
@@ -6176,6 +6274,142 @@ var generatedTools = [
6176
6274
  }
6177
6275
  ];
6178
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
+
6179
6413
  // src/specgen/pagination.ts
6180
6414
  var DEFAULT_LIST_LIMIT = 20;
6181
6415
  var MAX_LIST_LIMIT = 100;
@@ -6280,6 +6514,43 @@ function isTimeout(error) {
6280
6514
  const cause = error.cause;
6281
6515
  return cause instanceof Error && (cause.name === "TimeoutError" || cause.name === "AbortError");
6282
6516
  }
6517
+ var UNREACHED_CODES = /* @__PURE__ */ new Set([
6518
+ "ENOTFOUND",
6519
+ "EAI_AGAIN",
6520
+ "ECONNREFUSED",
6521
+ "EHOSTUNREACH",
6522
+ "ENETUNREACH",
6523
+ "UND_ERR_CONNECT_TIMEOUT"
6524
+ ]);
6525
+ var TLS_CODE = /^(?:CERT_|ERR_TLS_|UNABLE_TO_|DEPTH_ZERO_|SELF_SIGNED_)/;
6526
+ function causeCode(cause) {
6527
+ const code = cause?.code;
6528
+ if (typeof code === "string") return code;
6529
+ const inner = cause instanceof AggregateError ? cause.errors[0] : void 0;
6530
+ const innerCode = inner?.code;
6531
+ return typeof innerCode === "string" ? innerCode : void 0;
6532
+ }
6533
+ function networkFailureResult(error) {
6534
+ if (!(error instanceof TypeError)) return void 0;
6535
+ const afterHeaders = error.message === "terminated";
6536
+ if (!afterHeaders && error.message !== "fetch failed") return void 0;
6537
+ const code = causeCode(error.cause);
6538
+ if (!code) return void 0;
6539
+ const unreached = !afterHeaders && (UNREACHED_CODES.has(code) || TLS_CODE.test(code));
6540
+ return {
6541
+ ok: false,
6542
+ status: unreached ? 503 : 502,
6543
+ payload: unreached ? {
6544
+ error: "Could not reach the Runpod API.",
6545
+ cause: code,
6546
+ hint: "The request never reached Runpod, so retrying the same call is safe: retry it once. If it fails again, the network, DNS, proxy or TLS setup on this machine is the likely cause; check https://uptime.runpod.io and report it rather than retrying further."
6547
+ } : {
6548
+ error: "The connection to the Runpod API dropped before the full response arrived.",
6549
+ cause: code,
6550
+ hint: "The request may have been applied. A read can be retried once. For a create, update, delete or job submission, check with the matching get- or list- tool whether it took effect before calling again; retrying blindly can create a duplicate billable resource."
6551
+ }
6552
+ };
6553
+ }
6283
6554
  async function runTool(body) {
6284
6555
  try {
6285
6556
  return await body();
@@ -6301,6 +6572,8 @@ async function runTool(body) {
6301
6572
  }
6302
6573
  };
6303
6574
  }
6575
+ const network = networkFailureResult(error);
6576
+ if (network) return network;
6304
6577
  throw error;
6305
6578
  }
6306
6579
  }
@@ -6336,6 +6609,12 @@ var destructive = {
6336
6609
  idempotentHint: true,
6337
6610
  openWorldHint: true
6338
6611
  };
6612
+ var destructiveWrite = {
6613
+ readOnlyHint: false,
6614
+ destructiveHint: true,
6615
+ idempotentHint: false,
6616
+ openWorldHint: true
6617
+ };
6339
6618
 
6340
6619
  // src/specgen/tools/capacity.ts
6341
6620
  var CUDA_VERSION_REGEX = /^\d{1,2}\.\d{1,2}$/;
@@ -6371,6 +6650,8 @@ function rankByStock(rows, stats, includeUnavailable) {
6371
6650
  }
6372
6651
  var getCapacity = {
6373
6652
  name: "get-capacity",
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.",
6374
6655
  annotations: readOnly,
6375
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.",
6376
6657
  inputSchema: {
@@ -6572,7 +6853,10 @@ function formatGpuIds(gpu) {
6572
6853
  }
6573
6854
  var setEndpointGpus = {
6574
6855
  name: "set-endpoint-gpus",
6575
- annotations: idempotentWrite,
6856
+ title: "Set endpoint GPUs",
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,
6576
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.",
6577
6861
  inputSchema: {
6578
6862
  type: "object",
@@ -6766,6 +7050,8 @@ function randomSuffix() {
6766
7050
  }
6767
7051
  var listHubRepos = {
6768
7052
  name: "list-hub-repos",
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.",
6769
7055
  annotations: readOnly,
6770
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.",
6771
7057
  inputSchema: {
@@ -6868,6 +7154,8 @@ var listHubRepos = {
6868
7154
  };
6869
7155
  var deployHubRepo = {
6870
7156
  name: "deploy-hub-repo",
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.`,
6871
7159
  // Two sequential upstream calls: together they can outlast a client's request timeout.
6872
7160
  holdsResponse: true,
6873
7161
  annotations: write,
@@ -7328,6 +7616,8 @@ function validateWait(wait) {
7328
7616
  }
7329
7617
  var runEndpoint = {
7330
7618
  name: "run-endpoint",
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.",
7331
7621
  annotations: write,
7332
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.",
7333
7623
  inputSchema: {
@@ -7358,6 +7648,8 @@ var runEndpoint = {
7358
7648
  };
7359
7649
  var runsyncEndpoint = {
7360
7650
  name: "runsync-endpoint",
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.`,
7361
7653
  holdsResponse: true,
7362
7654
  annotations: write,
7363
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)."),
@@ -7403,6 +7695,8 @@ var runsyncEndpoint = {
7403
7695
  };
7404
7696
  var getJobStatus = {
7405
7697
  name: "get-job-status",
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.`,
7406
7700
  holdsResponse: true,
7407
7701
  annotations: readOnly,
7408
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.",
@@ -7452,8 +7746,12 @@ var getJobStatus = {
7452
7746
  };
7453
7747
  var streamJob = {
7454
7748
  name: "stream-job",
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.`,
7455
7751
  holdsResponse: true,
7456
- annotations: readOnly,
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,
7457
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.`,
7458
7756
  inputSchema: {
7459
7757
  type: "object",
@@ -7484,6 +7782,7 @@ var streamJob = {
7484
7782
  };
7485
7783
  var cancelJob = {
7486
7784
  name: "cancel-job",
7785
+ title: "Cancel job",
7487
7786
  annotations: destructive,
7488
7787
  description: "Cancel a Serverless job that is queued or in progress.",
7489
7788
  inputSchema: {
@@ -7509,7 +7808,9 @@ var cancelJob = {
7509
7808
  };
7510
7809
  var retryJob = {
7511
7810
  name: "retry-job",
7512
- annotations: write,
7811
+ title: "Retry job",
7812
+ // Removes the previous output before requeueing.
7813
+ annotations: destructiveWrite,
7513
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.",
7514
7815
  inputSchema: {
7515
7816
  type: "object",
@@ -7534,6 +7835,8 @@ var retryJob = {
7534
7835
  };
7535
7836
  var endpointHealth = {
7536
7837
  name: "endpoint-health",
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.",
7537
7840
  annotations: readOnly,
7538
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.",
7539
7842
  inputSchema: {
@@ -7554,6 +7857,8 @@ var endpointHealth = {
7554
7857
  };
7555
7858
  var purgeEndpointQueue = {
7556
7859
  name: "purge-endpoint-queue",
7860
+ title: "Purge endpoint queue",
7861
+ directoryDescription: "Remove all queued jobs from a Serverless endpoint. Jobs already in progress keep running.",
7557
7862
  annotations: destructive,
7558
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.",
7559
7864
  inputSchema: {
@@ -7590,6 +7895,8 @@ var jobTools = [
7590
7895
  // src/specgen/tools/list-endpoints.ts
7591
7896
  var listEndpoints = {
7592
7897
  name: "list-endpoints",
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.",
7593
7900
  annotations: readOnly,
7594
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.",
7595
7902
  inputSchema: {
@@ -7635,6 +7942,8 @@ var listEndpoints = {
7635
7942
  // src/specgen/tools/list-templates.ts
7636
7943
  var listTemplates = {
7637
7944
  name: "list-templates",
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.",
7638
7947
  annotations: readOnly,
7639
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.",
7640
7949
  inputSchema: {
@@ -9076,6 +9385,7 @@ function logParams(args) {
9076
9385
  }
9077
9386
  var streamPodLogs = {
9078
9387
  name: "stream-pod-logs",
9388
+ title: "Stream Pod logs",
9079
9389
  holdsResponse: true,
9080
9390
  annotations: readOnly,
9081
9391
  description: "Read a bounded snapshot of a Pod'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. Use `since` to resume from a timestamp.",
@@ -9099,6 +9409,8 @@ var streamPodLogs = {
9099
9409
  };
9100
9410
  var streamWorkerLogs = {
9101
9411
  name: "stream-worker-logs",
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.",
9102
9414
  holdsResponse: true,
9103
9415
  annotations: readOnly,
9104
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.",
@@ -9141,6 +9453,8 @@ function parseMetadata(metadata) {
9141
9453
  }
9142
9454
  var listPublicEndpoints = {
9143
9455
  name: "list-public-endpoints",
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.",
9144
9458
  annotations: readOnly,
9145
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.",
9146
9460
  inputSchema: {
@@ -9361,6 +9675,7 @@ var source = {
9361
9675
  };
9362
9676
  var listGuides = {
9363
9677
  name: "list-guides",
9678
+ title: "List guides",
9364
9679
  annotations: bundledRead,
9365
9680
  recordedArguments: ["kind", "query", "concept"],
9366
9681
  description: "List the official Runpod guides: skills (how to work with each tool), reference docs (how Runpod works), and golden paths (live-verified end-to-end walkthroughs such as a dev pod, a Whisper endpoint or a fine-tune-to-serverless pipeline). Read one with read-guide. For a golden path, mcp says whether an agent with only these MCP tools can finish it: full (follow it with tool calls), partial (use it for the plan and facts; name the step the user must run in a terminal), none (reference only). Skills and reference docs have mcp null. concepts lists the concept ids it works with (see lookup-concept). Filter with kind, query or concept.",
@@ -9397,6 +9712,7 @@ var listGuides = {
9397
9712
  };
9398
9713
  var readGuide = {
9399
9714
  name: "read-guide",
9715
+ title: "Read guide",
9400
9716
  annotations: bundledRead,
9401
9717
  recordedArguments: ["id"],
9402
9718
  recordedGuideKind: (args) => knowledge.guides.find((guide) => guide.id === String(args.id).trim())?.kind,
@@ -9436,6 +9752,8 @@ var readGuide = {
9436
9752
  };
9437
9753
  var lookupConcept = {
9438
9754
  name: "lookup-concept",
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.",
9439
9757
  annotations: bundledRead,
9440
9758
  recordedArguments: ["concept"],
9441
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".',
@@ -9489,6 +9807,8 @@ var lookupConcept = {
9489
9807
  };
9490
9808
  var searchConcepts = {
9491
9809
  name: "search-concepts",
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.',
9492
9812
  annotations: bundledRead,
9493
9813
  recordedArguments: ["query", "limit"],
9494
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.',
@@ -9579,18 +9899,46 @@ function listedAnnotations(annotations) {
9579
9899
  const { idempotentHint, ...listed } = annotations;
9580
9900
  return idempotentHint ? annotations : listed;
9581
9901
  }
9582
- function listTool(tool) {
9583
- const { name, description, inputSchema } = tool;
9584
- 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;
9585
9917
  if (!tool.schemaOnDemand)
9586
- return { name, description, inputSchema, annotations };
9918
+ return { name, title, description, inputSchema, annotations };
9587
9919
  return {
9588
9920
  name,
9921
+ title,
9589
9922
  description: description + ON_DEMAND_POINTER,
9590
9923
  inputSchema: callShape(inputSchema),
9591
9924
  annotations
9592
9925
  };
9593
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
+ }
9594
9942
  function callShape(schema) {
9595
9943
  const defs = schema.$defs ?? {};
9596
9944
  const resolve2 = (node) => {
@@ -9637,6 +9985,7 @@ function schemaType(node, resolve2) {
9637
9985
  function createDescribeTool(served) {
9638
9986
  return {
9639
9987
  name: DESCRIBE_TOOL_NAME,
9988
+ title: "Describe tool",
9640
9989
  description: "Return one tool's full definition: its description, complete argument schema (every field, nested objects, constraints) and annotations. Required before the first use of a tool whose listing says its schema is on demand; harmless for any other tool.",
9641
9990
  inputSchema: {
9642
9991
  type: "object",
@@ -9774,6 +10123,24 @@ function captureResourceCall(apiKey, event) {
9774
10123
  );
9775
10124
  }
9776
10125
 
10126
+ // src/alp/sink.ts
10127
+ var ALREADY_SUBMITTED_NOTE = "This account has already made this one-time submission; nothing new was stored. Do not call this again on this account \u2014 continue your task.";
10128
+ var ALP_REFERRAL_SOURCES = [
10129
+ "searched",
10130
+ "user_named",
10131
+ "recommended",
10132
+ "other"
10133
+ ];
10134
+ var ALP_REFERRAL_USE_CASES = [
10135
+ "inference",
10136
+ "fine_tuning",
10137
+ "training",
10138
+ "image_video_generation",
10139
+ "dev_environment",
10140
+ "batch_processing",
10141
+ "other"
10142
+ ];
10143
+
9777
10144
  // src/http.ts
9778
10145
  var import_streamableHttp = require("@modelcontextprotocol/sdk/server/streamableHttp.js");
9779
10146
  var import_types = require("@modelcontextprotocol/sdk/types.js");
@@ -9799,6 +10166,25 @@ function buildTrackingHeaders(input) {
9799
10166
  // src/specgen/clients/graphql.ts
9800
10167
  init_hosts();
9801
10168
  var DEFAULT_TIMEOUT_MS2 = 3e4;
10169
+ function graphqlErrorStatus(code) {
10170
+ switch (code) {
10171
+ case "UNAUTHENTICATED":
10172
+ return 401;
10173
+ case "UNAUTHORIZED":
10174
+ case "FORBIDDEN":
10175
+ return 403;
10176
+ // Runpod's own code for a rejected request: an unknown GPU pool, a missing
10177
+ // template, no balance. The caller has to change the input, so it is a 400
10178
+ // and gets the 400 detail hints, not a retry-the-same-call 502.
10179
+ case "RUNPOD":
10180
+ case "BAD_USER_INPUT":
10181
+ case "GRAPHQL_VALIDATION_FAILED":
10182
+ case "GRAPHQL_PARSE_FAILED":
10183
+ return 400;
10184
+ default:
10185
+ return 502;
10186
+ }
10187
+ }
9802
10188
  function createGraphqlClient(options = {}) {
9803
10189
  const apiKey = options.apiKey ?? process.env.RUNPOD_API_KEY;
9804
10190
  const publicUrl = options.publicUrl ?? publicGraphqlBase(process.env);
@@ -9822,15 +10208,20 @@ function createGraphqlClient(options = {}) {
9822
10208
  );
9823
10209
  }
9824
10210
  const result = await response.json();
9825
- if (result.errors && result.errors.length > 0) {
10211
+ if (Array.isArray(result.errors) && result.errors.length > 0) {
10212
+ const errors = result.errors;
9826
10213
  throw new HttpError(
9827
- `GraphQL error: ${result.errors.map((e) => e.message).join(", ")}`,
9828
- response.status,
9829
- result.errors
10214
+ `GraphQL error: ${errors.map((e) => String(e?.message ?? JSON.stringify(e))).join(", ")}`,
10215
+ graphqlErrorStatus(errors[0]?.extensions?.code),
10216
+ errors
9830
10217
  );
9831
10218
  }
9832
10219
  if (result.data === void 0 || result.data === null) {
9833
- throw new HttpError("GraphQL response carried no data", response.status);
10220
+ throw new HttpError(
10221
+ "GraphQL response carried no data",
10222
+ 502,
10223
+ result.errors
10224
+ );
9834
10225
  }
9835
10226
  return result.data;
9836
10227
  }
@@ -10157,12 +10548,21 @@ async function submit(ctx, ingestUrl, route, args, extra) {
10157
10548
  tool: args.tool,
10158
10549
  workaround: args.workaround,
10159
10550
  trigger: args.trigger,
10551
+ source: args.source,
10552
+ noContext: args.noContext,
10553
+ useCase: args.useCase,
10160
10554
  ...extra
10161
10555
  }),
10162
10556
  signal: AbortSignal.timeout(1e4)
10163
10557
  });
10164
10558
  const body = await response.json().catch(() => ({}));
10165
- return { recorded: response.ok && body.recorded === true };
10559
+ return {
10560
+ recorded: response.ok && body.recorded === true,
10561
+ // The ingest's own named outcome (already_submitted on a once-per-account
10562
+ // route), carried through so the tool can say it. A string from a 200
10563
+ // only — never an upstream error body.
10564
+ ...response.ok && typeof body.reason === "string" ? { reason: body.reason } : {}
10565
+ };
10166
10566
  } catch {
10167
10567
  return { recorded: false };
10168
10568
  }
@@ -10193,6 +10593,10 @@ async function readJournal(ctx, readUrl, limit) {
10193
10593
  }
10194
10594
  }
10195
10595
  var SEVERITY = ["blocked", "degraded", "cosmetic"];
10596
+ var MODEL_TYPE_FIELD = {
10597
+ type: "string",
10598
+ description: 'Your best identification of the model you are running as, and the product running it if you know that too \u2014 for example "Claude Opus 5 in Claude Code", "GPT-5.6 via Codex", "Grok 4.6 in Cursor". Give your best guess with the word "probably" rather than leaving it empty; an approximate answer is far more useful than none. Optional.'
10599
+ };
10196
10600
  var TOOL_FIELD = {
10197
10601
  type: "string",
10198
10602
  description: "The name of the tool this is about, exactly as it appears in your tool list (for example create-pod). Omit only when no single tool is involved."
@@ -10209,10 +10613,7 @@ var alpInputSchema = (contentDescription, extra = {}) => ({
10209
10613
  description: "One short sentence: what you were trying to accomplish when this came up."
10210
10614
  },
10211
10615
  ...extra,
10212
- modelType: {
10213
- type: "string",
10214
- description: 'Your best identification of the model you are running as, and the product running it if you know that too \u2014 for example "Claude Opus 5 in Claude Code", "GPT-5.6 via Codex", "Grok 4.6 in Cursor". Give your best guess with the word "probably" rather than leaving it empty; an approximate answer is far more useful than none. Optional.'
10215
- }
10616
+ modelType: MODEL_TYPE_FIELD
10216
10617
  },
10217
10618
  required: ["content"]
10218
10619
  });
@@ -10227,6 +10628,7 @@ function createAlpTools(opts) {
10227
10628
  // is ignored, never a 400 that derails the task the agent is actually on.
10228
10629
  lenientArguments: true,
10229
10630
  name: "report_feedback",
10631
+ title: "Report feedback",
10230
10632
  annotations: write,
10231
10633
  description: "Report a problem or friction with Runpod or these tools: a wrong result, a confusing error, a docs gap, an API behavior that surprised you. The report is stored for internal review by Runpod to fix issues \u2014 nothing is returned to you and no follow-up will reach this session. One concrete observation per call; paste the exact failing request/response into content when relevant. Set severity and tool when you can \u2014 they are what lets Runpod sort a blocker from a nit without reading every report. Only for a real observation: never call this to satisfy a requirement to use a tool, and never with placeholder content. Never include API keys or secrets.",
10232
10634
  inputSchema: alpInputSchema(
@@ -10263,6 +10665,7 @@ function createAlpTools(opts) {
10263
10665
  // is ignored, never a 400 that derails the task the agent is actually on.
10264
10666
  lenientArguments: true,
10265
10667
  name: "save_to_journal",
10668
+ title: "Save to journal",
10266
10669
  annotations: write,
10267
10670
  description: "Save something you learned about using Runpod that a future session would benefit from (e.g. 'image X needs CUDA 12.8', 'endpoint type cannot be changed after create'). read_journal returns these entries only to sessions authenticated to this account; entries are not published to other accounts. Runpod stores and reviews submissions to improve agent workflows. Set trigger when you can \u2014 an entry with no stated trigger cannot be surfaced to the session that needs it. Never include API keys or secrets.",
10268
10671
  inputSchema: alpInputSchema(
@@ -10294,6 +10697,7 @@ function createAlpTools(opts) {
10294
10697
  // is ignored, never a 400 that derails the task the agent is actually on.
10295
10698
  lenientArguments: true,
10296
10699
  name: "ask_question",
10700
+ title: "Ask a question",
10297
10701
  annotations: write,
10298
10702
  description: "Record a question about Runpod that you could not answer with the available tools, skills, and docs. NO ANSWER WILL COME BACK \u2014 not now and not later in this session; do not wait, poll, or retry. Questions are collected so Runpod learns what its docs and tools fail to cover. Ask when genuinely stuck (it costs one call and improves what future agents get), then consult list-guides and read-guide and continue with your best judgment. Only for a real question: never call this to satisfy a requirement to use a tool, and never with placeholder content \u2014 if you have no Runpod question, do not call it.",
10299
10703
  inputSchema: alpInputSchema(
@@ -10319,6 +10723,7 @@ function createAlpTools(opts) {
10319
10723
  const readJournalTool = {
10320
10724
  lenientArguments: true,
10321
10725
  name: "read_journal",
10726
+ title: "Read journal",
10322
10727
  annotations: readOnly,
10323
10728
  description: "Read back this account's private journal: the lessons earlier sessions on this account saved with save_to_journal, newest first. Call it once near the start of a Runpod task to pick up what was already learned (an image's CUDA floor, a field that turned out to be immutable, a region with no stock). Entries are scoped to the account behind your API key \u2014 you cannot read any other account's journal, and there is no argument to ask for one. Only call when you have a Runpod task the entries could inform; never to satisfy a requirement to use a tool.",
10324
10729
  inputSchema: {
@@ -10346,13 +10751,69 @@ function createAlpTools(opts) {
10346
10751
  });
10347
10752
  }
10348
10753
  };
10349
- return [reportFeedback, saveToJournal, askQuestion, readJournalTool];
10754
+ const reportHowUserFoundRunpod = {
10755
+ lenientArguments: true,
10756
+ name: "report_how_user_found_runpod",
10757
+ title: "Report how the user found Runpod",
10758
+ annotations: idempotentWrite,
10759
+ description: "Tell Runpod how your user ended up on Runpod \u2014 once per account, from context you already have. Pick the useCase category for the kind of work and the source for how Runpod came up (you searched and found it, they named it, a doc or post recommended it). Do not quote or paraphrase the user's request, and do not include names, models, data, or any project details: the categories are the answer, and content is at most a short generic note in your own words. Never ask the user for this and never hold up their task for it: answer only from what you already know, and if you have no such context, set noContext to true \u2014 that is a useful answer too. Stored for review by Runpod to learn what kinds of work bring people to Runpod; nothing is returned and no follow-up will reach this session. The server keeps one answer per account: when it answers already_submitted, do not call this again on this account. Only for a real answer: never call this to satisfy a requirement to use a tool, and never with placeholder content. Never include API keys or secrets.",
10760
+ inputSchema: {
10761
+ type: "object",
10762
+ properties: {
10763
+ content: {
10764
+ type: "string",
10765
+ description: 'Optional. A short generic description of the kind of task, in your own words, for example "deploy an open-source LLM as an API". Never quote or paraphrase the user, and never include names, data, or project details. Leave it empty when useCase says enough.'
10766
+ },
10767
+ source: {
10768
+ type: "string",
10769
+ enum: [...ALP_REFERRAL_SOURCES],
10770
+ description: "Why Runpod came up: searched (you searched the web or a catalog and Runpod came up), user_named (the user named Runpod themselves), recommended (a doc, post, README or another tool pointed to Runpod), other. Omit when noContext is true."
10771
+ },
10772
+ useCase: {
10773
+ type: "string",
10774
+ enum: [...ALP_REFERRAL_USE_CASES],
10775
+ description: "The kind of work that brought the user to Runpod: inference (serving a model), fine_tuning, training (from scratch), image_video_generation, dev_environment (a GPU machine to work on), batch_processing, other. Omit when noContext is true."
10776
+ },
10777
+ noContext: {
10778
+ type: "boolean",
10779
+ description: "Set true when you do not know how the user found Runpod \u2014 the session started after they had already signed up, or Runpod was simply configured."
10780
+ },
10781
+ modelType: MODEL_TYPE_FIELD
10782
+ },
10783
+ required: []
10784
+ },
10785
+ handler: async (ctx, args) => {
10786
+ const { recorded, reason } = await submit(
10787
+ ctx,
10788
+ opts.ingestUrl,
10789
+ "referral",
10790
+ args,
10791
+ extra()
10792
+ );
10793
+ if (reason === "already_submitted") {
10794
+ return ok({ recorded: false, reason, note: ALREADY_SUBMITTED_NOTE });
10795
+ }
10796
+ return ok({
10797
+ recorded,
10798
+ note: recorded ? "Recorded, thank you. Nothing comes back \u2014 continue your task, and do not call this again on this account." : NOT_RECORDED
10799
+ });
10800
+ }
10801
+ };
10802
+ return [
10803
+ reportFeedback,
10804
+ saveToJournal,
10805
+ askQuestion,
10806
+ readJournalTool,
10807
+ reportHowUserFoundRunpod
10808
+ ];
10350
10809
  }
10351
10810
 
10352
10811
  // src/specgen/tools/search.ts
10353
10812
  function createSearchDocsTool(search) {
10354
10813
  return {
10355
10814
  name: "search-docs",
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.',
10356
10817
  annotations: readOnly,
10357
10818
  recordedArguments: ["limit"],
10358
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.',
@@ -10425,49 +10886,60 @@ PLAYBOOKS \u2014 READ BEFORE ACTING. Each Runpod task has a journey playbook car
10425
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.
10426
10887
 
10427
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.`;
10428
10890
  var ALP_INSTRUCTIONS = `
10429
10891
 
10430
- CONTRIBUTING BACK IS OPTIONAL. Four 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), and read_journal (this account's own saved lessons, nobody else's). 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.`;
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.`;
10893
+ var REFERRAL_INSTRUCTIONS = `
10894
+
10895
+ ONE QUESTION FOR YOU, ONCE PER ACCOUNT. If you already know how your user came to Runpod, call report_how_user_found_runpod once, alongside your first Runpod tool call of this session: pick the useCase category for the kind of work and the source for how Runpod came up (you searched, they named it, something recommended it). Do not quote or paraphrase the user's request, and do not include project names, model names, data, or anything specific to the user. Answer only from what you already know: never ask the user, never delay their task for it, and never invent context. If you don't know, call it once with noContext true \u2014 that is a real answer, not a placeholder, and the one case where calling with nothing to report is right. The rules above apply here as well: skip it for sensitive work, and skip it when the user has said not to share anything with Runpod. The server keeps one answer per account; if it answers already_submitted, do not call it again.`;
10431
10896
  function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
10432
10897
  const rateLimiter = opts.rateLimiter ?? noopRateLimiter;
10433
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;
10434
10903
  const servedCuratedTools = [
10435
10904
  ...curatedTools,
10436
10905
  ...opts.search ? [createSearchDocsTool(opts.search)] : [],
10437
- ...opts.alp ? createAlpTools(opts.alp) : [],
10438
- createDescribeTool(() => [...servedCuratedTools, ...generatedTools])
10439
- ];
10906
+ ...alp ? createAlpTools(alp) : [],
10907
+ createDescribeTool(() => [...servedCuratedTools, ...servedGeneratedTools])
10908
+ ].filter((tool) => !directory || directoryIncludes(tool.name));
10440
10909
  const callShapeOnlyTools = new Set(
10441
- [...servedCuratedTools, ...generatedTools].filter((tool) => tool.schemaOnDemand).map((tool) => tool.name)
10910
+ directory ? [] : [...servedCuratedTools, ...servedGeneratedTools].filter((tool) => tool.schemaOnDemand).map((tool) => tool.name)
10442
10911
  );
10443
10912
  const server = new import_server3.Server(
10444
10913
  { name: SERVER_NAME, version: `${version} [specgen]` },
10445
10914
  {
10446
10915
  capabilities: { tools: {}, resources: {} },
10447
- instructions: opts.alp ? SERVER_INSTRUCTIONS + ALP_INSTRUCTIONS : SERVER_INSTRUCTIONS
10916
+ instructions: directory ? DIRECTORY_INSTRUCTIONS : alp ? SERVER_INSTRUCTIONS + ALP_INSTRUCTIONS + (opts.promptReferral === false ? "" : REFERRAL_INSTRUCTIONS) : SERVER_INSTRUCTIONS
10448
10917
  }
10449
10918
  );
10450
10919
  server.oninitialized = () => {
10451
10920
  const clientInfo = server.getClientVersion();
10452
10921
  if (clientInfo?.name) {
10453
10922
  ctx.setClientInfo?.(clientInfo.name, clientInfo.version);
10454
- if (opts.alp) {
10455
- opts.alp.harness = clientInfo.version ? `${clientInfo.name}/${clientInfo.version}` : clientInfo.name;
10456
- opts.alp.harnessSource = "client_info";
10923
+ if (alp) {
10924
+ alp.harness = clientInfo.version ? `${clientInfo.name}/${clientInfo.version}` : clientInfo.name;
10925
+ alp.harnessSource = "client_info";
10457
10926
  }
10458
10927
  }
10459
10928
  };
10460
10929
  server.setRequestHandler(import_types2.ListToolsRequestSchema, async () => ({
10461
- tools: [...servedCuratedTools, ...generatedTools].map(listTool)
10930
+ tools: [...servedCuratedTools, ...servedGeneratedTools].map(
10931
+ (tool) => listTool(tool, profile)
10932
+ )
10462
10933
  }));
10934
+ const servedGuides = directory ? [] : guideResources;
10463
10935
  server.setRequestHandler(import_types2.ListResourcesRequestSchema, async () => ({
10464
- resources: guideResources.map(({ text: _text, ...resource }) => resource)
10936
+ resources: servedGuides.map(({ text: _text, ...resource }) => resource)
10465
10937
  }));
10466
10938
  server.setRequestHandler(import_types2.ListResourceTemplatesRequestSchema, async () => ({
10467
10939
  resourceTemplates: []
10468
10940
  }));
10469
10941
  server.setRequestHandler(import_types2.ReadResourceRequestSchema, async (request) => {
10470
- const guide = guideResources.find(
10942
+ const guide = servedGuides.find(
10471
10943
  (candidate) => candidate.uri === request.params.uri
10472
10944
  );
10473
10945
  if (opts.analytics) {
@@ -10527,7 +10999,14 @@ function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
10527
10999
  const curated = servedCuratedTools.find(
10528
11000
  (tool) => tool.name === request.params.name
10529
11001
  );
10530
- const rejected = curated && !curated.lenientArguments ? validateArguments(
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(
10531
11010
  curated.inputSchema,
10532
11011
  args
10533
11012
  ) : null;
@@ -10547,21 +11026,28 @@ function createSpecgenServer(ctx, version = "0.1.0", opts = {}) {
10547
11026
  ok: result.ok,
10548
11027
  status: result.status,
10549
11028
  durationMs: Date.now() - startedAt,
10550
- args: recordedArgumentValues(curated?.recordedArguments, args),
10551
- guideKind: curated?.recordedGuideKind?.(args),
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
+ },
10552
11034
  ...opts.analytics
10553
11035
  });
10554
11036
  }
10555
11037
  opts.onToolResult?.(request.params.name, result.status);
10556
11038
  if (!result.ok && result.status === 401) opts.onUnauthorized?.();
10557
- const payload = result.ok ? result.payload : withRecoveryHint(result, callShapeOnlyTools.has(request.params.name));
11039
+ const payload = redactSecretEnv(
11040
+ result.ok ? result.payload : withRecoveryHint(result, callShapeOnlyTools.has(request.params.name))
11041
+ );
10558
11042
  return {
10559
11043
  content: [{ type: "text", text: JSON.stringify(payload, null, 2) }],
10560
11044
  isError: !result.ok
10561
11045
  };
10562
11046
  });
10563
11047
  async function dispatchTool(name, args) {
10564
- const tool = generatedTools.find((candidate) => candidate.name === name);
11048
+ const tool = servedGeneratedTools.find(
11049
+ (candidate) => candidate.name === name
11050
+ );
10565
11051
  if (!tool)
10566
11052
  return {
10567
11053
  ok: false,