issue
Creates, updates, deletes, gets or lists an issue resource.
Overview​
| Name | issue |
| Type | Resource |
| Id | gitlab.issues.issue |
Fields​
The following fields are returned by SELECT queries:
- get
GraphQL response envelope
| Name | Datatype | Description |
|---|---|---|
id | string | ID of the issue. |
name | string | Name or title of the object. |
project_id | integer | ID of the issue project. |
author | object | UserCore identity (id, username, name) |
blocked | boolean | Indicates the issue is blocked. |
blocked_by_count | integer | Count of issues blocking the issue. |
blocking_count | integer | Count of issues the issue is blocking. |
closed_at | string | Timestamp of when the issue was closed. |
confidential | boolean | Indicates the issue is confidential. |
create_note_email | string | User specific email address for the issue. |
created_at | string | Timestamp of when the issue was created. |
description | string | Description of the issue. |
discussion_locked | boolean | Indicates discussion is locked on the issue. |
downvotes | integer | Number of downvotes the issue has received. |
due_date | string | Due date of the issue. |
emails_enabled | boolean | Indicates if the parent project or group has email notifications disabled: false if email notifications are disabled. |
escalation_status | string | Escalation status of the issue. (TRIGGERED, ACKNOWLEDGED, RESOLVED, IGNORED) |
external_author | string | Email address of non-GitLab user reporting the issue. For guests, the email address is obfuscated. |
has_epic | boolean | Indicates if the issue belongs to an epic. Can return true and not show an associated epic when the user has no access to the epic. |
health_status | string | Current health status. (onTrack, needsAttention, atRisk) |
hidden | boolean | Indicates the issue is hidden because the author has been banned. |
human_time_estimate | string | Human-readable time estimate of the issue. |
human_total_time_spent | string | Human-readable total time reported as spent on the issue. |
iid | string | Internal ID of the issue. |
merge_requests_count | integer | Number of merge requests that close the issue on merge. |
milestone | object | Milestone identity (id, title) |
moved | boolean | Indicates if issue got moved from other project. |
reference | string | Internal reference of the issue. Returned in shortened format by default. |
relative_position | integer | Relative position of the issue (used for positioning in epic tree and issue boards). |
severity | string | Severity level of the incident. (UNKNOWN, LOW, MEDIUM, HIGH, CRITICAL) |
sla_due_at | string | Timestamp of when the issue SLA expires. |
state | string | State of the issue. (opened, closed, locked, all) |
status_page_published_incident | boolean | Indicates whether an issue is published to the status page. |
subscribed | boolean | Indicates the currently logged in user is subscribed to the issue. |
time_estimate | integer | Time estimate of the issue. |
title | string | Title of the issue. |
total_time_spent | integer | Total time (in seconds) reported as spent on the issue. |
type | string | Type of the issue. (ISSUE, INCIDENT, TEST_CASE, REQUIREMENT, TASK, TICKET) |
updated_at | string | Timestamp of when the issue was last updated. |
upvotes | integer | Number of upvotes the issue has received. |
user_discussions_count | integer | Number of user discussions in the issue. |
user_notes_count | integer | Number of user notes of the issue. |
web_path | string | Web path of the issue. |
web_url | string | Web URL of the issue. |
weight | integer | Weight of the issue. |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | id, host | Find an issue. Generated from the GitLab GraphQL schema field Query.issue (Issue). |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
host | string | GitLab host, with an optional port (default gitlab.com). Resolved from the GITLAB_HOST environment variable when it is set (x-stackQL-envVar); a WHERE host value always takes precedence. Self-managed instances: the provider is generated from the gitlab.com schema, so older instances may reject fields they do not serve. (default: gitlab.com, x-stackQL-envVar: GITLAB_HOST) |
id | string | Global ID of the issue. |
SELECT examples​
- get
Find an issue. Generated from the GitLab GraphQL schema field Query.issue (Issue).
SELECT
id,
name,
project_id,
author,
blocked,
blocked_by_count,
blocking_count,
closed_at,
confidential,
create_note_email,
created_at,
description,
discussion_locked,
downvotes,
due_date,
emails_enabled,
escalation_status,
external_author,
has_epic,
health_status,
hidden,
human_time_estimate,
human_total_time_spent,
iid,
merge_requests_count,
milestone,
moved,
reference,
relative_position,
severity,
sla_due_at,
state,
status_page_published_incident,
subscribed,
time_estimate,
title,
total_time_spent,
type,
updated_at,
upvotes,
user_discussions_count,
user_notes_count,
web_path,
web_url,
weight
FROM gitlab.issues.issue
WHERE id = '{{ id }}' -- required
AND host = '{{ host }}' -- required (defaults to gitlab.com; or set GITLAB_HOST)
;