-
Notifications
You must be signed in to change notification settings - Fork 123
Service Types
In the Locker Project we use a system similar to mime-types to document the types of services where data can be discovered and accessed.
There are two service types, primary types and complete types:
-
Primary types: Primary types are high-level, and represent all data of that type. Examples of primary types include
message
,photo
,link
, orcontact
. -
Complete types: Complete types are more specific, and usually represent either an external service or a new complete data structure. Examples of currently used complete service-types are
contact/google
,photo/flickr
andlink/chrome
.
Each service-type has a definition of a set of REST endpoints, the JSON structure they return, and the JSON structure of any events generated. The definition of this data is stored in a service type definition.
Connectors define the data they send as complete service types. The following are some examples:
- contact/google
- photo/flickr
- link/chrome
Collections define the data they send only as a primary service type, as in the following:
- contact - The contacts collection
- photo - The photos collection
- link - The links collection
The current list of active service types for the Locker Project can be found here.