Method: Github::Client::Issues#create

Defined in:
lib/github_api/client/issues.rb

#create(*args) ⇒ Object

Create an issue

Examples:

github = Github.new user: 'user-name', repo: 'repo-name'
github.issues.create
  title: "Found a bug",
  body: "I'm having a problem with this.",
  assignee: "octocat",
  milestone: 1,
  labels: [
    "Label1",
    "Label2"
  ]

Parameters:



200
201
202
203
204
205
206
207
# File 'lib/github_api/client/issues.rb', line 200

def create(*args)
  arguments(args, required: [:user, :repo]) do
    permit VALID_ISSUE_PARAM_NAMES
    assert_required %w[ title ]
  end

  post_request("/repos/#{arguments.user}/#{arguments.repo}/issues", arguments.params)
end