View Source GitHub.Issues (GitHub REST API Client v0.0.9)

Provides API endpoints related to issues

Link to this section Summary

Functions

List issues assigned to the authenticated user

List issue comments for a repository

List issue events for a repository

List user account issues assigned to the authenticated user

List organization issues assigned to the authenticated user

List labels for a repository

Link to this section Functions

Link to this function

add_assignees(owner, repo, issue_number, body, opts \\ [])

View Source
@spec add_assignees(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Issue.t()} | {:error, GitHub.Error.t()}

Add assignees to an issue

resources

Resources

Link to this function

add_labels(owner, repo, issue_number, body, opts \\ [])

View Source
@spec add_labels(
  String.t(),
  String.t(),
  integer(),
  map() | String.t() | [map()] | [String.t()],
  keyword()
) :: {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

Add labels to an issue

resources

Resources

Link to this function

check_user_can_be_assigned(owner, repo, assignee, opts \\ [])

View Source
@spec check_user_can_be_assigned(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Check if a user can be assigned

resources

Resources

Link to this function

check_user_can_be_assigned_to_issue(owner, repo, issue_number, assignee, opts \\ [])

View Source
@spec check_user_can_be_assigned_to_issue(
  String.t(),
  String.t(),
  integer(),
  String.t(),
  keyword()
) ::
  :ok | {:error, GitHub.Error.t()}

Check if a user can be assigned to a issue

resources

Resources

Link to this function

create(owner, repo, body, opts \\ [])

View Source
@spec create(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Issue.t()} | {:error, GitHub.Error.t()}

Create an issue

resources

Resources

Link to this function

create_comment(owner, repo, issue_number, body, opts \\ [])

View Source
@spec create_comment(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Issue.Comment.t()} | {:error, GitHub.Error.t()}

Create an issue comment

resources

Resources

Link to this function

create_label(owner, repo, body, opts \\ [])

View Source
@spec create_label(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Label.t()} | {:error, GitHub.Error.t()}

Create a label

resources

Resources

Link to this function

create_milestone(owner, repo, body, opts \\ [])

View Source
@spec create_milestone(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Milestone.t()} | {:error, GitHub.Error.t()}

Create a milestone

resources

Resources

Link to this function

delete_comment(owner, repo, comment_id, opts \\ [])

View Source
@spec delete_comment(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete an issue comment

resources

Resources

Link to this function

delete_label(owner, repo, name, opts \\ [])

View Source
@spec delete_label(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a label

resources

Resources

Link to this function

delete_milestone(owner, repo, milestone_number, opts \\ [])

View Source
@spec delete_milestone(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a milestone

resources

Resources

Link to this function

get(owner, repo, issue_number, opts \\ [])

View Source
@spec get(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Issue.t()} | {:error, GitHub.Error.t()}

Get an issue

resources

Resources

Link to this function

get_comment(owner, repo, comment_id, opts \\ [])

View Source
@spec get_comment(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Issue.Comment.t()} | {:error, GitHub.Error.t()}

Get an issue comment

resources

Resources

Link to this function

get_event(owner, repo, event_id, opts \\ [])

View Source
@spec get_event(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Issue.Event.t()} | {:error, GitHub.Error.t()}

Get an issue event

resources

Resources

Link to this function

get_label(owner, repo, name, opts \\ [])

View Source
@spec get_label(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Label.t()} | {:error, GitHub.Error.t()}

Get a label

resources

Resources

Link to this function

get_milestone(owner, repo, milestone_number, opts \\ [])

View Source
@spec get_milestone(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Milestone.t()} | {:error, GitHub.Error.t()}

Get a milestone

resources

Resources

@spec list(keyword()) :: {:ok, [GitHub.Issue.t()]} | {:error, GitHub.Error.t()}

List issues assigned to the authenticated user

options

Options

  • filter (String.t()): Indicates which sorts of issues to return. assigned means issues assigned to you. created means issues created by you. mentioned means issues mentioning you. subscribed means issues you're subscribed to updates for. all or repos means all issues you can see, regardless of participation or creation.
  • state (String.t()): Indicates the state of the issues to return.
  • labels (String.t()): A list of comma separated label names. Example: bug,ui,@high
  • sort (String.t()): What to sort results by.
  • direction (String.t()): The direction to sort the results by.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • collab (boolean):
  • orgs (boolean):
  • owned (boolean):
  • pulls (boolean):
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_assignees(owner, repo, opts \\ [])

View Source
@spec list_assignees(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.User.simple()]} | {:error, GitHub.Error.t()}

List assignees

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_comments(owner, repo, issue_number, opts \\ [])

View Source
@spec list_comments(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Issue.Comment.t()]} | {:error, GitHub.Error.t()}

List issue comments

options

Options

  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_comments_for_repo(owner, repo, opts \\ [])

View Source
@spec list_comments_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Issue.Comment.t()]} | {:error, GitHub.Error.t()}

List issue comments for a repository

options

Options

  • sort (String.t()): The property to sort the results by.
  • direction (String.t()): Either asc or desc. Ignored without the sort parameter.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_events(owner, repo, issue_number, opts \\ [])

View Source

List issue events

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_events_for_repo(owner, repo, opts \\ [])

View Source
@spec list_events_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Issue.Event.t()]} | {:error, GitHub.Error.t()}

