Module Equinoxe_cohttp.Ip

This module manages API parts related to ips.

type id

Abstract type to represent a unique identifier in the Equinix API for ip.

type config = {
id : id;
netmask : string;
network : string;
address : string;
gateway : string;
public : bool;
enabled : bool;
created_at : Equinoxe__Equinoxe_intf.Date.t;
}

Representation of an Ip.

val id_of_string : string -> id

id_of_string str turns a string into an Ip id.

val config_of_json : Ezjsonm.value -> config

config_of_json json returns a config representing the context of the JSON.

  • raises Ezjsonm.Parse_error

    in case of error.

val to_string : config -> string

to_string config returns a string that represents the configuration.

val get_from : t -> id:id -> config io

get_ips_id t ~id returns informations about an ip referenced by its id.

val pp : config -> unit

pp config prints a config in a human readable way.