Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
API capabilities, used to restrict the scope of an API.token
.
val parse : string -> [ `Error of string | `Ok of t ]
parse
is the parses capabilites, such that parse
(Fmt.to_to_string pp x) = `Ok x
.
The type for API operations.
`Read
allows the bridge to read the corresponding kind of GitHub resources`Write
allows the bridge to update the corresponding kind of resource.`Excl
means that the bridge has exclusive write access to the corresponding GitHub resource. In particular, this means that when the bridge is disconnect/reconnect it will always try to update GitHub to match with the current state of its local resources and it will revert any changes made by other GitHub users on this kind of resources.The type for API resources.
val none : t
none
is the capability to do nothing.
val all : t
all
is the capability to do everything.
allow t o r
is t
with the capability to do API calls of type o
to the kind of resource r
.
disallow t o r
is t
without the capability to do API calls of type o
to the kind of resource r
.
check t o r
is true if t
is allowed to to o
on the kind of resource r
.
val filter_diff : t -> op -> Snapshot.diff -> Snapshot.diff
filter_diff t op d
filters the diff d
to only apply the subset of operations op
over the capabilities defined by t
.