feat: refactor channel mapping with structured parameters and shared channel integration

- Add ChannelMappingRequest and ChannelMappingDeleteRequest structs with validation
- Update BridgeManager interface to accept structured parameters instead of individual strings
- Implement proper user ID and team ID propagation to shared channels
- Add shared channel creation/deletion integration with Mattermost API
- Update command handlers to provide user and team context
- Enhance logging with comprehensive parameter tracking

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Felipe M 2025-08-01 19:10:40 +02:00
parent a5eb80817c
commit 1f45197aa8
No known key found for this signature in database
GPG key ID: 52E5D65FCF99808A
5 changed files with 223 additions and 51 deletions

View file

@ -83,7 +83,7 @@ func (p *Plugin) OnActivate() error {
}
// Initialize bridge manager
p.bridgeManager = bridge.NewManager(p.logger)
p.bridgeManager = bridge.NewManager(p.logger, p.API, p.remoteID)
// Initialize and register bridges with current configuration
if err := p.initBridges(*cfg); err != nil {
@ -202,7 +202,7 @@ func (p *Plugin) registerForSharedChannels() error {
PluginID: manifest.Id,
CreatorID: botUserID,
AutoShareDMs: false,
AutoInvited: false,
AutoInvited: true,
}
remoteID, appErr := p.API.RegisterPluginForSharedChannels(opts)