integrations.discord.parser module

integrations/discord/parser.py

class integrations.discord.parser.MessageParser

Bases: MessageParserDataMixin, MessageParserInterface

メッセージ解析クラス

__init__()
Return type:

None

property check_updatable: bool

DB操作の許可チェック

Returns:

真偽値

  • True: 許可

  • False: 禁止

Return type:

bool

property ignore_user: bool

ignore_useridに存在するユーザかチェック

Returns:

真偽値

  • True: 存在する(操作禁止ユーザ)

  • False: 存在しない

Return type:

bool

property in_thread: bool

リプライメッセージか判定

Returns:

真偽値

Return type:

bool

Note

slackに合わせてプロパティ名に in_thread を使う

property is_bot: bool

botのポストかチェック

Returns:

真偽値

  • True: botのポスト

  • False: ユーザのポスト

Return type:

bool

parser(body)

メッセージ解析

Parameters:

body (Any) – 解析データ

Return type:

None