package github

  1. Overview
  2. Docs

The Issue module gives users access to GitHub's issue API.

val for_repo : ?token:Token.t -> ?creator:string -> ?mentioned:string -> ?assignee:Filter.user -> ?labels:string list -> ?milestone:Filter.milestone -> ?state:Filter.state -> ?sort:Filter.issue_sort -> ?direction:Filter.direction -> user:string -> repo:string -> unit -> Github_t.issue Stream.t

for_repo ?creator ?mentioned ?assignee ?labels ?milestone ?state ?sort ?direction ~user ~repo () is a stream of issues in repo user/repo which were created by user ?creator, mention user ?mentioned, are assigned to user ?assignee, have labels ?labels, are included in milestone ?milestone, and are in state ?state. The stream is sorted by ?sort (default `Created) and ordered by ?direction (default `Desc).

val create : ?token:Token.t -> user:string -> repo:string -> issue:Github_t.new_issue -> unit -> Github_t.issue Response.t Monad.t

create ~user ~repo ~issue () is a newly created issue described by issue in repo user/repo.

val update : ?token:Token.t -> user:string -> repo:string -> num:int -> issue:Github_t.new_issue -> unit -> Github_t.issue Response.t Monad.t

update ~user ~repo ~num ~issue () is the updated issue num in user/repo as described by issue.

val comments : ?token:Token.t -> user:string -> repo:string -> num:int -> unit -> Github_t.issue_comment Stream.t

comments ~user ~repo ~num () is a stream of issue comments for user/repo#num.

val create_comment : ?token:Token.t -> user:string -> repo:string -> num:int -> body:string -> unit -> Github_t.issue_comment Response.t Monad.t

create_comment ~user ~repo ~num ~body () is a newly created issue comment on user/repo#num with content body.

val is_issue : Github_t.issue -> bool

is_issue issue is true if issue is an actual issue and not a pull request.

val is_pull : Github_t.issue -> bool

is_pull issue is true if issue is a pull request.

OCaml

Innovation. Community. Security.