---
metadata:
  - name: generator
    content: Diplodoc Platform v5.71.0
alternate:
  - https://vibe.sourcecraft.dev/portal/docs/en/sec-api-ref/Operations/v1operationsoperationUuid-get.md
  - https://vibe.sourcecraft.dev/portal/docs/en/sec-api-ref/Operations/v1operationsoperationUuid-get.md
  - https://vibe.sourcecraft.dev/portal/docs/ru/sec-api-ref/Operations/v1operationsoperationUuid-get.md
  - href: https://vibe.sourcecraft.dev/portal/docs/en/sec-api-ref/Operations/v1operationsoperationUuid-get.md
    type: text/markdown
    title: Markdown version
  - href: https://vibe.sourcecraft.dev/portal/docs/en/llms.txt?revision=r22261781
    rel: describedby
---
> **Documentation Index:** Fetch the complete configuration index at https://vibe.sourcecraft.dev/portal/docs/en/llms.txt?revision=r22261781

<div class="openapi">

# Get an AppSec operation

<!-- markdownlint-disable-file -->

Reads any operation type, including AI suggestions, batch prioritization, fixes, audits and report generation. Returns status, completion state and source/result UUIDs. AI fix and audit operations also include job metadata when available. Supports operations stored under the repository ID, public UUID or the supplied legacy identifier. Requires permission to read AppSec results for the repository. A failed operation returns HTTP 200 with status FAILED and done=true.

## Request

<div class="openapi__requests">

<div class="openapi__request__wrapper" style="--method: var(--dc-openapi-methods-get);margin-bottom: 12px">

<div class="openapi__request">

GET {.openapi__method}
```text translate=no
https://appsec.sourcecraft.tech/v1/operations/{operationUuid}
```

</div>

</div>

</div>

### Path parameters

#|
|| **Name** | **Description** ||
||

_operationUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

UUID of the operation to read

_Example:_{.json-schema-reset .json-schema-example} ``
{.table-cell}
||
|#{.json-schema-properties}

### Query parameters

#|
|| **Name** | **Description** ||
||

_gitRepo_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Repository identifier. Accepts either internal repository ID (e.g., 88769874964302633) or public UUID (e.g., 0199140f-4343-7c06-a7e3-b835c305b629). These values can be obtained from the getRepo API (fields: id and uuid).

_Pattern:_{.json-schema-reset .json-schema-assertion} `\S`

_Example:_{.json-schema-reset .json-schema-example} `0199140f-4343-7c06-a7e3-b835c305b629`
{.table-cell}
||
|#{.json-schema-properties}

## Responses

<div class="openapi__response__code__200">

## 200 OK

Current operation state

<div class="openapi-entity">

### Body

{% cut "application/json" %}

```json translate=no
{
  "operationUuid": "example",
  "type": "ACTIVITY_AI_SUGGESTION",
  "status": "IN_PROGRESS",
  "done": true,
  "gitRepo": "example",
  "createdAt": 0,
  "updatedAt": 0,
  "createdBy": "example",
  "entityUuid": "example",
  "createdEntityUuid": "example",
  "metadata": {
    "gitRepo": "example",
    "defectGroupUuid": "example",
    "jobId": "example",
    "linkUuid": "example",
    "activityUuid": "example"
  }
}
```

{% endcut %}

#|
|| **Name** | **Description** ||
||

_createdAt_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: integer

Creation time in milliseconds since the Unix epoch
{.table-cell}
||
||

_createdBy_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_createdEntityUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string &#124; null

UUID of the generated report, suggestion activity or AI agent run, depending on type. May be allocated before completion; check status before using the result.

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_done_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: boolean

True for both COMPLETED and FAILED; inspect status to distinguish success from failure
{.table-cell}
||
||

_entityUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string &#124; null

UUID of the source entity: a scan for report generation or a defect group for AI suggestion/fix

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_gitRepo_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Repository identifier stored with the operation; may be an ID, public UUID or a legacy identifier

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_metadata_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: object &#124; null

