v1

latestOpenAPI 3.0.32026-07-22238629559.2 KB
IssuesService

Get Issue

Get a single issue by ID with details

get/api/agent/deployments/{deploymentId}/issues/v2/{issueId}

Path parameters

deploymentIdstring required
issueIdstring required

Query parameters

includeCodeSnippetboolean

When true, include code snippets in the response. Defaults to true for non-secrets when unset. Does not apply to secrets: this option has no effect for secret issues—snippets are never returned for secrets (security; no masking yet).

includeIsArchivedboolean

When true, populate the is_archived field on the response. Defaults to false.

Response

OK

idstring

ID of the finding

createdAtstring date-time

Creation timestamp

refstring

Branch where the finding was detected

syntacticIdstring

Semi-unique hash of a check consisting of: Line Numbers, File Path, Rule ID, Index of finding in file, and Matched code

matchBasedIdstring

Semi-unique hash of a check consisting of: File Path, Rule ID, Index of finding in file, and Rule Formula with metavariable bindings substituted in

ruleIdstring

The ID of the associated semgrep rule

status'ISSUE_STATUS_FIXED' | 'ISSUE_STATUS_MUTED' | 'ISSUE_STATUS_REMOVED' | 'ISSUE_STATUS_UNRESOLVED' enum
valuedescription
ISSUE_STATUS_FIXED
ISSUE_STATUS_MUTED
ISSUE_STATUS_REMOVED
ISSUE_STATUS_UNRESOLVED
triageState'FINDING_TRIAGE_STATE_UNTRIAGED' | 'FINDING_TRIAGE_STATE_IGNORED' | 'FINDING_TRIAGE_STATE_REOPENED' | 'FINDING_TRIAGE_STATE_UNKNOWN' | 'FINDING_TRIAGE_STATE_REVIEWING' | 'FINDING_TRIAGE_STATE_FIXING' | 'FINDING_TRIAGE_STATE_PROVISIONALLY_IGNORED' enum

The issue's current triage state.

valuedescription
FINDING_TRIAGE_STATE_UNTRIAGED
FINDING_TRIAGE_STATE_IGNORED
FINDING_TRIAGE_STATE_REOPENED
FINDING_TRIAGE_STATE_UNKNOWN
FINDING_TRIAGE_STATE_REVIEWING
FINDING_TRIAGE_STATE_FIXING
FINDING_TRIAGE_STATE_PROVISIONALLY_IGNORED
triageReason'FINDING_TRIAGE_REASON_FALSE_POSITIVE' | 'FINDING_TRIAGE_REASON_NO_TIME' | 'FINDING_TRIAGE_REASON_ACCEPTABLE_RISK' | 'FINDING_TRIAGE_REASON_NO_TRIAGE_REASON' | 'FINDING_TRIAGE_REASON_UNKNOWN' | 'FINDING_TRIAGE_REASON_DUPLICATE' enum

The reason the issue was triaged.

valuedescription
FINDING_TRIAGE_REASON_FALSE_POSITIVE
FINDING_TRIAGE_REASON_NO_TIME
FINDING_TRIAGE_REASON_ACCEPTABLE_RISK
FINDING_TRIAGE_REASON_NO_TRIAGE_REASON
FINDING_TRIAGE_REASON_UNKNOWN
FINDING_TRIAGE_REASON_DUPLICATE
relevantSincestring date-time

The timestamp from which this issue was relevant

aggregateState'AGGREGATE_ISSUE_STATE_OPEN' | 'AGGREGATE_ISSUE_STATE_FIXED' | 'AGGREGATE_ISSUE_STATE_REMOVED' | 'AGGREGATE_ISSUE_STATE_IGNORED_APP' | 'AGGREGATE_ISSUE_STATE_IGNORED_CODE' | 'AGGREGATE_ISSUE_STATE_UNKNOWN' | 'AGGREGATE_ISSUE_STATE_REVIEWING' | 'AGGREGATE_ISSUE_STATE_FIXING' | 'AGGREGATE_ISSUE_STATE_PROVISIONALLY_IGNORED_APP' enum

The overall state of the issue, accounting for status (controlled by scans), triaging, external events like PR closes, etc. TODO: use the AggregateState enum instead of raw strings.

valuedescription
AGGREGATE_ISSUE_STATE_OPEN
AGGREGATE_ISSUE_STATE_FIXED
AGGREGATE_ISSUE_STATE_REMOVED
AGGREGATE_ISSUE_STATE_IGNORED_APP
AGGREGATE_ISSUE_STATE_IGNORED_CODE
AGGREGATE_ISSUE_STATE_UNKNOWN
AGGREGATE_ISSUE_STATE_REVIEWING
AGGREGATE_ISSUE_STATE_FIXING
AGGREGATE_ISSUE_STATE_PROVISIONALLY_IGNORED_APP
notestring

Comment left when triaged

vulnGroupKeystring

The key used to group supply chain vulns (deprecated)

isBlockingboolean

