package links

  1. Overview
  2. Docs
type handler_id = int
type json_string = string
type websocket_url = string
module JsonState : sig ... end
type json_state = JsonState.t
val nil_literal : string
val parse_json : json_string -> Value.t

Parses a JSON string into a value

val parse_json_b64 : string -> Value.t

Parses a b64-encoded JSON string into a value

val jsonize_value : Value.t -> json_string

Returns a JSON representation of a given value.

val jsonize_value_with_state : Value.t -> json_state -> json_string

Given a JSON state (calculated from resolveJsonState) and a value, * returns an object of the form "value" : v, "state" : s, where v is * the value to serialise and s is the state to serialise.

val jsonize_call : json_state -> Value.continuation -> string -> Value.t list -> json_string

Given a json_state, continuation, function name, and list of arguments, JSONises a call * to the client.

OCaml

Innovation. Community. Security.