diff --git a/Sources/Realtime/V2/RealtimeChannelV2.swift b/Sources/Realtime/V2/RealtimeChannelV2.swift index d9714bf2..a7f971d3 100644 --- a/Sources/Realtime/V2/RealtimeChannelV2.swift +++ b/Sources/Realtime/V2/RealtimeChannelV2.swift @@ -472,6 +472,24 @@ public final class RealtimeChannelV2: Sendable { } } + /// Listen for postgres changes in a channel. + public func onPostgresChange( + _: AnyAction.Type, + schema: String = "public", + table: String? = nil, + filter: String? = nil, + callback: @escaping @Sendable (AnyAction) -> Void + ) -> Subscription { + _onPostgresChange( + event: .insert, + schema: schema, + table: table, + filter: filter + ) { + callback($0) + } + } + /// Listen for postgres changes in a channel. public func onPostgresChange( _: InsertAction.Type,