Skip to content

WebhookをBotに置き換え#553

Open
DO885 wants to merge 10 commits intotraPtitech:mainfrom
DO885:feat/bot
Open

WebhookをBotに置き換え#553
DO885 wants to merge 10 commits intotraPtitech:mainfrom
DO885:feat/bot

Conversation

@DO885
Copy link
Copy Markdown

@DO885 DO885 commented Jul 7, 2024

resolves #377
イベントの作成時、メッセージを投稿しそのmessageIDとeventIDがpostsテーブルに入ります
メッセージにスタンプが付けられた際、postsテーブルを参照して対応するイベントの出席状態が変化します

migrationはよくわかってないので雰囲気で書いてます
自動生成に失敗しているので今のところconverterは手実装になっています:ayase_iyaa:

@DO885 DO885 requested review from Nzt3-gh, iChemy and ras0q July 7, 2024 12:54
@ras0q
Copy link
Copy Markdown
Contributor

ras0q commented Jul 7, 2024

メモ #545 でもtraQのbotを作ってaccess tokenを設定していてコンフリクトしているので何とかする

Comment thread domain/post.go
Comment on lines +5 to +8
type Post struct {
MessageID uuid.UUID
EventID uuid.UUID
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eventにtraQのmessageを紐づけるなら新しくテーブルを作らなくてもeventsテーブルにカラムを追加するのでもいいかもしれないです

Copy link
Copy Markdown
Contributor

@iChemy iChemy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

少しコメントしました.
database のスキーマは確かに新しいカラムを増やすだけでも良いのかなと私も思いました

コメント失敗した

@ras0q
Copy link
Copy Markdown
Contributor

ras0q commented Jul 9, 2024

#545 がマージされてTRAQ_ACCESS_TOKENが使われるようになったのでTRAQ_BOT_TOKENではなくこれを使ってほしいです:pray:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

出席を反映するBOTの作成

3 participants