에픽 API

Tier: Premium, Ultimate Offering: GitLab.com, Self-managed, GitLab Dedicated

에픽에 대한 모든 API 호출은 인증되어야 합니다.

비공개 그룹의 멤버가 아닌 경우, 해당 그룹에 대한 GET 요청은 404 상태 코드를 반환합니다.

에픽 기능을 사용할 수 없는 경우 403 상태 코드가 반환됩니다.

에픽 이슈 API

에픽 이슈 API를 사용하면 에픽과 관련된 이슈와 상호 작용할 수 있습니다.

마일스톤 날짜 통합

  • GitLab 11.3에서 소개되었습니다.

시작 날짜와 마감 날짜는 관련된 이슈 마일스톤에서 동적으로 가져올 수 있기 때문에 사용자에게 편집 권한이 부여될 때 추가 필드가 표시됩니다. 이러한 필드에는 두 개의 부울 필드 start_date_is_fixeddue_date_is_fixed, 그리고 네 개의 날짜 필드 start_date_fixed, start_date_from_inherited_source, due_date_fixeddue_date_from_inherited_source가 포함됩니다.

  • end_datedue_date로 대체되었습니다.
  • start_date_from_milestonesstart_date_from_inherited_source로 대체되었습니다.
  • due_date_from_milestonesdue_date_from_inherited_source로 대체되었습니다.

에픽 분할

기본적으로 GET 요청은 API 결과를 페이지로 나눠 20개씩 반환합니다.

자세한 내용은 페이지네이션을 참조하세요.

caution
GitLab 12.6 이후, 응답에서 reference 속성은 references로 대체되었습니다.
note
references.relative는 요청한 에픽의 원본 그룹을 기준으로 상대적입니다. 에픽이 원본 그룹에서 가져올 때 relative 형식은 short 형식과 동일합니다. 그러나 에픽이 그룹 간에 요청되는 경우, relative 형식은 full 형식과 동일하다고 예상됩니다.

그룹의 에픽 디렉터리

응답의 parent_iid_links[parent]GitLab 14.6에서 소개되었습니다.

요청한 그룹과 해당 서브 그룹의 모든 에픽을 가져옵니다.

GET /groups/:id/epics
GET /groups/:id/epics?author_id=5
GET /groups/:id/epics?labels=bug,reproduced
GET /groups/:id/epics?state=opened
속성 유형 필수여부 설명
id 정수/문자열 인증된 사용자가 소유한 그룹의 ID 또는 URL-인코딩된 경로
author_id 정수 아니요 지정된 사용자 id로 생성된 에픽을 반환합니다.
author_username 문자열 아니요 주어진 username을 가진 사용자에 의해 생성된 에픽을 반환합니다. GitLab 14.7부터 사용 가능
labels 문자열 아니요 쉼표로 구분된 라벨 이름 디렉터리과 일치하는 에픽을 반환합니다. 에픽 그룹이나 상위 그룹의 라벨 이름을 사용할 수 있습니다.
with_labels_details 부울 아니요 true인 경우 응답은 labels 필드의 각 라벨에 대한 자세한 정보를 반환합니다: :name, :color, :description, :description_html, :text_color. 기본값은 false입니다. GitLab 12.7 이후 사용 가능
order_by 문자열 아니요 에픽을 created_at, updated_at, 또는 title 필드로 정렬해서 반환합니다. 기본값은 created_at입니다.
sort 문자열 아니요 에픽을 asc 또는 desc 순서로 정렬해서 반환합니다. 기본값은 desc입니다.
search 문자열 아니요 에픽을 titledescription에 대해 검색합니다.
state 문자열 아니요 에픽을 상태에 따라 검색합니다. 가능한 필터: opened, closed, all. 기본값은 all입니다.
created_after 날짜 및 시간 아니요 주어진 시간 이후로 생성된 에픽을 반환합니다. ISO 8601 형식으로 입력하세요 (2019-03-15T08:00:00Z)
created_before 날짜 및 시간 아니요 주어진 시간 이전에 생성된 에픽을 반환합니다. ISO 8601 형식으로 입력하세요 (2019-03-15T08:00:00Z)
updated_after 날짜 및 시간 아니요 주어진 시간 이후로 업데이트된 에픽을 반환합니다. ISO 8601 형식으로 입력하세요 (2019-03-15T08:00:00Z)
updated_before 날짜 및 시간 아니요 주어진 시간 이전에 업데이트된 에픽을 반환합니다. ISO 8601 형식으로 입력하세요 (2019-03-15T08:00:00Z)
include_ancestor_groups 부울 아니요 요청된 그룹의 상위 그룹에서 에픽을 포함시킵니다. 기본값은 false입니다.
include_descendant_groups 부울 아니요 요청된 그룹의 하위 그룹에서 에픽을 포함시킵니다. 기본값은 true입니다.
my_reaction_emoji 문자열 아니요 지정된 이모지로 인증된 사용자가 반응한 에픽을 반환합니다. None은 반응하지 않은 에픽을, Any는 하나 이상의 반응이 있는 에픽을 반환합니다. GitLab 13.0부터 사용 가능
not 해시 아니요 제공된 매개변수와 일치하지 않는 에픽을 반환합니다. author_id, author_username (GitLab 14.7 이후) 및 labels를 사용하세요. GitLab 14.6 이후 사용 가능
curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics"

