Skip to main content
PATCH
/
v1
/
projects
/
{project}
/
issues
/
{issue}
cURL
curl --request PATCH \
  --url https://api.example.com/v1/projects/{project}/issues/{issue} \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "title": "<string>",
  "description": "<string>",
  "type": "TYPE_UNSPECIFIED",
  "status": "ISSUE_STATUS_UNSPECIFIED",
  "approvers": [
    {
      "status": "STATUS_UNSPECIFIED",
      "principal": "<string>"
    }
  ],
  "approvalTemplate": {
    "flow": {
      "roles": [
        "<string>"
      ]
    },
    "title": "<string>",
    "description": "<string>"
  },
  "plan": "<string>",
  "rollout": "<string>",
  "grantRequest": {
    "role": "<string>",
    "user": "<string>",
    "condition": {
      "id": "<string>",
      "constExpr": {
        "nullValue": "NULL_VALUE",
        "boolValue": true,
        "int64Value": "<string>",
        "uint64Value": "<string>",
        "doubleValue": 123,
        "stringValue": "<string>",
        "bytesValue": "<string>",
        "durationValue": "<string>",
        "timestampValue": "2023-11-07T05:31:56Z"
      },
      "identExpr": {
        "name": "<string>"
      },
      "selectExpr": {
        "operand": "<unknown>",
        "field": "<string>",
        "testOnly": true
      },
      "callExpr": {
        "target": "<unknown>",
        "function": "<string>",
        "args": "<array>"
      },
      "listExpr": {
        "elements": "<array>",
        "optionalIndices": [
          123
        ]
      },
      "structExpr": {
        "messageName": "<string>",
        "entries": [
          {
            "id": "<string>",
            "fieldKey": "<string>",
            "mapKey": "<unknown>",
            "value": "<unknown>",
            "optionalEntry": true
          }
        ]
      },
      "comprehensionExpr": {
        "iterVar": "<string>",
        "iterVar2": "<string>",
        "iterRange": "<unknown>",
        "accuVar": "<string>",
        "accuInit": "<unknown>",
        "loopCondition": "<unknown>",
        "loopStep": "<unknown>",
        "result": "<unknown>"
      }
    },
    "expiration": "<string>"
  },
  "releasers": [
    "<string>"
  ],
  "riskLevel": "RISK_LEVEL_UNSPECIFIED",
  "taskStatusCount": {},
  "labels": [
    "<string>"
  ]
}
'
{
  "name": "<string>",
  "title": "<string>",
  "description": "<string>",
  "type": "TYPE_UNSPECIFIED",
  "status": "ISSUE_STATUS_UNSPECIFIED",
  "approvers": [
    {
      "status": "STATUS_UNSPECIFIED",
      "principal": "<string>"
    }
  ],
  "approvalTemplate": {
    "flow": {
      "roles": [
        "<string>"
      ]
    },
    "title": "<string>",
    "description": "<string>"
  },
  "creator": "<string>",
  "createTime": "2023-11-07T05:31:56Z",
  "updateTime": "2023-11-07T05:31:56Z",
  "plan": "<string>",
  "rollout": "<string>",
  "grantRequest": {
    "role": "<string>",
    "user": "<string>",
    "condition": {
      "id": "<string>",
      "constExpr": {
        "nullValue": "NULL_VALUE",
        "boolValue": true,
        "int64Value": "<string>",
        "uint64Value": "<string>",
        "doubleValue": 123,
        "stringValue": "<string>",
        "bytesValue": "<string>",
        "durationValue": "<string>",
        "timestampValue": "2023-11-07T05:31:56Z"
      },
      "identExpr": {
        "name": "<string>"
      },
      "selectExpr": {
        "operand": "<unknown>",
        "field": "<string>",
        "testOnly": true
      },
      "callExpr": {
        "target": "<unknown>",
        "function": "<string>",
        "args": "<array>"
      },
      "listExpr": {
        "elements": "<array>",
        "optionalIndices": [
          123
        ]
      },
      "structExpr": {
        "messageName": "<string>",
        "entries": [
          {
            "id": "<string>",
            "fieldKey": "<string>",
            "mapKey": "<unknown>",
            "value": "<unknown>",
            "optionalEntry": true
          }
        ]
      },
      "comprehensionExpr": {
        "iterVar": "<string>",
        "iterVar2": "<string>",
        "iterRange": "<unknown>",
        "accuVar": "<string>",
        "accuInit": "<unknown>",
        "loopCondition": "<unknown>",
        "loopStep": "<unknown>",
        "result": "<unknown>"
      }
    },
    "expiration": "<string>"
  },
  "releasers": [
    "<string>"
  ],
  "riskLevel": "RISK_LEVEL_UNSPECIFIED",
  "taskStatusCount": {},
  "labels": [
    "<string>"
  ],
  "approvalStatus": "APPROVAL_STATUS_UNSPECIFIED",
  "approvalStatusError": "<string>"
}