{% cut "**Any of 2 types**" %}{.json-schema-combinators data-marker=or}

- **Type**: [OperationAgentMetadataDto](#entity-OperationAgentMetadataDto)

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "gitRepo": "example",
    "defectGroupUuid": "example",
    "jobId": "example",
    "linkUuid": "example",
    "activityUuid": "example"
  }
  ```

  {% endcut %}

- **Type**: null

  _Example:_{.json-schema-reset .json-schema-example} `null`

{% endcut %}

Metadata of an AI fix, triage or audit job, when available

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "gitRepo": "example",
  "defectGroupUuid": "example",
  "jobId": "example",
  "linkUuid": "example",
  "activityUuid": "example"
}
```

{% endcut %}
{.table-cell}
||
||

_operationUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_status_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: [OperationStatus](#entity-OperationStatus)

_Enum:_{.json-schema-reset .json-schema-value} `IN_PROGRESS`, `COMPLETED`, `FAILED`
{.table-cell}
||
||

_type_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: [OperationType](#entity-OperationType)

_Enum:_{.json-schema-reset .json-schema-value} `ACTIVITY_AI_SUGGESTION`, `DEFECT_GROUPS_BATCH_PRIORITIZE`, `GENERATE_REPORT`, `TRIGGER_DEFECT_FIX`, `TRIGGER_AUDIT`, `GENERATE_SARIF_REPORT_ALL`, `GENERATE_SARIF_REPORT_SECRETS`, `GENERATE_SARIF_REPORT_SCA`, `GENERATE_SARIF_REPORT_SAST`, `GENERATE_SARIF_REPORT_DAST`, `AGENT_TRIAGE`, `STOP_SCAN`
{.table-cell}
||
||

_updatedAt_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: integer

Last update time in milliseconds since the Unix epoch
{.table-cell}
||
|#{.json-schema-properties}

</div>

<div class="openapi-entity">

### OperationType {#entity-OperationType}

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `ACTIVITY_AI_SUGGESTION`, `DEFECT_GROUPS_BATCH_PRIORITIZE`, `GENERATE_REPORT`, `TRIGGER_DEFECT_FIX`, `TRIGGER_AUDIT`, `GENERATE_SARIF_REPORT_ALL`, `GENERATE_SARIF_REPORT_SECRETS`, `GENERATE_SARIF_REPORT_SCA`, `GENERATE_SARIF_REPORT_SAST`, `GENERATE_SARIF_REPORT_DAST`, `AGENT_TRIAGE`, `STOP_SCAN`

</div>

<div class="openapi-entity">

### OperationStatus {#entity-OperationStatus}

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `IN_PROGRESS`, `COMPLETED`, `FAILED`

</div>

<div class="openapi-entity">

### OperationAgentMetadataDto {#entity-OperationAgentMetadataDto}

#|
|| **Name** | **Description** ||
||

_defectGroupUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string &#124; null

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_gitRepo_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_jobId_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string &#124; null

AI job ID; null while the agent job is still being started

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_linkUuid_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string &#124; null

UUID of the defect group's SOURCECRAFT_PR link, once reported by the fix agent

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_activityUuid_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string &#124; null

UUID of the accepted triage result activity; null until a result is saved

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "gitRepo": "example",
  "defectGroupUuid": "example",
  "jobId": "example",
  "linkUuid": "example",
  "activityUuid": "example"
}
```

{% endcut %}

</div>

</div>

<div class="openapi__response__code__400">

## 400 Bad Request

Missing gitRepo or invalid operation UUID

</div>

<div class="openapi__response__code__401">

## 401 Unauthorized

Missing or invalid authorization header

</div>

<div class="openapi__response__code__403">

## 403 Forbidden

Permission denied

</div>

<div class="openapi__response__code__404">

## 404 Not Found

Repository not found, or operation not found in this repository

</div>

</div>

[*Deprecated]: No longer supported, please use an alternative and newer version.