응답 예시:

[
  {
  "id": 29,
  "iid": 4,
  "group_id": 7,
  "parent_id": 23,
  "parent_iid": 3,
  "title": "Accusamus iste et ullam ratione voluptatem omnis debitis dolor est.",
  "description": "Molestias dolorem eos vitae expedita impedit necessitatibus quo voluptatum.",
  "state": "opened",
  "confidential": "false",
  "web_url": "http://gitlab.example.com/groups/test/-/epics/4",
  "reference": "&4",
  "references": {
    "short": "&4",
    "relative": "&4",
    "full": "test&4"
  },
  "author": {
    "id": 10,
    "name": "Lu Mayer",
    "username": "kam",
    "state": "active",
    "avatar_url": "http://www.gravatar.com/avatar/018729e129a6f31c80a6327a30196823?s=80&d=identicon",
    "web_url": "http://gitlab.example.com/kam"
  },
  "start_date": null,
  "start_date_is_fixed ": false,
  "start_date_fixed": null,
  "start_date_from_milestones": null,       // start_date_from_inherited_source로 대체됨
  "start_date_from_inherited_source": null,
  "end_date": "2018-07-31",                 // due_date로 대체됨
  "due_date": "2018-07-31",
  "due_date_is_fixed": false,
  "due_date_fixed": null,
  "due_date_from_milestones": "2018-07-31", // start_date_from_inherited_source로 대체됨
  "due_date_from_inherited_source": "2018-07-31",
  "created_at": "2018-07-17T13:36:22.770Z",
  "updated_at": "2018-07-18T12:22:05.239Z",
  "closed_at": "2018-08-18T12:22:05.239Z",
  "labels": [],
  "upvotes": 4,
  "downvotes": 0,
  "color": "#1068bf",
  "_links":{
      "self": "http://gitlab.example.com/api/v4/groups/7/epics/4",
      "epic_issues ": "http://gitlab.example.com/api/v4/groups/7/epics/4/issues",
      "group":"http://gitlab.example.com/api/v4/groups/7",
      "parent":"http://gitlab.example.com/api/v4/groups/7/epics/3"
  }
  },
  {
  "id": 50,
  "iid": 35,
  "group_id": 17,
  "parent_id": 19,
  "parent_iid": 1,
  "title": "Accusamus iste et ullam ratione voluptatem omnis debitis dolor est.",
  "description": "Molestias dolorem eos vitae expedita impedit necessitatibus quo voluptatum.",
  "state": "opened",
  "web_url": "http://gitlab.example.com/groups/test/sample/-/epics/35",
  "reference": "&4",
  "references": {
    "short": "&4",
    "relative": "sample&4",
    "full": "test/sample&4"
  },
  "author": {
    "id": 10,
    "name": "Lu Mayer",
    "username": "kam",
    "state": "active",
    "avatar_url": "http://www.gravatar.com/avatar/018729e129a6f31c80a6327a30196823?s=80&d=identicon",
    "web_url": "http://gitlab.example.com/kam"
  },
  "start_date": null,
  "start_date_is_fixed ": false,
  "start_date_fixed": null,
  "start_date_from_milestones": null,       // start_date_from_inherited_source로 대체됨
  "start_date_from_inherited_source": null,
  "end_date": "2018-07-31",                 // due_date로 대체됨
  "due_date": "2018-07-31",
  "due_date_is_fixed": false,
  "due_date_fixed": null,
  "due_date_from_milestones": "2018-07-31", // start_date_from_inherited_source로 대체됨
  "due_date_from_inherited_source": "2018-07-31",
  "created_at": "2018-07-17T13:36:22.770Z",
  "updated_at": "2018-07-18T12:22:05.239Z",
  "closed_at": "2018-08-18T12:22:05.239Z",
  "labels": [],
  "upvotes": 4,
  "downvotes": 0,
  "color": "#1068bf",
  "_links":{
      "self": "http://gitlab.example.com/api/v4/groups/17/epics/35",
      "epic_issues ": "http://gitlab.example.com/api/v4/groups/17/epics/35/issues",
      "group":"http://gitlab.example.com/api/v4/groups/17",
      "parent":"http://gitlab.example.com/api/v4/groups/17/epics/1"
  }
  }
]