Path Parameters

project
string
required

The project id.

issue
string
required

The issue id.

Query Parameters

updateMask
string<field-mask>

The list of fields to update.

allowMissing
boolean

If set to true, and the issue is not found, a new issue will be created. In this situation, update_mask is ignored.

Body

application/json
name
string

The name of the issue. Format: projects/{project}/issues/{issue}

title
string

The title of the issue.

description
string

The description of the issue.

type
enum<string>
Available options:
TYPE_UNSPECIFIED,
DATABASE_CHANGE,
GRANT_REQUEST,
DATABASE_EXPORT
status
enum<string>

The status of the issue.

Available options:
ISSUE_STATUS_UNSPECIFIED,
OPEN,
DONE,
CANCELED
approvers
object[]
approvalTemplate
object

The approval template for the issue.

plan
string

The plan associated with the issue. Can be empty. Format: projects/{project}/plans/{plan}

rollout
string

The rollout associated with the issue. Can be empty. Format: projects/{project}/rollouts/{rollout}

grantRequest
object

Used if the issue type is GRANT_REQUEST.

releasers
string[]

The releasers of the pending stage of the issue rollout, judging from the rollout policy. Format:

  • roles/workspaceOwner
  • roles/workspaceDBA
  • roles/projectOwner
  • roles/projectReleaser
riskLevel
enum<string>

The risk level of the issue.

Available options:
RISK_LEVEL_UNSPECIFIED,
LOW,
MODERATE,
HIGH
taskStatusCount
object

The status count of the issue. Keys are the following:

  • NOT_STARTED
  • SKIPPED
  • PENDING
  • RUNNING
  • DONE
  • FAILED
  • CANCELED
labels
string[]

Labels attached to the issue for categorization and filtering.

Response

OK

name
string

The name of the issue. Format: projects/{project}/issues/{issue}

title
string

The title of the issue.

description
string

The description of the issue.

type
enum<string>
Available options:
TYPE_UNSPECIFIED,
DATABASE_CHANGE,
GRANT_REQUEST,
DATABASE_EXPORT
status
enum<string>

The status of the issue.

Available options:
ISSUE_STATUS_UNSPECIFIED,
OPEN,
DONE,
CANCELED
approvers
object[]
approvalTemplate
object

The approval template for the issue.

creator
string

Format: users/[email protected]

createTime
string<date-time>
updateTime
string<date-time>
plan
string

The plan associated with the issue. Can be empty. Format: projects/{project}/plans/{plan}

rollout
string

The rollout associated with the issue. Can be empty. Format: projects/{project}/rollouts/{rollout}

grantRequest
object

Used if the issue type is GRANT_REQUEST.

releasers
string[]

The releasers of the pending stage of the issue rollout, judging from the rollout policy. Format:

  • roles/workspaceOwner
  • roles/workspaceDBA
  • roles/projectOwner
  • roles/projectReleaser
riskLevel
enum<string>

The risk level of the issue.

Available options:
RISK_LEVEL_UNSPECIFIED,
LOW,
MODERATE,
HIGH
taskStatusCount
object

The status count of the issue. Keys are the following:

  • NOT_STARTED
  • SKIPPED
  • PENDING
  • RUNNING
  • DONE
  • FAILED
  • CANCELED
labels
string[]

Labels attached to the issue for categorization and filtering.

approvalStatus
enum<string>
Available options:
APPROVAL_STATUS_UNSPECIFIED,
CHECKING,
PENDING,
APPROVED,
REJECTED,
SKIPPED,
ERROR
approvalStatusError
string

Only populated when approval_status == ERROR