|
| 1 | +--- |
| 2 | +# generated by https://github.com/hashicorp/terraform-plugin-docs |
| 3 | +page_title: "gitlab_project_issue Data Source - terraform-provider-gitlab" |
| 4 | +subcategory: "" |
| 5 | +description: |- |
| 6 | + This data source allows you to access GitLab Project Issues. |
| 7 | + Upstream API: GitLab API docs https://docs.gitlab.com/ee/api/issues.html |
| 8 | +--- |
| 9 | + |
| 10 | +# gitlab_project_issue (Data Source) |
| 11 | + |
| 12 | +This data source allows you to access GitLab Project Issues. |
| 13 | + |
| 14 | +**Upstream API:** [GitLab API docs](https://docs.gitlab.com/ee/api/issues.html) |
| 15 | + |
| 16 | +## Example Usage |
| 17 | + |
| 18 | +```terraform |
| 19 | +data "gitlab_project" "foo" { |
| 20 | + id = "foo/bar/baz" |
| 21 | +} |
| 22 | +
|
| 23 | +data "gitlab_project_issue" "welcome_issue" { |
| 24 | + project = data.gitlab_project.foo.id |
| 25 | + iid = 1 |
| 26 | +} |
| 27 | +
|
| 28 | +output "welcome_issue_web_url" { |
| 29 | + value = data.gitlab_project_issue.web_url |
| 30 | +} |
| 31 | +``` |
| 32 | + |
| 33 | +<!-- schema generated by tfplugindocs --> |
| 34 | +## Schema |
| 35 | + |
| 36 | +### Required |
| 37 | + |
| 38 | +- **iid** (Number) The internal ID of the project's issue. |
| 39 | +- **project** (String) The name or ID of the project. |
| 40 | + |
| 41 | +### Optional |
| 42 | + |
| 43 | +- **id** (String) The ID of this resource. |
| 44 | + |
| 45 | +### Read-Only |
| 46 | + |
| 47 | +- **assignee_ids** (Set of Number) The IDs of the users to assign the issue to. |
| 48 | +- **author_id** (Number) The ID of the author of the issue. Use `gitlab_user` data source to get more information about the user. |
| 49 | +- **closed_at** (String) When the issue was closed. Date time string, ISO 8601 formatted, for example 2016-03-11T03:45:40Z. |
| 50 | +- **closed_by_user_id** (Number) The ID of the user that closed the issue. Use `gitlab_user` data source to get more information about the user. |
| 51 | +- **confidential** (Boolean) Set an issue to be confidential. |
| 52 | +- **created_at** (String) When the issue was created. Date time string, ISO 8601 formatted, for example 2016-03-11T03:45:40Z. Requires administrator or project/group owner rights. |
| 53 | +- **description** (String) The description of an issue. Limited to 1,048,576 characters. |
| 54 | +- **discussion_locked** (Boolean) Whether the issue is locked for discussions or not. |
| 55 | +- **discussion_to_resolve** (String) The ID of a discussion to resolve. This fills out the issue with a default description and mark the discussion as resolved. Use in combination with merge_request_to_resolve_discussions_of. |
| 56 | +- **downvotes** (Number) The number of downvotes the issue has received. |
| 57 | +- **due_date** (String) The due date. Date time string in the format YYYY-MM-DD, for example 2016-03-11. |
| 58 | +**Note:** removing a due date is currently not supported, see https://github.com/xanzy/go-gitlab/issues/1384 for details. |
| 59 | +- **epic_id** (Number) ID of the epic to add the issue to. Valid values are greater than or equal to 0. |
| 60 | +- **epic_issue_id** (Number) The ID of the epic issue. |
| 61 | +- **external_id** (String) The external ID of the issue. |
| 62 | +- **human_time_estimate** (String) The human-readable time estimate of the issue. |
| 63 | +- **human_total_time_spent** (String) The human-readable total time spent of the issue. |
| 64 | +- **issue_id** (Number) The instance-wide ID of the issue. |
| 65 | +- **issue_link_id** (Number) The ID of the issue link. |
| 66 | +- **issue_type** (String) The type of issue. Valid values are: `issue`, `incident`, `test_case`. |
| 67 | +- **labels** (Set of String) The labels of an issue. |
| 68 | +- **links** (Map of String) The links of the issue. |
| 69 | +- **merge_request_to_resolve_discussions_of** (Number) The IID of a merge request in which to resolve all issues. This fills out the issue with a default description and mark all discussions as resolved. When passing a description or title, these values take precedence over the default values. |
| 70 | +- **merge_requests_count** (Number) The number of merge requests associated with the issue. |
| 71 | +- **milestone_id** (Number) The global ID of a milestone to assign issue. To find the milestone_id associated with a milestone, view an issue with the milestone assigned and use the API to retrieve the issue's details. |
| 72 | +- **moved_to_id** (Number) The ID of the issue that was moved to. |
| 73 | +- **references** (Map of String) The references of the issue. |
| 74 | +- **state** (String) The state of the issue. Valid values are: `opened`, `closed`. |
| 75 | +- **subscribed** (Boolean) Whether the authenticated user is subscribed to the issue or not. |
| 76 | +- **task_completion_status** (List of Object) The task completion status. It's always a one element list. (see [below for nested schema](#nestedatt--task_completion_status)) |
| 77 | +- **time_estimate** (Number) The time estimate of the issue. |
| 78 | +- **title** (String) The title of the issue. |
| 79 | +- **total_time_spent** (Number) The total time spent of the issue. |
| 80 | +- **updated_at** (String) When the issue was updated. Date time string, ISO 8601 formatted, for example 2016-03-11T03:45:40Z. |
| 81 | +- **upvotes** (Number) The number of upvotes the issue has received. |
| 82 | +- **user_notes_count** (Number) The number of user notes on the issue. |
| 83 | +- **web_url** (String) The web URL of the issue. |
| 84 | +- **weight** (Number) The weight of the issue. Valid values are greater than or equal to 0. |
| 85 | + |
| 86 | +<a id="nestedatt--task_completion_status"></a> |
| 87 | +### Nested Schema for `task_completion_status` |
| 88 | + |
| 89 | +Read-Only: |
| 90 | + |
| 91 | +- **completed_count** (Number) |
| 92 | +- **count** (Number) |
| 93 | + |
| 94 | + |
0 commit comments