diff options
author | Gauvain Pocentek <gauvain@pocentek.net> | 2018-06-17 16:20:50 +0200 |
---|---|---|
committer | Gauvain Pocentek <gauvain@pocentek.net> | 2018-06-17 16:20:50 +0200 |
commit | ba90e305bc2d54eb42aa0f8251a9e45b0d1736e4 (patch) | |
tree | 7c220ff08ba92f203a0adf92b26633c6ba4f675a /docs | |
parent | b2cb70016e4fd2baa1f136a17946a474f1b18f24 (diff) | |
download | gitlab-ba90e305bc2d54eb42aa0f8251a9e45b0d1736e4.tar.gz |
Add support for epics API (EE)
Fixes #525
Diffstat (limited to 'docs')
-rw-r--r-- | docs/api-objects.rst | 1 | ||||
-rw-r--r-- | docs/gl_objects/epics.rst | 79 |
2 files changed, 80 insertions, 0 deletions
diff --git a/docs/api-objects.rst b/docs/api-objects.rst index 4e7961d..0cc5014 100644 --- a/docs/api-objects.rst +++ b/docs/api-objects.rst @@ -18,6 +18,7 @@ API examples gl_objects/discussions gl_objects/environments gl_objects/events + gl_objects/epics gl_objects/features gl_objects/geo_nodes gl_objects/groups diff --git a/docs/gl_objects/epics.rst b/docs/gl_objects/epics.rst new file mode 100644 index 0000000..2b1e23e --- /dev/null +++ b/docs/gl_objects/epics.rst @@ -0,0 +1,79 @@ +##### +Epics +##### + +Epics +===== + +Reference +--------- + +* v4 API: + + + :class:`gitlab.v4.objects.GroupEpic` + + :class:`gitlab.v4.objects.GroupEpicManager` + + :attr:`gitlab.Gitlab.Group.epics` + +* GitLab API: https://docs.gitlab.com/ee/api/epics.html (EE feature) + +Examples +-------- + +List the epics for a group:: + + epics = groups.epics.list() + +Get a single epic for a group:: + + epic = group.epics.get(epic_iid) + +Create an epic for a group:: + + epic = group.epics.create({'title': 'My Epic'}) + +Edit an epic:: + + epic.title = 'New title' + epic.labels = ['label1', 'label2'] + epic.save() + +Delete an epic:: + + epic.delete() + +Epics issues +============ + +Reference +--------- + +* v4 API: + + + :class:`gitlab.v4.objects.GroupEpicIssue` + + :class:`gitlab.v4.objects.GroupEpicIssueManager` + + :attr:`gitlab.Gitlab.GroupEpic.issues` + +* GitLab API: https://docs.gitlab.com/ee/api/epic_issues.html (EE feature) + +Examples +-------- + +List the issues associated with an issue:: + + ei = epic.issues.list() + +Associate an issue with an epic:: + + # use the issue id, not its iid + ei = epic.issues.create({'issue_id': 4}) + +Move an issue in the list:: + + ei.move_before_id = epic_issue_id_1 + # or + ei.move_after_id = epic_issue_id_2 + ei.save() + +Delete an issue association:: + + ei.delete() |