module Gitlab::Client::IssueLinks

def create_issue_link(project, issue, target_project_id, target_issue_iid)

Returns:
  • (Gitlab::ObjectifiedHash) - Information about created link.

Parameters:
  • target_issue_iid (Integer) -- The ID of the target issue.
  • target_project_id (Integer) -- Project ID the target issue is located in.
  • issue (Integer) -- The ID of an issue.
  • project (Integer, String) -- The ID or name of a project.
def create_issue_link(project, issue, target_project_id, target_issue_iid)
  post("/projects/#{url_encode project}/issues/#{issue}/links", body: { target_project_id: target_project_id, target_issue_iid: target_issue_iid })
end

def delete_issue_link(project, issue, id)

Returns:
  • (Gitlab::ObjectifiedHash) -

Parameters:
  • id (Integer) -- The ID of a link.
  • issue (Integer) -- The ID of an issue.
  • project (Integer) -- The ID of a project.
def delete_issue_link(project, issue, id)
  delete("/projects/#{url_encode project}/issues/#{issue}/links/#{id}")
end

def issue_links(project, issue, options = {})

Returns:
  • (Array) -

Options Hash: (**options)
  • :per_page (Integer) -- The number of results per page.
  • :page (Integer) -- The page number.

Parameters:
  • issue (Integer) -- The ID of an issue.
  • project (Integer) -- The ID of a project.
def issue_links(project, issue, options = {})
  get("/projects/#{url_encode project}/issues/#{issue}/links", query: options)
end