True if this issue is a blocking issue.

lineOfCodeUrlstring

The URL to the specific line of code causing this issue

codeSnippetstring

The code snippet causing this issue. Only available when fetching a single issue at a time via the GetIssue RPC. Deprecated in favor of code_snippets for multi-file support.

commitUrlstring

The URL of the specific commit which introduced this issue. Only available when fetching a single issue at a time via the GetIssue RPC.

filePathstring

The path to the file in which this issue was found.

lineinteger

The first line number in which this issue was found.

endLineinteger

The end line number in which this issue was found (if the offending code spans several lines).

columninteger

The start column number within the line in which this issue was found.

endColumninteger

The end column number within the last line in which this issue was found (if applicable).

severity'SEVERITY_HIGH' | 'SEVERITY_MEDIUM' | 'SEVERITY_LOW' | 'SEVERITY_CRITICAL' enum

The severity ("seriousness") of the issue.

valuedescription
SEVERITY_HIGH
SEVERITY_MEDIUM
SEVERITY_LOW
SEVERITY_CRITICAL
messagestring

An optional message that helps describe the issue in more detail.

rulePathstring

The full path of the rule used to generate this issue.

confidence'CONFIDENCE_HIGH' | 'CONFIDENCE_MEDIUM' | 'CONFIDENCE_LOW' enum

The confidence in false-positive rate of an issue.

valuedescription
CONFIDENCE_HIGH
CONFIDENCE_MEDIUM
CONFIDENCE_LOW
ruleUrlstring

The url of the rule used to generate this issue.

ruleReferencesstring[]

A list of external references (URLs) which help describe or provide context for the rule used to generate this issue.

ruleOrigin'RULE_ORIGIN_CUSTOM' | 'RULE_ORIGIN_COMMUNITY' | 'RULE_ORIGIN_PRO_RULES' enum

The origin of the rule (pro rules, semgrep community, or a custom rule)

valuedescription
RULE_ORIGIN_CUSTOM
RULE_ORIGIN_COMMUNITY
RULE_ORIGIN_PRO_RULES
ruleHashIdstring

The hash of the associated rule.

ruleCweNamesstring[]

The names of the CWEs associated with this issue's rule.

ruleOwaspNamesstring[]

The names of the OWASP categories associated with this issue's rule.

rulesetstring

The ruleset to which this issue's rule belongs (if applicable).

policySlugstring

A slugified version of the associated rule's policy.

categorystring

The issue's category (or "other" if none).

issueType'ISSUE_TYPE_SAST' | 'ISSUE_TYPE_SCA' | 'ISSUE_TYPE_SECRETS' | 'ISSUE_TYPE_RESEARCH' | 'ISSUE_TYPE_AI_SAST' enum

The product which owns this issue, e.g. SAST (code), SCA (supply chain), etc.

valuedescription
ISSUE_TYPE_SASTDetected by Code rules
ISSUE_TYPE_SCADetected by Supply Chain rules
ISSUE_TYPE_SECRETSDetected by Secrets rules
ISSUE_TYPE_RESEARCHDetected by research rules or scanners
ISSUE_TYPE_AI_SASTDetected by AI detection code scanning
issueParentIdstring

Parent ID of the finding. Present for all types.

sastAttributesProtosIssuesV1IssueSastAttributes

Groups the fields of Issue that are specific to the SAST product

subcategoriesstring[]

The issue's subcategories

refUrlstring

The URL of the specific commit which introduced this issue. Only available when fetching a single issue at a time via the GetIssue RPC.

ruleDisplayNamestring

The human-readable display name of the rule (e.g., "Hardcoded secret"). Only available when fetching a single issue at a time via the GetIssue RPC.

clickToFixPrUrlstring

The URL of the Click-to-Fix PR that was opened to fix this issue (if any). Available in the GetIssue RPC and in list responses that opt into it.

aiImpactstring

AI Detection only: LLM-generated description of the vulnerability's impact. Only available when fetching a single issue at a time via the GetIssue RPC.

clickToFixCommitMsgstring

The commit message for the Click-to-Fix PR (if any). Only available when fetching a single issue at a time via the GetIssue RPC.

clickToFixPrIdstring

The SCM-agnostic PR identifier for the Click-to-Fix PR (if any). Available in the GetIssue RPC and in list responses that opt into it. Prefer this over parsing the PR number from click_to_fix_pr_url.

triagePermission'TRIAGE_PERMISSION_IGNORE' | 'TRIAGE_PERMISSION_REQUEST' | 'TRIAGE_PERMISSION_NONE' enum

The triage permission for this issue: whether a developer may ignore it themselves, must request an exception, or cannot triage it at all. Only defined when the developer approvals feature is enabled.

valuedescription
TRIAGE_PERMISSION_IGNORE
TRIAGE_PERMISSION_REQUEST
TRIAGE_PERMISSION_NONE
isArchivedboolean

True if this finding's project is archived (Semgrep-initiated via is_semgrep_archived, or SCM-archived).