anchor.diff:           pull_req_comments/3,
            %% Users
            user/1,
  -         current_user_repos/2,
  -         current_user_orgs/1,
            repos/2,
  -         org_repos/2,
  +         repos/3,
  +         orgs/1,
  +         orgs/2,
  +         org_repos/3,
            %% Hooks
            hooks/2,
            create_webhook/4,
  
positive.code:     | {oauth, Token :: string()}.
  -type repository() :: string(). %% "username/reponame"
  -type result() :: ok | {ok, any()} | {error, term()}.
  
  -type endpoint() ::
      {pull_req, comments | files}
      | raw_contents.
  
  -define(GITHUB_API, "https://api.github.com").
  
  
negative.code:     Url = make_url(user, {}),
      api_call_json_result(Cred, Url).
  
  -spec orgs(credentials()) -> string().
  orgs(Cred) ->
      orgs(Cred, undefined).
  
  -spec orgs(credentials(), string()) -> string().
  orgs(Cred, User) ->
      Url = make_url(orgs, {User}),
      api_call_json_result(Cred, Url).
  
  -spec repos(credentials(), map()) -> result().
  repos(Cred, Opts) ->
      repos(Cred, undefined, Opts).
  
  -spec repos(credentials(), string(), map()) -> result().
  repos(Cred, User, Opts) ->
      Url = make_url(repos, {User, Opts}),
      api_call_json_result(Cred, Url).
  
  -spec org_repos(credentials(), string(), map()) -> result().
  org_repos(Cred, Org, Opts) ->
      Url = make_url(org_repos, {Org, Opts}),
      api_call_json_result(Cred, Url).
  
  -spec hooks(credentials(), repository()) -> result().
  