Custodian v0.0.1 Custodian.Bots.Bot View Source

A Bot is installed on an individual repo on GitHub. It holds data about its repo and installation.

Fields

  • installation_id (integer, required) - Integer issued by GitHub for the installation of the app
  • name (string, required) - The repo’s name
  • owner (string, required) - The repo’s owner
  • repo_id (integer, required) - Integer issued by GitHub identifying the repository

Note: on GitHub, repos are named owner/name.

Validations

  • installation_id - Required
  • name - Required, unique scoped by owner
  • owner - Required, unique
  • repo_id - Required, unique

Link to this section Summary

Types

t()

Bot installation on a remote GitHub repository

Functions

Builds a changeset based on the struct and params

Link to this section Types

Link to this type t() View Source
t() :: %Custodian.Bots.Bot{__meta__: term(), id: term(), inserted_at: term(), installation_id: term(), name: term(), owner: term(), repo_id: term(), updated_at: term()}

Bot installation on a remote GitHub repository.

Link to this section Functions

Link to this function changeset(bot, attrs) View Source
changeset(t(), map()) :: Ecto.Changeset.t()

Builds a changeset based on the struct and params.

Examples

iex> changeset(%Bot{}, %{name: "lleger", repo: "gh-api-test"})
%Ecto.Changeset{}