URL structure
Supported methods and overview
GET- retrieves information about the notification preferences of a Covata user (whose access token is submitted in the request to this endpoint).PUT- modifies the notification preferences for a Covata user (whose access token is submitted in the request to this endpoint).
The
GET method takes no parameters.Detailed description
This API endpoint serves a number of purposes:- Retrieves information about the notification preferences of a Covata user (whose access token is submitted in the request to this endpoint). These notifications relate to the frequency with which this Covata user receives email notifications about items which have been shared with them.
- Modifies the notification preferences of a Covata user (whose access token is submitted in the request to this endpoint).
Note: These settings can also be modified through the My Account feature of Safe Share for Web.
Supported roles
This API endpoint supports requests utilizing Covata user accounts with the following roles (as described in the Organization Administrator’s Guide) and conditions: The Covata Platform’s resources available to a Covata user meeting the criteria above is determined by the access token submitted in the header of requests to this endpoint.Required headers
The appropriate access token as theBearer token:
Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJleHAiOjE0NjcwMTY2NjYsInVzZXJfbmFtZSI6ImFsZXgub...
Content-Type: application/json
Required PUT-request parameters
The following parameters must be sent in the body of the PUT request, each as individual members of a JSON object:-
code - Specify the enumeration (enum) value:
ITEM- Sets the Covata user (whose access token is submitted in the request to this endpoint) to receive email notifications (entitled ‘New items have been shared with you’) each time an item is shared with them. These email notifications contain links to the items (which had been shared with this user since their previous such notification), that opens the items in Safe Share for Web. Bear in mind that multiple items may appear as a ‘digest’ in a single email notification based on the Item shared noticication frequency in minutues property configured by a Safe Share administrator (described in the Safe Share Administrator’s Guide).DAILY- Sets this Covata user to receive a ‘New items have been shared with you’ email notification once a day, containing a digest of all items which had been shared with them since their previous such notification.WEEKLY- Sets this user to receive a ‘New items have been shared with you’ email notification once a week, containing a digest of all items which had been shared with them since their previous such notification.NONE- Sets this user to receive no ‘New items have been shared with you’ email notifications.
Returns
If the request succeeded, then an HTTP response status200 OK is returned.
For successful requests only, a JSON-formatted response containing the following members is also returned:
-
notificationPreferences - An array containing information about each available notification preference in the response to this endpoint. Each element of this array contains information about one of these notification preferences, represented as an object containing the following members.
- name - The name of the notification preference as it is exposed through the user interface of Safe Share applications.
- code - The value of the notification preference as it is hard-coded in the Covata Platform. Each of these are equivalent to the enum value specified in the request to this endpoint.
- selected - A boolean value representing whether (
true) or not (false) the notification preference is currently set for the Covata user (whose access token is submitted in the request to this endpoint). FromPUTrequests to this endpoint, this value should betruefor the notification preference specified in the request to this endpoint (andfalsefor the others).

