feat: typing indicator

This commit is contained in:
Andrew Glaze
2026-03-20 22:00:19 -04:00
parent 6a48936f6c
commit 85c699412f
2 changed files with 7 additions and 1 deletions

View File

@@ -47,6 +47,12 @@ public struct DiscordClient: Sendable {
req.httpBody = try json.encode(payload)
try await authReq(req)
}
public func triggerTypingIndicator(channelId: String) async throws {
var req = URLRequest(url: DiscordClient.apiUrl.appending(path: "/channels/\(channelId)/typing"))
req.httpMethod = "POST"
try await authReq(req)
}
}
public enum ApiError: Error {