DeepSource MCP Server

by sapientpants

deepsource_update_metric_threshold

Modify or remove threshold values for quality metrics in a DeepSource project, enabling precise control over pass/fail criteria per language or repository.

Instructions

Update the threshold for a specific quality metric in a DeepSource project.

This allows setting or removing threshold values that determine if a metric passes or fails. Thresholds can be set per language or for the entire repository (AGGREGATE).

Examples:

  • Set a 80% line coverage threshold: metricShortcode="LCV", metricKey="AGGREGATE", thresholdValue=80
  • Remove a threshold: metricShortcode="LCV", metricKey="AGGREGATE", thresholdValue=null

Input Schema

NameRequiredDescriptionDefault
metricKeyYesThe language or context key for the metric
metricShortcodeYesThe shortcode of the metric to update
projectKeyYesThe unique identifier for the DeepSource project
repositoryIdYesThe GraphQL repository ID (get this from deepsource_quality_metrics response)
thresholdValueNoThe new threshold value (null to remove the threshold)

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "metricKey": { "description": "The language or context key for the metric", "enum": [ "AGGREGATE", "PYTHON", "JAVASCRIPT", "TYPESCRIPT", "GO", "JAVA", "RUBY", "RUST" ], "type": "string" }, "metricShortcode": { "description": "The shortcode of the metric to update", "enum": [ "LCV", "BCV", "DCV", "DDP", "SCV", "TCV", "CMP" ], "type": "string" }, "projectKey": { "description": "The unique identifier for the DeepSource project", "type": "string" }, "repositoryId": { "description": "The GraphQL repository ID (get this from deepsource_quality_metrics response)", "type": "string" }, "thresholdValue": { "description": "The new threshold value (null to remove the threshold)", "type": [ "number", "null" ] } }, "required": [ "projectKey", "repositoryId", "metricShortcode", "metricKey" ], "type": "object" }

You must be authenticated.

Other Tools from DeepSource MCP Server

Related Tools

ID: u4wlvmu5z8