Single epic

  • 응답의 parent_iid_links[parent]는 GitLab 14.6에서 소개되었습니다.

단일 epic 가져오기

GET /groups/:id/epics/:epic_iid
속성 유형 필수 여부 설명
id 정수/문자열 인증된 사용자가 소유한 그룹의 ID 또는 URL-인코딩된 경로
epic_iid 정수/문자열 epic의 내부 ID입니다.
curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics/5"

응답 예시:

{
  "id": 30,
  "iid": 5,
  "group_id": 7,
  "parent_id": null,
  "parent_iid": null,
  "title": "Ea cupiditate dolores ut vero consequatur quasi veniam voluptatem et non.",
  "description": "Molestias dolorem eos vitae expedita impedit necessitatibus quo voluptatum.",
  "state": "opened",
  "web_url": "http://gitlab.example.com/groups/test/-/epics/5",
  "reference": "&5",
  "references": {
    "short": "&5",
    "relative": "&5",
    "full": "test&5"
  },
  "author":{
    "id": 7,
    "name": "Pamella Huel",
    "username": "arnita",
    "state": "active",
    "avatar_url": "http://www.gravatar.com/avatar/a2f5c6fcef64c9c69cb8779cb292be1b?s=80&d=identicon",
    "web_url": "http://gitlab.example.com/arnita"
  },
  "start_date": null,
  "start_date_is_fixed": false,
  "start_date_fixed": null,
  "start_date_from_milestones": null,       //deprecated in favor of start_date_from_inherited_source
  "start_date_from_inherited_source": null,
  "end_date": "2018-07-31",                 //deprecated in favor of due_date
  "due_date": "2018-07-31",
  "due_date_is_fixed": false,
  "due_date_fixed": null,
  "due_date_from_milestones": "2018-07-31", //deprecated in favor of start_date_from_inherited_source
  "due_date_from_inherited_source": "2018-07-31",
  "created_at": "2018-07-17T13:36:22.770Z",
  "updated_at": "2018-07-18T12:22:05.239Z",
  "closed_at": "2018-08-18T12:22:05.239Z",
  "labels": [],
  "upvotes": 4,
  "downvotes": 0,
  "color": "#1068bf",
  "subscribed": true,
  "_links":{
      "self": "http://gitlab.example.com/api/v4/groups/7/epics/5",
      "epic_issues": "http://gitlab.example.com/api/v4/groups/7/epics/5/issues",
      "group":"http://gitlab.example.com/api/v4/groups/7",
      "parent": null
  }
}

New epic

  • 응답의 parent_iid_links[parent]는 GitLab 14.6에서 소개되었습니다.

새로운 epic 생성

note
GitLab 11.3부터 start_dateend_date는 더 이상 직접 할당되지 않으며 이제 복합 값으로 나타냅니다. 대신 *_is_fixed*_fixed 필드를 통해 구성할 수 있습니다.
POST /groups/:id/epics
속성 유형 필수 여부 설명
id 정수/문자열 인증된 사용자가 소유한 그룹의 ID 또는 URL-인코딩된 경로
title 문자열 epic의 제목
labels 문자열 아니오 라벨의 쉼표로 구분된 디렉터리
description 문자열 아니오 epic의 설명. 1,048,576자로 제한됨.
color 문자열 아니오 epic의 색상. 기본적으로 비활성화된 epic_highlight_color이름의 피처 플래그(기본 설정)으로 소개되었습니다.
confidential 부울 값 아니오 epic을 비밀로 처리해야 하는지 여부
created_at 문자열 아니오 epic이 생성된 날짜 및 시간. 날짜 및 시간 문자열, ISO 8601 형식, 예: 2016-03-11T03:45:40Z . 관리자 또는 프로젝트/그룹 소유자 권한이 필요함 (사용 가능한 GitLab 13.5 이상)
start_date_is_fixed 부울 값 아니오 시작 날짜를 start_date_fixed 또는 마일스톤에서 소스로 가져와야 하는지 여부 (GitLab 11.3 이상)
start_date_fixed 문자열 아니오 epic의 고정된 시작 날짜 (GitLab 11.3 이상)
due_date_is_fixed 부울 값 아니오 완료 날짜를 due_date_fixed 또는 마일스톤에서 소스로 가져와야 하는지 여부 (GitLab 11.3 이상)
due_date_fixed 문자열 아니오 epic의 고정된 완료 날짜 (GitLab 11.3 이상)
parent_id 정수/문자열 아니오 부모 epic의 ID (GitLab 11.11 이상)
curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics?title=Epic&description=Epic%20description&parent_id=29"

