Documentation ¶
Index ¶
- Variables
- func DoUpgrade(helper *up.Helper)
- type BridgeConfig
- func (bc *BridgeConfig) EnableMessageErrorNotices() bool
- func (bc *BridgeConfig) EnableMessageStatusEvents() bool
- func (bc BridgeConfig) FormatDisplayname(params DisplaynameParams) string
- func (bc BridgeConfig) FormatUsername(userID string) string
- func (bc BridgeConfig) GetCommandPrefix() string
- func (bc BridgeConfig) GetDoublePuppetConfig() bridgeconfig.DoublePuppetConfig
- func (bc BridgeConfig) GetEncryptionConfig() bridgeconfig.EncryptionConfig
- func (bc BridgeConfig) GetManagementRoomTexts() bridgeconfig.ManagementRoomTexts
- func (bc *BridgeConfig) GetResendBridgeInfo() bool
- func (bc *BridgeConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
- func (bc *BridgeConfig) Validate() error
- type BridgeMode
- type Config
- type DisplaynameParams
- type RelaybotConfig
- type Sender
Constants ¶
This section is empty.
Variables ¶
View Source
var SpacedBlocks = [][]string{
{"homeserver", "software"},
{"appservice"},
{"appservice", "hostname"},
{"appservice", "database"},
{"appservice", "id"},
{"appservice", "ephemeral_events"},
{"appservice", "as_token"},
{"meta"},
{"bridge"},
{"bridge", "personal_filtering_spaces"},
{"bridge", "command_prefix"},
{"bridge", "backfill"},
{"bridge", "management_room_text"},
{"bridge", "encryption"},
{"bridge", "provisioning"},
{"bridge", "permissions"},
{"bridge", "relay"},
{"logging"},
}
Functions ¶
Types ¶
type BridgeConfig ¶
type BridgeConfig struct { UsernameTemplate string `yaml:"username_template"` DisplaynameTemplate string `yaml:"displayname_template"` PrivateChatPortalMeta string `yaml:"private_chat_portal_meta"` PortalMessageBuffer int `yaml:"portal_message_buffer"` PersonalFilteringSpaces bool `yaml:"personal_filtering_spaces"` BridgeNotices bool `yaml:"bridge_notices"` DeliveryReceipts bool `yaml:"delivery_receipts"` MessageStatusEvents bool `yaml:"message_status_events"` MessageErrorNotices bool `yaml:"message_error_notices"` DisableBridgeAlerts bool `yaml:"disable_bridge_alerts"` SyncDirectChatList bool `yaml:"sync_direct_chat_list"` ResendBridgeInfo bool `yaml:"resend_bridge_info"` CaptionInMessage bool `yaml:"caption_in_message"` FederateRooms bool `yaml:"federate_rooms"` MuteBridging string `yaml:"mute_bridging"` DoublePuppetConfig bridgeconfig.DoublePuppetConfig `yaml:",inline"` MessageHandlingTimeout struct { ErrorAfterStr string `yaml:"error_after"` DeadlineStr string `yaml:"deadline"` ErrorAfter time.Duration `yaml:"-"` Deadline time.Duration `yaml:"-"` } `yaml:"message_handling_timeout"` CommandPrefix string `yaml:"command_prefix"` Backfill struct { Enabled bool `yaml:"enabled"` InboxFetchPages int `yaml:"inbox_fetch_pages"` HistoryFetchPages int `yaml:"history_fetch_pages"` CatchupFetchPages int `yaml:"catchup_fetch_pages"` UnreadHoursThreshold int `yaml:"unread_hours_threshold"` Queue struct { PagesAtOnce int `yaml:"pages_at_once"` MaxPages int `yaml:"max_pages"` SleepBetweenTasks time.Duration `yaml:"sleep_between_tasks"` DontFetchXMA bool `yaml:"dont_fetch_xma"` } `yaml:"queue"` } `yaml:"backfill"` ManagementRoomText bridgeconfig.ManagementRoomTexts `yaml:"management_room_text"` Encryption bridgeconfig.EncryptionConfig `yaml:"encryption"` Provisioning struct { Prefix string `yaml:"prefix"` SharedSecret string `yaml:"shared_secret"` DebugEndpoints bool `yaml:"debug_endpoints"` } `yaml:"provisioning"` Permissions bridgeconfig.PermissionConfig `yaml:"permissions"` Relay RelaybotConfig `yaml:"relay"` // contains filtered or unexported fields }
func (*BridgeConfig) EnableMessageErrorNotices ¶
func (bc *BridgeConfig) EnableMessageErrorNotices() bool
func (*BridgeConfig) EnableMessageStatusEvents ¶
func (bc *BridgeConfig) EnableMessageStatusEvents() bool
func (BridgeConfig) FormatDisplayname ¶
func (bc BridgeConfig) FormatDisplayname(params DisplaynameParams) string
func (BridgeConfig) FormatUsername ¶
func (bc BridgeConfig) FormatUsername(userID string) string
func (BridgeConfig) GetCommandPrefix ¶
func (bc BridgeConfig) GetCommandPrefix() string
func (BridgeConfig) GetDoublePuppetConfig ¶
func (bc BridgeConfig) GetDoublePuppetConfig() bridgeconfig.DoublePuppetConfig
func (BridgeConfig) GetEncryptionConfig ¶
func (bc BridgeConfig) GetEncryptionConfig() bridgeconfig.EncryptionConfig
func (BridgeConfig) GetManagementRoomTexts ¶
func (bc BridgeConfig) GetManagementRoomTexts() bridgeconfig.ManagementRoomTexts
func (*BridgeConfig) GetResendBridgeInfo ¶
func (bc *BridgeConfig) GetResendBridgeInfo() bool
func (*BridgeConfig) UnmarshalYAML ¶
func (bc *BridgeConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
func (*BridgeConfig) Validate ¶
func (bc *BridgeConfig) Validate() error
type BridgeMode ¶
type BridgeMode string
const ( ModeInstagram BridgeMode = "instagram" ModeFacebook BridgeMode = "facebook" ModeFacebookTor BridgeMode = "facebook-tor" ModeMessenger BridgeMode = "messenger" )
func (BridgeMode) IsInstagram ¶
func (bm BridgeMode) IsInstagram() bool
func (BridgeMode) IsMessenger ¶
func (bm BridgeMode) IsMessenger() bool
func (BridgeMode) IsValid ¶
func (bm BridgeMode) IsValid() bool
type Config ¶
type Config struct { *bridgeconfig.BaseConfig `yaml:",inline"` Meta struct { Mode BridgeMode `yaml:"mode"` IGE2EE bool `yaml:"ig_e2ee"` Proxy string `yaml:"proxy"` GetProxyFrom string `yaml:"get_proxy_from"` } `yaml:"meta"` Bridge BridgeConfig `yaml:"bridge"` }
type DisplaynameParams ¶
type RelaybotConfig ¶
type RelaybotConfig struct { Enabled bool `yaml:"enabled"` AdminOnly bool `yaml:"admin_only"` MessageFormats map[event.MessageType]string `yaml:"message_formats"` // contains filtered or unexported fields }
func (*RelaybotConfig) FormatMessage ¶
func (rc *RelaybotConfig) FormatMessage(content *event.MessageEventContent, sender id.UserID, member event.MemberEventContent) (string, error)
func (*RelaybotConfig) UnmarshalYAML ¶
func (rc *RelaybotConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
type Sender ¶
type Sender struct { UserID string event.MemberEventContent }
Click to show internal directories.
Click to hide internal directories.