My agentic slop goes here. Not intended for anyone else!
1(** JMAP Connection Management *)
2
3(** Connection configuration *)
4type config = {
5 max_retries : int;
6 timeout : float;
7 user_agent : string;
8}
9
10(** Default configuration *)
11val default_config : config
12
13(** Config accessors *)
14val max_retries : config -> int
15val timeout : config -> float
16val user_agent : config -> string
17
18(** Config constructor *)
19val config_v : max_retries:int -> timeout:float -> user_agent:string -> config
20
21(** Authentication method *)
22type auth =
23 | Basic of string * string (** username, password *)
24 | Bearer of string (** OAuth2 token *)
25
26(** Connection state *)
27type t
28
29(** Connection accessors *)
30val config : t -> config
31val auth : t -> auth option
32
33(** Connection constructor *)
34val v : ?config:config -> ?auth:auth -> unit -> t
35
36(** Legacy alias for backwards compatibility *)
37val create : ?config:config -> ?auth:auth -> unit -> t