응답 예시:

{
  "id": 33,
  "iid": 6,
  "group_id": 7,
  "parent_id": 29,
  "parent_iid": 4,
  "title": "Epic",
  "description": "Epic description",
  "state": "opened",
  "confidential": "false",
  "web_url": "http://gitlab.example.com/groups/test/-/epics/6",
  "reference": "&6",
  "references": {
    "short": "&6",
    "relative": "&6",
    "full": "test&6"
  },
  "author": {
    "name" : "Alexandra Bashirian",
    "avatar_url" : null,
    "state" : "active",
    "web_url" : "https://gitlab.example.com/eileen.lowe",
    "id" : 18,
    "username" : "eileen.lowe"
  },
  "start_date": null,
  "start_date_is_fixed": false,
  "start_date_fixed": null,
  "start_date_from_milestones": null,       //deprecated in favor of start_date_from_inherited_source
  "start_date_from_inherited_source": null,
  "end_date": "2018-07-31",                 //deprecated in favor of due_date
  "due_date": "2018-07-31",
  "due_date_is_fixed": false,
  "due_date_fixed": null,
  "due_date_from_milestones": "2018-07-31", //deprecated in favor of start_date_from_inherited_source
  "due_date_from_inherited_source": "2018-07-31",
  "created_at": "2018-07-17T13:36:22.770Z",
  "updated_at": "2018-07-18T12:22:05.239Z",
  "closed_at": "2018-08-18T12:22:05.239Z",
  "labels": [],
  "upvotes": 4,
  "downvotes": 0,
  "color": "#1068bf",
  "_links":{
    "self": "http://gitlab.example.com/api/v4/groups/7/epics/6",
    "epic_issues": "http://gitlab.example.com/api/v4/groups/7/epics/6/issues",
    "group":"http://gitlab.example.com/api/v4/groups/7",
    "parent": "http://gitlab.example.com/api/v4/groups/7/epics/4"
  }
}

Epic 업데이트

  • 응답의 parent_iid_links[parent]GitLab 14.6에서 도입되었습니다.

Epic을 업데이트합니다.

note
GitLab 11.3부터 start_dateend_date는 이제 합성 값으로 나타내므로 직접 할당되지 않아야 합니다. 대신 *_is_fixed*_fixed 필드를 통해 구성할 수 있습니다.
PUT /groups/:id/epics/:epic_iid
속성 유형 필수 여부 설명
id integer/string yes 인증된 사용자가 소유한 그룹의 ID 또는 URL-encoded path
epic_iid integer/string yes Epic의 내부 ID
add_labels string no 이슈에 추가할 쉼표로 구분된 라벨 이름
confidential boolean no Epic이 비공개여부
description string no Epic의 설명. 1,048,576자로 제한됨.
due_date_fixed string no Epic의 고정된 마감일 (GitLab 11.3 이상)
due_date_is_fixed boolean no 마감일은 due_date_fixed에서 지정되어야 하는지 또는 마일스톤에서 가져와야 하는지 (GitLab 11.3 이상)
labels string no 이슈를 위한 쉼표로 구분된 라벨 이름. 모든 라벨을 해제하려면 빈 문자열로 설정하세요.
parent_id integer/string no 상위 Epic의 ID. GitLab 14.6 이상에서 사용 가능
remove_labels string no 이슈에서 제거할 쉼표로 구분된 라벨 이름
start_date_fixed string no Epic의 고정된 시작일 (GitLab 11.3 이상)
start_date_is_fixed boolean no 시작일은 start_date_fixed에서 지정되어야 하는지 또는 마일스톤에서 가져와야 하는지 (GitLab 11.3 이상)
state_event string no Epic의 상태 이벤트. Epic을 닫으려면 close로 설정하고 다시 열려면 reopen으로 설정하세요 (GitLab 11.4 이상)
title string no Epic의 제목
updated_at string no Epic을 업데이트한 시간. ISO 8601 형식의 날짜 및 시간 문자열, 예: 2016-03-11T03:45:40Z. 관리자 또는 프로젝트/그룹 소유자 권한이 필요합니다 (사용 가능한 것은 GitLab 13.5 이상)
color string no Epic의 색상. 피처 플래그인 epic_highlight_color (기본값: 비활성화)로 도입됨 (GitLab 14.8)
curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics/5?title=New%20Title&parent_id=29"

