Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interactor ¶
type Interactor interface { FindUserByID(ctx context.Context, id int64) (*ent.User, error) FindChatUserByID(ctx context.Context, id string) (*ent.ChatUser, error) CreateChatUser(ctx context.Context, cu *ent.ChatUser) (*ent.ChatUser, error) UpdateChatUser(ctx context.Context, cu *ent.ChatUser) (*ent.ChatUser, error) DeleteChatUser(ctx context.Context, cu *ent.ChatUser) error FindDeploymentByID(ctx context.Context, id int) (*ent.Deployment, error) FindDeploymentStatusByID(ctx context.Context, id int) (*ent.DeploymentStatus, error) FindReviewByID(ctx context.Context, id int) (*ent.Review, error) SubscribeEvent(fn func(e *ent.Event)) error UnsubscribeEvent(fn func(e *ent.Event)) error }
type Slack ¶
type Slack struct {
// contains filtered or unexported fields
}
func NewSlack ¶
func NewSlack(c *SlackConfig) *Slack
func (*Slack) Signin ¶
Signin authenticate by Slack oAuth https://api.slack.com/authentication/oauth-v2#exchanging
type SlackAuthedUser ¶
type SlackConfig ¶
type SlackConfig struct { ServerHost string ServerProto string *oauth2.Config Interactor }
type SlackTokenResponse ¶
type SlackTokenResponse struct { // Bot access token AccessToken string `json:"access_token"` TokenType string `json:"token_type"` Scope string `json:"scope"` // Authenticated user access token. User *SlackAuthedUser `json:"authed_user"` }
SlackTokenResponse is the result from exchanging a authorization code for user's access token in Slack. https://api.slack.com/authentication/oauth-v2#exchanging
Click to show internal directories.
Click to hide internal directories.