Native macOS app for posting to Mastodon, WordPress (self-hosted), and Micro.blog. Features: global hotkey (Ctrl+Option+Cmd+T), multiple accounts with selection, image attachments (up to 4, drag-and-drop), floating panel UI, Keychain storage.
12 lines
368 B
Swift
12 lines
368 B
Swift
import AppKit
|
|
|
|
protocol PostingService: Sendable {
|
|
var account: Account { get }
|
|
func uploadMedia(imageData: Data, filename: String, altText: String?) async throws -> String
|
|
func createPost(text: String, mediaIDs: [String]) async throws -> URL
|
|
}
|
|
|
|
struct PostingError: LocalizedError {
|
|
let message: String
|
|
var errorDescription: String? { message }
|
|
}
|