예시 응답:

{
  "id": 33,
  "iid": 6,
  "group_id": 7,
  "parent_id": 29,
  "parent_iid": 4,
  "title": "New Title",
  "description": "Epic description",
  "state": "opened",
  "confidential": "false",
  "web_url": "http://gitlab.example.com/groups/test/-/epics/6",
  "reference": "&6",
  "references": {
    "short": "&6",
    "relative": "&6",
    "full": "test&6"
  },
  "author": {
    "name" : "Alexandra Bashirian",
    "avatar_url" : null,
    "state" : "active",
    "web_url" : "https://gitlab.example.com/eileen.lowe",
    "id" : 18,
    "username" : "eileen.lowe"
  },
  "start_date": null,
  "start_date_is_fixed": false,
  "start_date_fixed": null,
  "start_date_from_milestones": null,       // start_date_from_inherited_source로 대체됨
  "start_date_from_inherited_source": null,
  "end_date": "2018-07-31",                 // due_date로 대체됨
  "due_date": "2018-07-31",
  "due_date_is_fixed": false,
  "due_date_fixed": null,
  "due_date_from_milestones": "2018-07-31", // start_date_from_inherited_source로 대체됨
  "due_date_from_inherited_source": "2018-07-31",
  "created_at": "2018-07-17T13:36:22.770Z",
  "updated_at": "2018-07-18T12:22:05.239Z",
  "closed_at": "2018-08-18T12:22:05.239Z",
  "labels": [],
  "upvotes": 4,
  "downvotes": 0,
  "color": "#1068bf"
}

Epic 삭제

Epic을 삭제합니다.

DELETE /groups/:id/epics/:epic_iid
속성 유형 필수 여부 설명
id integer/string yes 인증된 사용자가 소유한 그룹의 ID 또는 URL-encoded path
epic_iid integer/string yes Epic의 내부 ID.
curl --request DELETE --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics/5"

할 일 항목 생성

현재 사용자의 epic에 대해 매뉴얼으로 할 일 항목을 생성합니다. 해당 epic에 이미 사용자의 할 일 항목이 있는 경우 304 상태 코드가 반환됩니다.

POST /groups/:id/epics/:epic_iid/todo
속성 유형 필수 여부 설명
id 정수/문자열 인증된 사용자가 소유한 그룹의 ID 또는 URL-인코딩된 경로
epic_iid 정수 그룹 epic의 내부 ID
curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/epics/5/todo"

예시 응답:

{
  "id": 112,
  "group": {
    "id": 1,
    "name": "Gitlab",
    "path": "gitlab",
    "kind": "group",
    "full_path": "base/gitlab",
    "parent_id": null
  },
  "author": {
    "name": "Administrator",
    "username": "root",
    "id": 1,
    "state": "active",
    "avatar_url": "http://www.gravatar.com/avatar/e64c7d89f26bd1972efa854d13d7dd61?s=80&d=identicon",
    "web_url": "https://gitlab.example.com/root"
  },
  "action_name": "marked",
  "target_type": "epic",
  "target": {
    "id": 30,
    "iid": 5,
    "group_id": 1,
    "title": "Ea cupiditate dolores ut vero consequatur quasi veniam voluptatem et non.",
    "description": "Molestias dolorem eos vitae expedita impedit necessitatibus quo voluptatum.",
    "author":{
      "id": 7,
      "name": "Pamella Huel",
      "username": "arnita",
      "state": "active",
      "avatar_url": "http://www.gravatar.com/avatar/a2f5c6fcef64c9c69cb8779cb292be1b?s=80&d=identicon",
      "web_url": "http://gitlab.example.com/arnita"
    },
    "web_url": "http://gitlab.example.com/groups/test/-/epics/5",
    "reference": "&5",
    "references": {
      "short": "&5",
      "relative": "&5",
      "full": "test&5"
    },
    "start_date": null,
    "end_date": null,
    "created_at": "2018-01-21T06:21:13.165Z",
    "updated_at": "2018-01-22T12:41:41.166Z",
    "closed_at": "2018-08-18T12:22:05.239Z"
  },
  "target_url": "https://gitlab.example.com/groups/epics/5",
  "body": "Vel voluptas atque dicta mollitia adipisci qui at.",
  "state": "pending",
  "created_at": "2016-07-01T11:09:13.992Z"
}