package otoggl

  1. Overview
  2. Docs

Helper types

type datetime = Ptime.t

Response types

val show_datetime : datetime -> Ppx_deriving_runtime.string
val equal_datetime : datetime -> datetime -> Ppx_deriving_runtime.bool
type time_entry_update_request = {
  1. description : string option;
  2. wid : int option;
  3. pid : int option option;
  4. start : datetime option;
  5. stop : datetime option option;
  6. duration : int option;
  7. tags : string list option;
  8. duronly : bool option;
  9. billable : bool option;
}

Represents a time entry as we send to Toggl when updating one

val show_time_entry_update_request : time_entry_update_request -> Ppx_deriving_runtime.string
type wrapped_time_entry_update_request = {
  1. time_entry : time_entry_update_request;
}
val show_wrapped_time_entry_update_request : wrapped_time_entry_update_request -> Ppx_deriving_runtime.string
type time_entry_request = {
  1. description : string;
  2. wid : int option;
  3. pid : int option;
  4. start : datetime option;
  5. stop : datetime option option;
  6. duration : int;
  7. created_with : string;
  8. tags : string list;
  9. duronly : bool;
  10. billable : bool;
}

Represents a time entry as we send to Toggl when starting or creating one

val show_time_entry_request : time_entry_request -> Ppx_deriving_runtime.string
type wrapped_time_entry = {
  1. time_entry : time_entry_request;
}
val show_wrapped_time_entry : wrapped_time_entry -> Ppx_deriving_runtime.string
type wid = int
val equal_wid : wid -> wid -> Ppx_deriving_runtime.bool
type project_request = {
  1. wid : wid;
  2. name : string;
  3. billable : bool;
  4. is_private : bool;
  5. active : bool;
  6. auto_estimates : bool;
  7. estimated_hours : bool;
  8. actual_hours : int;
  9. template : bool;
  10. template_id : int option;
  11. cid : int option;
  12. color : string option;
  13. hex_color : string option;
}

Represents a project as we send to Toggl when creating one

val show_project_request : project_request -> Ppx_deriving_runtime.string
type wrapped_project_request = {
  1. project : project_request;
}
val show_wrapped_project_request : wrapped_project_request -> Ppx_deriving_runtime.string
type workspace = {
  1. id : wid;
  2. name : string;
  3. default_currency : string;
  4. at : datetime;
  5. premium : bool;
  6. admin : bool;
  7. default_hourly_rate : float;
  8. only_admins_may_create_projects : bool;
  9. only_admins_see_billable_rates : bool;
  10. only_admins_see_team_dashboard : bool;
  11. projects_billable_by_default : bool;
  12. rounding : int;
  13. rounding_minutes : int;
  14. ical_enabled : bool;
  15. api_token : string option;
  16. profile : int option;
  17. logo_url : string option;
}

Represents a workspace in Toggl

val show_workspace : workspace -> Ppx_deriving_runtime.string
val equal_workspace : workspace -> workspace -> Ppx_deriving_runtime.bool
type workspace_list = workspace list
val show_workspace_list : workspace_list -> Ppx_deriving_runtime.string
type uid = int
val equal_uid : uid -> uid -> Ppx_deriving_runtime.bool
type tid = int
val equal_tid : tid -> tid -> Ppx_deriving_runtime.bool
type pid = int
val equal_pid : pid -> pid -> Ppx_deriving_runtime.bool
type time_entry = {
  1. id : tid;
  2. wid : wid;
  3. uid : uid;
  4. description : string;
  5. at : datetime;
  6. pid : pid option;
  7. start : datetime;
  8. stop : datetime option;
  9. duration : int;
  10. tags : string list;
  11. duronly : bool;
  12. billable : bool;
}

Represents a time enty as will be returned from the Toggl API

val show_time_entry : time_entry -> Ppx_deriving_runtime.string
val equal_time_entry : time_entry -> time_entry -> Ppx_deriving_runtime.bool
type time_entry_list = time_entry list
val show_time_entry_list : time_entry_list -> Ppx_deriving_runtime.string
type tid_list = tid list
val show_tid_list : tid_list -> Ppx_deriving_runtime.string
val equal_tid_list : tid_list -> tid_list -> Ppx_deriving_runtime.bool
type project = {
  1. id : pid;
  2. wid : wid;
  3. name : string;
  4. at : datetime;
  5. created_at : datetime option;
  6. billable : bool;
  7. is_private : bool;
  8. active : bool;
  9. auto_estimates : bool;
  10. estimated_hours : bool;
  11. actual_hours : int;
  12. template : bool;
  13. template_id : int option;
  14. color : string option;
  15. hex_color : string option;
}

Represents a project in Toggl

val show_project : project -> Ppx_deriving_runtime.string
val equal_project : project -> project -> Ppx_deriving_runtime.bool
type project_list = project list
val show_project_list : project_list -> Ppx_deriving_runtime.string
val equal_project_list : project_list -> project_list -> Ppx_deriving_runtime.bool
type pid_list = pid list
val show_pid_list : pid_list -> Ppx_deriving_runtime.string
val equal_pid_list : pid_list -> pid_list -> Ppx_deriving_runtime.bool
type data_time_entry = {
  1. data : time_entry;
}
val show_data_time_entry : data_time_entry -> Ppx_deriving_runtime.string
type data_project = {
  1. data : project;
}

Request types

val show_data_project : data_project -> Ppx_deriving_runtime.string
val equal_data_project : data_project -> data_project -> Ppx_deriving_runtime.bool