@@ -36,7 +36,10 @@ import "cs3/types/v1beta1/types.proto";
3636
3737// OCM Core API
3838//
39- // The OCM Core API is the mapping in GRPC of the OCM core protocol.
39+ // the OCM Core API is the mapping for the local system of the OCM protocol,
40+ // including multi-protocol shares. Implementations are expected to expose
41+ // the `/ocm` endpoints according to the OCM API, and in response to those
42+ // endpoints implement the following API.
4043//
4144// The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
4245// NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and
@@ -50,11 +53,17 @@ import "cs3/types/v1beta1/types.proto";
5053// Any method MAY return UNKNOWN.
5154// Any method MAY return UNAUTHENTICATED.
5255service OcmCoreAPI {
53- // Creates a new ocm share.
56+ // Creates a new OCM share, in response to a call from remote to:
57+ // https://cs3org.github.io/OCM-API/docs.html?branch=v1.1.0&repo=OCM-API&user=cs3org#/paths/~1shares/post
5458 rpc CreateOCMCoreShare (CreateOCMCoreShareRequest ) returns (CreateOCMCoreShareResponse );
59+ // Updates an OCM share, in response to a notification from the remote system to:
60+ // https://cs3org.github.io/OCM-API/docs.html?branch=v1.1.0&repo=OCM-API&user=cs3org#/paths/~1notifications/post
61+ rpc UpdateOCMCoreShare (UpdateOCMCoreShareRequest ) returns (UpdateOCMCoreShareResponse );
62+ // Deletes an OCM share, in response to a notification from the remote system to:
63+ // https://cs3org.github.io/OCM-API/docs.html?branch=v1.1.0&repo=OCM-API&user=cs3org#/paths/~1notifications/post
64+ rpc DeleteOCMCoreShare (DeleteOCMCoreShareRequest ) returns (DeleteOCMCoreShareResponse );
5565}
5666
57- // https://rawgit.com/GEANT/OCM-API/v1/docs.html#null%2Fpaths%2F~1shares%2Fpost
5867message CreateOCMCoreShareRequest {
5968 // OPTIONAL.
6069 // Opaque information.
@@ -87,10 +96,11 @@ message CreateOCMCoreShareRequest {
8796 // Recipient share type.
8897 cs3.sharing.ocm.v1beta1.ShareType share_type = 9 ;
8998 // OPTIONAL.
90- // The expiration time for the ocm share.
99+ // The expiration time for the OCM share.
91100 cs3.types.v1beta1.Timestamp expiration = 10 ;
92101 // REQUIRED.
93- // The protocols which are used to establish synchronisation.
102+ // The protocols which are used to establish synchronisation,
103+ // with their access rights.
94104 // See also cs3/sharing/ocm/v1beta1/resources.proto for how to map
95105 // this to the OCM share payload.
96106 repeated cs3.sharing.ocm.v1beta1.Protocol protocols = 11 ;
@@ -109,3 +119,52 @@ message CreateOCMCoreShareResponse {
109119 // REQUIRED.
110120 cs3.types.v1beta1.Timestamp created = 4 ;
111121}
122+
123+ message UpdateOCMCoreShareRequest {
124+ // OPTIONAL.
125+ // Opaque information.
126+ cs3.types.v1beta1.Opaque opaque = 1 ;
127+ // REQUIRED.
128+ // Unique ID to identify the share at the consumer side.
129+ string ocm_share_id = 2 ;
130+ // OPTIONAL.
131+ // Description for the share.
132+ string description = 3 ;
133+ // OPTIONAL.
134+ // Recipient share type.
135+ cs3.sharing.ocm.v1beta1.ShareType share_type = 5 ;
136+ // OPTIONAL.
137+ // The expiration time for the OCM share.
138+ cs3.types.v1beta1.Timestamp expiration = 6 ;
139+ // OPTIONAL.
140+ // The protocols which are used to establish synchronisation,
141+ // with their access rights.
142+ repeated cs3.sharing.ocm.v1beta1.Protocol protocols = 7 ;
143+ }
144+
145+ message UpdateOCMCoreShareResponse {
146+ // REQUIRED.
147+ // The response status.
148+ cs3.rpc.v1beta1.Status status = 1 ;
149+ // OPTIONAL.
150+ // Opaque information.
151+ cs3.types.v1beta1.Opaque opaque = 2 ;
152+ }
153+
154+ message DeleteOCMCoreShareRequest {
155+ // REQUIRED.
156+ // Unique ID to identify the share at the consumer side.
157+ string id = 1 ;
158+ // OPTIONAL.
159+ // Opaque information.
160+ cs3.types.v1beta1.Opaque opaque = 2 ;
161+ }
162+
163+ message DeleteOCMCoreShareResponse {
164+ // REQUIRED.
165+ // The response status.
166+ cs3.rpc.v1beta1.Status status = 1 ;
167+ // OPTIONAL.
168+ // Opaque information.
169+ cs3.types.v1beta1.Opaque opaque = 2 ;
170+ }
0 commit comments