aboutsummaryrefslogtreecommitdiff
path: root/portal/portal.mli
diff options
context:
space:
mode:
authorClombrong <cromblong@egregore.fun>2025-06-26 09:06:21 +0200
committerClombrong <cromblong@egregore.fun>2025-06-26 10:10:08 +0200
commit439711054759b19fdd814e103599e96c92991a69 (patch)
treee4cda0f7327536da6278036d43f82296c67b90ad /portal/portal.mli
parent1d54e3f65f661d8b5e8f12fa347caab27b968c16 (diff)
feat(portal): change stream open and close interface in Portal
Diffstat (limited to 'portal/portal.mli')
-rw-r--r--portal/portal.mli9
1 files changed, 7 insertions, 2 deletions
diff --git a/portal/portal.mli b/portal/portal.mli
index 025055f..f063cd7 100644
--- a/portal/portal.mli
+++ b/portal/portal.mli
@@ -12,8 +12,13 @@ type t = (signal, async) stream * ((signal, sync) stream option -> unit)
Still, bad implementations exist -- Use with care. *)
val xmlns : string
-val stanza_open : ?from:string -> string -> (signal, sync) stream
+(** [negotiate domain portal] negotiates an open stream between the provided [portal]
+ and the XMPP server. It returns the server-assigned [id] of the stream.
-val stanza_close : (signal, sync) stream
+ If [from] is specified, the opening stanza is signed with the JID specified. *)
+val negotiate : ?from:string -> string -> t -> string Lwt.t
+
+(** [close portal] closes the stream between [portal] and the XMPP server. *)
+val close : t -> unit
val connect : string -> t Lwt.t