List issue events for a repository

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_events_for_timeline(owner, repo, issue_number, opts \\ [])

View Source

List timeline events for an issue

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_for_authenticated_user(opts \\ [])

View Source
@spec list_for_authenticated_user(keyword()) ::
  {:ok, [GitHub.Issue.t()]} | {:error, GitHub.Error.t()}

List user account issues assigned to the authenticated user

options

Options

  • filter (String.t()): Indicates which sorts of issues to return. assigned means issues assigned to you. created means issues created by you. mentioned means issues mentioning you. subscribed means issues you're subscribed to updates for. all or repos means all issues you can see, regardless of participation or creation.
  • state (String.t()): Indicates the state of the issues to return.
  • labels (String.t()): A list of comma separated label names. Example: bug,ui,@high
  • sort (String.t()): What to sort results by.
  • direction (String.t()): The direction to sort the results by.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_for_org(org, opts \\ [])

View Source
@spec list_for_org(
  String.t(),
  keyword()
) :: {:ok, [GitHub.Issue.t()]} | {:error, GitHub.Error.t()}

List organization issues assigned to the authenticated user

options

Options

  • filter (String.t()): Indicates which sorts of issues to return. assigned means issues assigned to you. created means issues created by you. mentioned means issues mentioning you. subscribed means issues you're subscribed to updates for. all or repos means all issues you can see, regardless of participation or creation.
  • state (String.t()): Indicates the state of the issues to return.
  • labels (String.t()): A list of comma separated label names. Example: bug,ui,@high
  • sort (String.t()): What to sort results by.
  • direction (String.t()): The direction to sort the results by.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_for_repo(owner, repo, opts \\ [])

View Source
@spec list_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Issue.t()]} | {:error, GitHub.Error.t()}

List repository issues

options

Options

  • milestone (String.t()): If an integer is passed, it should refer to a milestone by its number field. If the string * is passed, issues with any milestone are accepted. If the string none is passed, issues without milestones are returned.
  • state (String.t()): Indicates the state of the issues to return.
  • assignee (String.t()): Can be the name of a user. Pass in none for issues with no assigned user, and * for issues assigned to any user.
  • creator (String.t()): The user that created the issue.
  • mentioned (String.t()): A user that's mentioned in the issue.
  • labels (String.t()): A list of comma separated label names. Example: bug,ui,@high
  • sort (String.t()): What to sort results by.
  • direction (String.t()): The direction to sort the results by.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_labels_for_milestone(owner, repo, milestone_number, opts \\ [])

View Source
@spec list_labels_for_milestone(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

List labels for issues in a milestone

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_labels_for_repo(owner, repo, opts \\ [])

View Source
@spec list_labels_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

List labels for a repository

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_labels_on_issue(owner, repo, issue_number, opts \\ [])

View Source
@spec list_labels_on_issue(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

List labels for an issue

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_milestones(owner, repo, opts \\ [])

View Source
@spec list_milestones(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Milestone.t()]} | {:error, GitHub.Error.t()}

List milestones

options

Options

  • state (String.t()): The state of the milestone. Either open, closed, or all.
  • sort (String.t()): What to sort results by. Either due_on or completeness.
  • direction (String.t()): The direction of the sort. Either asc or desc.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

lock(owner, repo, issue_number, body, opts \\ [])

View Source
@spec lock(String.t(), String.t(), integer(), map() | nil, keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Lock an issue

resources

Resources

Link to this function

remove_all_labels(owner, repo, issue_number, opts \\ [])

View Source
@spec remove_all_labels(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Remove all labels from an issue

resources

Resources

Link to this function

remove_assignees(owner, repo, issue_number, body, opts \\ [])

View Source
@spec remove_assignees(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Issue.t()} | {:error, GitHub.Error.t()}

Remove assignees from an issue

resources

Resources

Link to this function

remove_label(owner, repo, issue_number, name, opts \\ [])

View Source
@spec remove_label(String.t(), String.t(), integer(), String.t(), keyword()) ::
  {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

Remove a label from an issue

resources

Resources

Link to this function

set_labels(owner, repo, issue_number, body, opts \\ [])

View Source
@spec set_labels(
  String.t(),
  String.t(),
  integer(),
  map() | String.t() | [map()] | [String.t()],
  keyword()
) :: {:ok, [GitHub.Label.t()]} | {:error, GitHub.Error.t()}

Set labels for an issue

resources

Resources

Link to this function

unlock(owner, repo, issue_number, opts \\ [])

View Source
@spec unlock(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Unlock an issue

resources

Resources

Link to this function

update(owner, repo, issue_number, body, opts \\ [])

View Source
@spec update(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Issue.t()} | {:error, GitHub.Error.t()}

Update an issue

resources

Resources

Link to this function

update_comment(owner, repo, comment_id, body, opts \\ [])

View Source
@spec update_comment(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Issue.Comment.t()} | {:error, GitHub.Error.t()}

Update an issue comment

resources

Resources

Link to this function

update_label(owner, repo, name, body, opts \\ [])

View Source
@spec update_label(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Label.t()} | {:error, GitHub.Error.t()}

Update a label

resources

Resources

Link to this function

update_milestone(owner, repo, milestone_number, body, opts \\ [])

View Source
@spec update_milestone(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Milestone.t()} | {:error, GitHub.Error.t()}

Update a milestone

resources

Resources