Full Mattermost server source with integrated Community Enterprise features. Includes vendor directory for offline/air-gapped builds. Structure: - enterprise-impl/: Enterprise feature implementations - enterprise-community/: Init files that register implementations - enterprise/: Bridge imports (community_imports.go) - vendor/: All dependencies for offline builds Build (online): go build ./cmd/mattermost Build (offline/air-gapped): go build -mod=vendor ./cmd/mattermost 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
39 lines
1.2 KiB
Go
39 lines
1.2 KiB
Go
// Copyright (c) 2019-present Mattermost, Inc. All Rights Reserved.
|
|
// See License for license information.
|
|
|
|
package poster
|
|
|
|
import (
|
|
"github.com/mattermost/mattermost/server/public/model"
|
|
)
|
|
|
|
// Poster defines an entity that can post DMs and Ephemerals and update and delete those posts
|
|
type Poster interface {
|
|
DMer
|
|
|
|
// DMWithAttachments posts a Direct Message that contains Slack attachments.
|
|
// Often used to include post actions.
|
|
DMWithAttachments(mattermostUserID string, attachments ...*model.SlackAttachment) (string, error)
|
|
|
|
// Ephemeral sends an ephemeral message to a user
|
|
Ephemeral(mattermostUserID, channelID, format string, args ...any)
|
|
|
|
// UpdatePostByID updates the post with postID with the formatted message
|
|
UpdatePostByID(postID, format string, args ...any) error
|
|
|
|
// DeletePost deletes a single post
|
|
DeletePost(postID string) error
|
|
|
|
// DMUpdatePost substitute one post with another
|
|
UpdatePost(post *model.Post) error
|
|
|
|
// UpdatePosterID updates the Mattermost User ID of the poster
|
|
UpdatePosterID(id string)
|
|
}
|
|
|
|
// DMer defines an entity that can send Direct Messages
|
|
type DMer interface {
|
|
// DM posts a simple Direct Message to the specified user
|
|
DM(mattermostUserID, format string, args ...any) (string, error)
|
|
}
|