harness-mcp-v2 3.0.5 → 3.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +75 -20
- package/build/client/types.d.ts +5 -0
- package/build/client/types.d.ts.map +1 -1
- package/build/data/schemas/v0/pipeline.d.ts.map +1 -1
- package/build/data/schemas/v0/pipeline.js +658 -12
- package/build/data/schemas/v0/pipeline.js.map +1 -1
- package/build/data/schemas/v0/template.d.ts.map +1 -1
- package/build/data/schemas/v0/template.js +1264 -367
- package/build/data/schemas/v0/template.js.map +1 -1
- package/build/data/schemas/v1/pipeline.d.ts.map +1 -1
- package/build/data/schemas/v1/pipeline.js +193 -117
- package/build/data/schemas/v1/pipeline.js.map +1 -1
- package/build/data/schemas/v1/template.d.ts.map +1 -1
- package/build/data/schemas/v1/template.js +193 -117
- package/build/data/schemas/v1/template.js.map +1 -1
- package/build/index.js +1 -6
- package/build/index.js.map +1 -1
- package/build/prompts/exempt-opa-failed-issues.d.ts +20 -0
- package/build/prompts/exempt-opa-failed-issues.d.ts.map +1 -0
- package/build/prompts/exempt-opa-failed-issues.js +298 -0
- package/build/prompts/exempt-opa-failed-issues.js.map +1 -0
- package/build/prompts/index.d.ts.map +1 -1
- package/build/prompts/index.js +2 -0
- package/build/prompts/index.js.map +1 -1
- package/build/registry/index.d.ts.map +1 -1
- package/build/registry/index.js +1 -0
- package/build/registry/index.js.map +1 -1
- package/build/registry/scope-utils.d.ts +9 -0
- package/build/registry/scope-utils.d.ts.map +1 -0
- package/build/registry/scope-utils.js +21 -0
- package/build/registry/scope-utils.js.map +1 -0
- package/build/registry/toolsets/ccm.d.ts.map +1 -1
- package/build/registry/toolsets/ccm.js +32 -0
- package/build/registry/toolsets/ccm.js.map +1 -1
- package/build/registry/toolsets/governance.d.ts.map +1 -1
- package/build/registry/toolsets/governance.js +26 -8
- package/build/registry/toolsets/governance.js.map +1 -1
- package/build/registry/toolsets/iacm.d.ts.map +1 -1
- package/build/registry/toolsets/iacm.js +37 -35
- package/build/registry/toolsets/iacm.js.map +1 -1
- package/build/registry/toolsets/sto.d.ts.map +1 -1
- package/build/registry/toolsets/sto.js +300 -82
- package/build/registry/toolsets/sto.js.map +1 -1
- package/build/registry/toolsets/templates.d.ts.map +1 -1
- package/build/registry/toolsets/templates.js +314 -81
- package/build/registry/toolsets/templates.js.map +1 -1
- package/build/tools/harness-create.d.ts.map +1 -1
- package/build/tools/harness-create.js +2 -1
- package/build/tools/harness-create.js.map +1 -1
- package/build/tools/harness-delete.d.ts.map +1 -1
- package/build/tools/harness-delete.js +15 -3
- package/build/tools/harness-delete.js.map +1 -1
- package/build/tools/harness-list.d.ts.map +1 -1
- package/build/tools/harness-list.js +4 -2
- package/build/tools/harness-list.js.map +1 -1
- package/build/tools/harness-update.d.ts.map +1 -1
- package/build/tools/harness-update.js +2 -1
- package/build/tools/harness-update.js.map +1 -1
- package/build/tools/input-schemas.d.ts +6 -0
- package/build/tools/input-schemas.d.ts.map +1 -1
- package/build/tools/input-schemas.js +5 -0
- package/build/tools/input-schemas.js.map +1 -1
- package/build/tools/output-schemas.d.ts +4 -2
- package/build/tools/output-schemas.d.ts.map +1 -1
- package/build/tools/output-schemas.js +11 -5
- package/build/tools/output-schemas.js.map +1 -1
- package/build/utils/http-auth.d.ts +1 -1
- package/build/utils/http-auth.d.ts.map +1 -1
- package/build/utils/http-auth.js +17 -8
- package/build/utils/http-auth.js.map +1 -1
- package/build/utils/log-resolver.d.ts.map +1 -1
- package/build/utils/log-resolver.js +37 -1
- package/build/utils/log-resolver.js.map +1 -1
- package/build/utils/poll-execution.d.ts +2 -2
- package/build/utils/poll-execution.d.ts.map +1 -1
- package/build/utils/poll-execution.js +3 -5
- package/build/utils/poll-execution.js.map +1 -1
- package/build/utils/response-formatter.d.ts +11 -0
- package/build/utils/response-formatter.d.ts.map +1 -1
- package/build/utils/response-formatter.js +39 -0
- package/build/utils/response-formatter.js.map +1 -1
- package/build/utils/url-parser.d.ts +2 -0
- package/build/utils/url-parser.d.ts.map +1 -1
- package/build/utils/url-parser.js +12 -1
- package/build/utils/url-parser.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
## Harness MCP Server 2.0
|
|
2
2
|
|
|
3
|
-
An MCP (Model Context Protocol) server that gives AI agents full access to the Harness.io platform through 11 consolidated tools and
|
|
3
|
+
An MCP (Model Context Protocol) server that gives AI agents full access to the Harness.io platform through 11 consolidated tools and 190 resource types.
|
|
4
4
|
|
|
5
5
|
## Why Use This MCP Server
|
|
6
6
|
|
|
@@ -8,10 +8,10 @@ Most MCP servers map one tool per API endpoint. For a platform as broad as Harne
|
|
|
8
8
|
|
|
9
9
|
This server is built differently:
|
|
10
10
|
|
|
11
|
-
- **11 tools,
|
|
12
|
-
- **Full platform coverage.** 32 toolsets spanning CI/CD, GitOps, Feature Flags, Cloud Cost Management, Security Testing, Chaos Engineering, Database DevOps, Internal Developer Portal, Software Supply Chain, Governance, Service Overrides, Visualizations, and more.
|
|
11
|
+
- **11 tools, 190 resource types.** A registry-based dispatch system routes `harness_list`, `harness_get`, `harness_create`, etc. to any Harness resource — pipelines, services, environments, orgs, projects, feature flags, cost data, and more. The LLM picks from 11 tools instead of hundreds.
|
|
12
|
+
- **Full platform coverage.** 32 default toolsets spanning CI/CD, GitOps, Feature Flags, Cloud Cost Management, Security Testing, Chaos Engineering, Database DevOps, Internal Developer Portal, Software Supply Chain, Governance, Service Overrides, Visualizations, and more. Opt-in IaCM coverage is available when you need Terraform workspace and module data.
|
|
13
13
|
- **Multi-project workflows out of the box.** Agents discover organizations and projects dynamically — no hardcoded env vars needed. Ask "show failed executions across all projects" and the agent can navigate the full account hierarchy.
|
|
14
|
-
- **
|
|
14
|
+
- **32 prompt templates.** Pre-built prompts for common workflows: build & deploy apps end-to-end, debug failed pipelines, review DORA metrics, triage vulnerabilities, optimize cloud costs, audit access control, plan feature flag rollouts, review pull requests, approve pending pipelines, and more.
|
|
15
15
|
- **Works everywhere.** Stdio transport for local clients (Claude Desktop, Cursor, Windsurf), HTTP transport for remote/shared deployments, Docker and Kubernetes ready.
|
|
16
16
|
- **Zero-config start.** Just provide a Harness API key. Account ID is auto-extracted from PAT tokens, org/project defaults are optional, and toolset filtering lets you expose only what you need.
|
|
17
17
|
- **Extensible by design.** Adding a new Harness resource means adding a declarative data file — no new tool registration, no schema changes, no prompt updates.
|
|
@@ -528,7 +528,7 @@ The server automatically loads environment variables from a `.env` file in the p
|
|
|
528
528
|
| `HARNESS_MAX_BODY_SIZE_MB` | No | `10` | Max HTTP request body size in MB for `http` transport |
|
|
529
529
|
| `HARNESS_RATE_LIMIT_RPS` | No | `10` | Client-side request throttle (requests per second) to Harness APIs |
|
|
530
530
|
| `LOG_LEVEL` | No | `info` | Log verbosity: `debug`, `info`, `warn`, `error` |
|
|
531
|
-
| `HARNESS_TOOLSETS` | No | *(
|
|
531
|
+
| `HARNESS_TOOLSETS` | No | *(defaults)* | Comma-separated toolset list. Empty loads default toolsets. Supports `+name` to explicitly include opt-in toolsets and `-name` to remove defaults (see [Toolset Filtering](#toolset-filtering)) |
|
|
532
532
|
| `HARNESS_READ_ONLY` | No | `false` | Block all mutating operations (create, update, delete, execute). Only list and get are allowed. Useful for shared/demo environments |
|
|
533
533
|
| `HARNESS_AUTO_APPROVE_RISK` | No | `none` | Risk-based auto-approve threshold for autonomous workflows. Operations at or below this risk proceed without confirmation. Values: `none`, `low_write`, `medium_write`, `high_write`, `all`. See [Elicitation](#elicitation) |
|
|
534
534
|
| `HARNESS_SKIP_ELICITATION` | No | `false` | **Deprecated** — use `HARNESS_AUTO_APPROVE_RISK=all` instead. Kept for backward compatibility |
|
|
@@ -538,6 +538,12 @@ The server automatically loads environment variables from a `.env` file in the p
|
|
|
538
538
|
| `HARNESS_MCP_AUTH_TOKEN` | No | -- | Bearer token required on `/mcp` HTTP routes when set. Required by default when HTTP transport binds to a non-loopback host |
|
|
539
539
|
| `HARNESS_MCP_ALLOW_UNAUTHENTICATED_HTTP` | No | `false` | Explicitly allow unauthenticated HTTP transport on non-loopback binds. Use only behind another authenticated control |
|
|
540
540
|
| `HARNESS_MCP_LOG_FILE` | No | `~/.claude/harness-mcp.log` | File used for stdio disconnect/crash diagnostics when stderr may no longer be available |
|
|
541
|
+
| `HARNESS_AUDIT_FILE` | No | -- | Append audit events to a newline-delimited JSON file in addition to stderr |
|
|
542
|
+
| `HARNESS_AUDIT_WEBHOOK_URL` | No | -- | HTTPS endpoint that receives batched audit events. HTTP URLs require `HARNESS_ALLOW_HTTP=true` for local development |
|
|
543
|
+
| `HARNESS_AUDIT_WEBHOOK_TOKEN` | No | -- | Optional bearer token sent to the audit webhook |
|
|
544
|
+
| `HARNESS_AUDIT_WEBHOOK_BATCH_SIZE` | No | `10` | Number of audit events to batch before webhook flush |
|
|
545
|
+
| `HARNESS_AUDIT_WEBHOOK_FLUSH_MS` | No | `5000` | Max time to hold audit events before webhook flush |
|
|
546
|
+
| `OTEL_EXPORTER_OTLP_ENDPOINT` | No | -- | Enables OpenTelemetry audit spans when the optional OpenTelemetry packages are installed |
|
|
541
547
|
|
|
542
548
|
|
|
543
549
|
### HTTPS Enforcement
|
|
@@ -550,7 +556,13 @@ HARNESS_BASE_URL must use HTTPS (got "http://..."). If you need HTTP for local d
|
|
|
550
556
|
|
|
551
557
|
### Audit Logging
|
|
552
558
|
|
|
553
|
-
All write operations (`harness_create`, `harness_update`, `harness_delete`, `harness_execute`) emit structured audit
|
|
559
|
+
All write operations (`harness_create`, `harness_update`, `harness_delete`, `harness_execute`) emit structured audit events. The stderr sink is always active; additional sinks are enabled by configuration:
|
|
560
|
+
|
|
561
|
+
- `HARNESS_AUDIT_FILE` appends newline-delimited JSON events for local collection.
|
|
562
|
+
- `HARNESS_AUDIT_WEBHOOK_URL` posts batched events to an HTTPS webhook, optionally with `HARNESS_AUDIT_WEBHOOK_TOKEN`.
|
|
563
|
+
- `OTEL_EXPORTER_OTLP_ENDPOINT` enables audit spans when the optional OpenTelemetry packages are installed.
|
|
564
|
+
|
|
565
|
+
Each event includes the tool name, resource type, operation, identifiers, timestamp, and confirmation method. Audit sinks are best-effort telemetry; a webhook delivery issue is logged and does not retry or replay the mutating Harness operation.
|
|
554
566
|
|
|
555
567
|
## Tools Reference
|
|
556
568
|
|
|
@@ -558,6 +570,16 @@ The server exposes 11 MCP tools. Most API tools accept `org_id` and `project_id`
|
|
|
558
570
|
|
|
559
571
|
**URL support:** Most API-facing tools accept a `url` parameter — paste a Harness UI URL and the server auto-extracts org, project, resource type, resource ID, pipeline ID, and execution ID. `harness_describe` does not accept `url`.
|
|
560
572
|
|
|
573
|
+
**Scope support:** Resource types with account/org/project variants expose `supportedScopes` in `harness_describe`. Pass `resource_scope` when you need a specific level:
|
|
574
|
+
|
|
575
|
+
- `resource_scope: "account"` sends only `accountIdentifier`.
|
|
576
|
+
- `resource_scope: "org"` sends `accountIdentifier` and `orgIdentifier`.
|
|
577
|
+
- `resource_scope: "project"` sends account, org, and project identifiers.
|
|
578
|
+
|
|
579
|
+
Current multi-scope resources include `connector`, `service`, `environment`, `infrastructure`, `secret`, and `template`. If `resource_scope` is omitted, the registry uses the resource's default scope and configured defaults, except resources marked as optional scope may omit org/project unless explicitly passed. Harness URLs can also set the scope automatically when the path contains account-level or project-level context.
|
|
580
|
+
|
|
581
|
+
**Structured output:** Every tool declares an MCP `outputSchema`. `harness_list` normalizes list-like Harness responses into object-shaped structured content so strict clients can validate it: top-level arrays become `{ "items": [...], "total": <count>, "page": <page> }`, and common wrapper keys such as `content`, `data`, `body`, `objects`, or `features` are hoisted to `items` when needed. The text response still contains the compact JSON payload returned to all clients.
|
|
582
|
+
|
|
561
583
|
|
|
562
584
|
| Tool | Description |
|
|
563
585
|
| ------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
@@ -613,7 +635,8 @@ The server exposes 11 MCP tools. Most API tools accept `org_id` and `project_id`
|
|
|
613
635
|
"resource_type": "pipeline",
|
|
614
636
|
"action": "run",
|
|
615
637
|
"resource_id": "my-pipeline",
|
|
616
|
-
"inputs": { "tag": "v1.2.3" }
|
|
638
|
+
"inputs": { "tag": "v1.2.3" },
|
|
639
|
+
"wait": true
|
|
617
640
|
}
|
|
618
641
|
```
|
|
619
642
|
|
|
@@ -766,7 +789,8 @@ Use this sequence to reduce execution-time input errors:
|
|
|
766
789
|
"action": "run",
|
|
767
790
|
"resource_id": "deploy_app",
|
|
768
791
|
"params": { "pipeline_branch": "feature/new-stage" },
|
|
769
|
-
"inputs": { "branch": "main" }
|
|
792
|
+
"inputs": { "branch": "main" },
|
|
793
|
+
"wait": true
|
|
770
794
|
}
|
|
771
795
|
```
|
|
772
796
|
4. **Optional: combine both**
|
|
@@ -774,6 +798,31 @@ Use this sequence to reduce execution-time input errors:
|
|
|
774
798
|
|
|
775
799
|
If required fields are unresolved, the tool returns a pre-flight error with expected keys and suggested input sets. You can inspect available shorthand mappings with `harness_describe(resource_type="pipeline")` (`executeActions.run.inputShorthands`).
|
|
776
800
|
|
|
801
|
+
### Pipeline Execute Wait Mode
|
|
802
|
+
|
|
803
|
+
For `pipeline.run`, `pipeline.retry`, and `pipeline_v1.run`, pass `wait: true` to let the server poll until the execution reaches a terminal status. This keeps a pipeline launch and status check in one tool call instead of asking the client or LLM to run a polling loop.
|
|
804
|
+
|
|
805
|
+
```json
|
|
806
|
+
{
|
|
807
|
+
"resource_type": "pipeline",
|
|
808
|
+
"action": "run",
|
|
809
|
+
"resource_id": "deploy_app",
|
|
810
|
+
"inputs": { "branch": "main" },
|
|
811
|
+
"wait": true,
|
|
812
|
+
"wait_timeout_seconds": 900,
|
|
813
|
+
"wait_poll_interval_seconds": 5
|
|
814
|
+
}
|
|
815
|
+
```
|
|
816
|
+
|
|
817
|
+
Wait mode behavior:
|
|
818
|
+
|
|
819
|
+
- Default timeout is 600 seconds; allowed range is 10 seconds to 7200 seconds.
|
|
820
|
+
- Initial poll interval defaults to 3 seconds, backs off by 1.5x, and caps at 30 seconds.
|
|
821
|
+
- On success or failure, the response includes fields such as `execution_id`, `execution_status`, `execution_terminal`, `execution_elapsed_ms`, and `execution_poll_count`.
|
|
822
|
+
- If the timeout fires, the original trigger still succeeded; the response includes `execution_timed_out: true` and `_wait.hint` with the last observed status.
|
|
823
|
+
- If polling fails after the trigger succeeds, the response includes `_wait.error` and a recheck hint. Do not blindly rerun the pipeline unless you have confirmed the first execution is not running.
|
|
824
|
+
- Failed terminal statuses include `_diagnose_hint` pointing to `harness_diagnose(resource_type="execution", options={execution_id: "..."})`.
|
|
825
|
+
|
|
777
826
|
**Ask the AI DevOps Agent to create a pipeline:**
|
|
778
827
|
|
|
779
828
|
```json
|
|
@@ -991,7 +1040,7 @@ Harness pipelines can be stored in three ways:
|
|
|
991
1040
|
|
|
992
1041
|
## Resource Types
|
|
993
1042
|
|
|
994
|
-
|
|
1043
|
+
190 resource types organized across 32 toolsets. Each resource type supports a subset of CRUD operations and optional execute actions.
|
|
995
1044
|
|
|
996
1045
|
### Platform
|
|
997
1046
|
|
|
@@ -1446,15 +1495,15 @@ Inline PNG chart visualizations rendered from Harness data. These are metadata-o
|
|
|
1446
1495
|
|
|
1447
1496
|
## Toolset Filtering
|
|
1448
1497
|
|
|
1449
|
-
By default,
|
|
1498
|
+
By default, 32 of 33 toolsets are enabled. The `iacm` toolset is opt-in because Harness IaCM APIs are project-scoped and add Terraform workspace/module concepts that many users do not need. The `ai-evals` toolset is default-enabled.
|
|
1450
1499
|
|
|
1451
1500
|
### Adding toolsets with `+` prefix
|
|
1452
1501
|
|
|
1453
|
-
Use the `+` prefix to explicitly include toolsets alongside all defaults
|
|
1502
|
+
Use the `+` prefix to explicitly include opt-in toolsets alongside all defaults:
|
|
1454
1503
|
|
|
1455
1504
|
```bash
|
|
1456
|
-
# Explicitly include
|
|
1457
|
-
HARNESS_TOOLSETS=+
|
|
1505
|
+
# Explicitly include IaCM alongside all defaults
|
|
1506
|
+
HARNESS_TOOLSETS=+iacm
|
|
1458
1507
|
```
|
|
1459
1508
|
|
|
1460
1509
|
### Removing default toolsets
|
|
@@ -1469,8 +1518,8 @@ HARNESS_TOOLSETS=-chaos,-ccm
|
|
|
1469
1518
|
### Combining + and -
|
|
1470
1519
|
|
|
1471
1520
|
```bash
|
|
1472
|
-
# Add
|
|
1473
|
-
HARNESS_TOOLSETS=+
|
|
1521
|
+
# Add IaCM, remove chaos
|
|
1522
|
+
HARNESS_TOOLSETS=+iacm,-chaos
|
|
1474
1523
|
```
|
|
1475
1524
|
|
|
1476
1525
|
### Explicit allowlist
|
|
@@ -1519,6 +1568,7 @@ Available toolset names:
|
|
|
1519
1568
|
| `settings` | setting |
|
|
1520
1569
|
| `visualizations` | visual_timeline, visual_stage_flow, visual_health_dashboard, visual_pie_chart, visual_bar_chart, visual_timeseries, visual_architecture |
|
|
1521
1570
|
| `ai-evals` | eval_dataset, eval_dataset_item, evaluation, eval_run, eval_run_item, eval_run_by_eval, eval_metric, eval_metric_set, eval_metric_set_entry, eval_suite, eval_suite_evaluation, eval_suite_run, eval_target, eval_model, eval_annotation, eval_analytics, eval_git_settings, eval_registry_item |
|
|
1571
|
+
| `iacm` *(opt-in)* | iacm_workspace, iacm_resource, iacm_module, iacm_workspace_costs, iacm_activity_resource_change |
|
|
1522
1572
|
|
|
1523
1573
|
|
|
1524
1574
|
## Architecture
|
|
@@ -1537,7 +1587,7 @@ Available toolset names:
|
|
|
1537
1587
|
+--------v---------+
|
|
1538
1588
|
| Registry | <-- Declarative resource definitions
|
|
1539
1589
|
| 32 Toolsets | (data files, not code)
|
|
1540
|
-
|
|
|
1590
|
+
| 190 Resource Types|
|
|
1541
1591
|
+--------+---------+
|
|
1542
1592
|
|
|
|
1543
1593
|
+--------v---------+
|
|
@@ -1553,10 +1603,11 @@ Available toolset names:
|
|
|
1553
1603
|
|
|
1554
1604
|
1. **Tools** are generic verbs: `harness_list`, `harness_get`, etc. They accept a `resource_type` parameter that routes to the correct API endpoint.
|
|
1555
1605
|
2. **The Registry** maps each `resource_type` to a `ResourceDefinition` — a declarative data structure specifying the HTTP method, URL path, path/query parameter mappings, and response extraction logic.
|
|
1556
|
-
3. **Dispatch** resolves the resource definition, builds the HTTP request (path substitution, query params,
|
|
1606
|
+
3. **Dispatch** resolves the resource definition, builds the HTTP request (path substitution, query params, `resource_scope`-aware account/org/project injection), calls the Harness API through `HarnessClient`, and extracts the relevant response data.
|
|
1557
1607
|
4. **Toolset filtering** (`HARNESS_TOOLSETS`) controls which resource definitions are loaded into the registry at startup.
|
|
1558
|
-
5. **
|
|
1559
|
-
6. **
|
|
1608
|
+
5. **Structured output** is declared with MCP `outputSchema`; `harness_list` coerces arrays and common list wrappers into object-shaped `structuredContent` for strict clients.
|
|
1609
|
+
6. **Deep links** are automatically appended to responses, providing direct Harness UI URLs for every resource.
|
|
1610
|
+
7. **Compact mode** strips verbose metadata from list results, keeping only actionable fields (identity, status, type, timestamps, deep links) to minimize token usage.
|
|
1560
1611
|
|
|
1561
1612
|
### Adding a New Resource Type
|
|
1562
1613
|
|
|
@@ -1643,7 +1694,7 @@ src/
|
|
|
1643
1694
|
ccm.ts
|
|
1644
1695
|
access-control.ts
|
|
1645
1696
|
...
|
|
1646
|
-
tools/ #
|
|
1697
|
+
tools/ # 11 generic MCP tools
|
|
1647
1698
|
harness-list.ts
|
|
1648
1699
|
harness-get.ts
|
|
1649
1700
|
harness-create.ts
|
|
@@ -1654,6 +1705,7 @@ src/
|
|
|
1654
1705
|
harness-diagnose.ts
|
|
1655
1706
|
harness-describe.ts
|
|
1656
1707
|
harness-status.ts
|
|
1708
|
+
harness-schema.ts
|
|
1657
1709
|
|
|
1658
1710
|
resources/ # MCP resource providers
|
|
1659
1711
|
pipeline-yaml.ts
|
|
@@ -1820,10 +1872,13 @@ The Harness MCP server pairs well with **[Harness Skills](https://github.com/har
|
|
|
1820
1872
|
| HTTP `Invalid request` | Invalid JSON body or request body exceeded `HARNESS_MAX_BODY_SIZE_MB` | Validate JSON payload size/shape; increase `HARNESS_MAX_BODY_SIZE_MB` if needed |
|
|
1821
1873
|
| `Unknown resource_type "..."` from tools | Resource type is misspelled or filtered out via `HARNESS_TOOLSETS` | Call `harness_describe` (with optional `search_term`) to discover valid types |
|
|
1822
1874
|
| `Missing required field "... for path parameter ..."` | A project/org scoped call is missing identifiers | Set `HARNESS_ORG`/`HARNESS_PROJECT` or pass `org_id`/`project_id` per tool call |
|
|
1875
|
+
| `resource_scope "org" requires org_id...` or `resource_scope "project" requires project_id...` | A multi-scope resource was forced to org/project scope without enough identifiers | Pass the missing `org_id`/`project_id`, configure `HARNESS_ORG`/`HARNESS_PROJECT`, or use `resource_scope: "account"` when supported |
|
|
1823
1876
|
| `Read-only mode is enabled ... operations are not allowed` | `HARNESS_READ_ONLY=true` blocks create/update/delete/execute | Set `HARNESS_READ_ONLY=false` if write operations are intended |
|
|
1824
1877
|
| Pipeline run fails pre-flight with unresolved required inputs | Provided `inputs` did not cover required runtime placeholders | Fetch `runtime_input_template`, supply missing simple keys, or use `input_set_ids` for structural inputs |
|
|
1825
1878
|
| Pipeline CI shorthand (`branch`, `tag`, `pr_number`, `commit_sha`) did not apply | `inputs.build` was already provided, so shorthand expansion was intentionally skipped | Remove `inputs.build` to use shorthand expansion, or keep full explicit `build` structure |
|
|
1826
1879
|
| Pipeline run loaded the wrong YAML revision | The pipeline definition is stored in Git and the run did not specify the desired pipeline branch | Pass `params.pipeline_branch` on the `run` action; this maps to Harness `pipelineBranchName` |
|
|
1880
|
+
| `wait: true` returned `_wait.error` | The pipeline trigger succeeded, but server-side polling failed | Recheck the `execution_id` with `harness_get(resource_type="execution", ...)` before deciding whether to rerun |
|
|
1881
|
+
| `wait: true` returned `execution_timed_out: true` | The execution did not reach a terminal status before `wait_timeout_seconds` | Use the returned `execution_id` to recheck status or diagnose the still-running execution |
|
|
1827
1882
|
| Execution logs are empty or blob downloads return 403 | Harness-hosted log blob URLs require the configured Harness client/auth path, especially for internal or self-managed hosts | Keep `HARNESS_BASE_URL` pointed at the target Harness host and use `harness_get(resource_type="execution_log", ...)` or `harness_diagnose(..., include_logs=true)` rather than bypassing the MCP client |
|
|
1828
1883
|
| `Operation declined by user` | User declined the elicitation confirmation dialog | The user chose not to proceed — verify the operation details and retry if intended |
|
|
1829
1884
|
| `body.template_yaml (or body.yaml) is required` for template create/update | Template APIs expect full YAML payload | Provide full `template_yaml` string in `body`; for deletes, pass `version_label` to delete one version (omit to delete all versions) |
|
package/build/client/types.d.ts
CHANGED
|
@@ -58,5 +58,10 @@ export interface RequestOptions {
|
|
|
58
58
|
/** Retry policy from OperationPolicy. When "do_not_retry", transient errors
|
|
59
59
|
* (5xx, timeouts) throw immediately instead of retrying. */
|
|
60
60
|
retryPolicy?: "safe" | "idempotency_key_required" | "do_not_retry";
|
|
61
|
+
/** Internal tracing metadata. Never serialized into HTTP headers/query/body. */
|
|
62
|
+
tracing?: {
|
|
63
|
+
/** API name that produced this concrete request path. */
|
|
64
|
+
route?: string;
|
|
65
|
+
};
|
|
61
66
|
}
|
|
62
67
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/client/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,+CAA+C;AAC/C,MAAM,WAAW,eAAe,CAAC,CAAC;IAChC,MAAM,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;IACxC,IAAI,CAAC,EAAE,CAAC,CAAC;IACT,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,yDAAyD;AACzD,MAAM,WAAW,mBAAmB,CAAC,CAAC;IACpC,MAAM,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;IACxC,IAAI,CAAC,EAAE;QACL,OAAO,CAAC,EAAE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UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,cAAc;IAC7B,MAAM,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;IACrD,IAAI,EAAE,MAAM,CAAC;IACb,oGAAoG;IACpG,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,EAAE,GAAG,SAAS,CAAC,CAAC;IAC1E,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,uFAAuF;IACvF,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,oEAAoE;IACpE,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,oFAAoF;IACpF,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,gEAAgE;IAChE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iGAAiG;IACjG,YAAY,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;IACjC,gFAAgF;IAChF,OAAO,CAAC,EAAE,SAAS,GAAG,KAAK,CAAC;IAC5B;0FACsF;IACtF,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;iEAC6D;IAC7D,WAAW,CAAC,EAAE,MAAM,GAAG,0BAA0B,GAAG,cAAc,CAAC;IACnE,gFAAgF;IAChF,OAAO,CAAC,EAAE;QACR,yDAAyD;QACzD,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pipeline.d.ts","sourceRoot":"","sources":["../../../../src/data/schemas/v0/pipeline.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,
|
|
1
|
+
{"version":3,"file":"pipeline.d.ts","sourceRoot":"","sources":["../../../../src/data/schemas/v0/pipeline.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CA0sjH/B,CAAC;AACF,eAAe,MAAM,CAAC"}
|