![]() |
API Documentation
|
where {objectId} is the ID of a file object/Secure Object.
GET - used to retrieve information about a file object/Secure Object using its ID.PUT - used to modify a file object's properties using the file object's ID. This involves the file's owner or a collaborator with sufficient permissions on the file 1 (represented through an access token), performing any combination of the following:DELETE - used to change a file object's state on the Covata Platform's Access Service to Deleted. Note: Both the
GETandDELETEmethods take no parameters.
This API endpoint serves a number of purposes:
GET method requests:
PUT method requests:
GET method on the <content-service>/api/v1/objects/{objectId}/view endpoint).GET method on the <content-service>/api/v1/objects/{objectId}/contents endpoint).DELETE method on the <content-service>/api/v1/objects/{objectId}/contents endpoint followed by the DELETE method on the <access-service>/api/v1/objects/{objectId} endpoint), through the Remove (File) permission.1 This owner or collaborator is a Covata user, whose authenticated account is represented by the access token used in calling this API endpoint (see Supported roles and conditions below for more information). A file object's:
DELETE method requests:
DELETE method). DELETE method of this API endpoint (to change the state of this file object to Deleted). If not, then the Covata user's actual quota may differ (potentially significantly) from the quota reported by the Covata Platform (until this data is automatically deleted by the Content Service).This API endpoint supports requests utilizing Covata user accounts with the following roles (as described in the Organization Administrator's Guide) and conditions:
GET, PUT and DELETE methods, when this user owns the file object whose ID is specified by the {objectId} of the request's URL.GET method, when this user is a collaborator on the file object whose ID is specified by the {objectId} of the request's URL.PUT method, when this user is a collaborator on the file object whose ID is specified by {objectId} in the URL. Such a collaborator user can set the:DELETE method, when this user is a collaborator on the file object whose ID is specified by {objectId} in the URL and has the Remove (File) permission on this file object.The Covata Platform's resources available to one of these Covata users (above) is determined by the access token passed in the header of requests to this endpoint.
The appropriate access token as the Bearer token:
Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJleHAiOjE0NjcwMTY2NjYsInVzZXJfbmFtZSI6ImFsZXgub...The following header is required if the body of the request has a JSON object:
Content-Type: application/jsonThe following optional parameters can be sent in the body of the PUT request, each as individual members of a JSON object:
objectId ) - A parameter containing the following optional sub-element parameters, relating to the collaborators being applied to this file object: objectId ) - The size (in bytes) of the file object's data (in its unencrypted form) to be recorded by the Covata Platform's Access Service. Specify this value to record the size of a completed file object's unencrypted data, which is to be encrypted locally by your client application. objectId, although requiring the Share permission to set this parameter as a condition in your client application is recommended ) - The ID of the classification to apply to (or modify on) the file object. If this parameter's value is an empty string (set as the file object's owner only) or the parameter is omitted altogether, then no classification is applied to the file object and therefore, no classification restrictions (i.e. checks on Covata users' group membership and the association of these groups with classifications - see User group endpoints for more information) are placed on any collaborators added to this file object. objectId ) - The MIME type of the data associated with the file object. For example, if the data to be encrypted into this file object is an image in JPEG format, its MIME type value would be image/jpeg. objectId ) - The name to apply to the file object. For example, this might be the name of the original file (whose data is being encrypted into this file object) and its extension. objectId ) - The ID of the folder that will contain the file object. Specifying a value of 0 (or omitting this parameter) results in the new file being located at the default logical root storage location. objectId and the same collaborator's user account that initialized this file object ) - The SHA-512 value of the file object's encrypted data. objectId ) - The date and time from which collaborators can begin accessing the file object's content. Omitting this member makes the file object's content available immediately. shareEndTime ( For collaborator users, requires the Share permission on objectId ) - The date and time from which collaborators' access to the file object's content ceases. Omitting this member makes the file object's content available indefinitely (after its shareStartTime).
Note: As for the shareStartTime parameter, the shareEndTime parameter should only be specified in conjunction with the collaborators parameter. Otherwise, the shareEndTime parameter's value will not be saved when the request is submitted.
Example (PUT request parameters - modifying a Created file object):
Notes:
A JSON-formatted response containing the following members (from GET and PUT requests only):
false. POST method request to this endpoint). This value is null if the name was never specified. null. local, ldap or external. true after it sets the value of canGenerateView (below) to true and the Content Service has successfully generated and stored a read-only view of the file object's data. true after the file object's data has been successfully uploaded and stored and the size of this data is less than the maximum configured file size for generating a view (i.e. 20 MB by default). true) or not (false) two-factor authentication has been enforced for all members of the organization. POST method request to this endpoint). This value is null if the mimeType was never specified. null. 0 indicates that this file object is located at the logical root location. incomplete for an initialized file object, created for a completed file or deleted for a deleted file. createdAt value below. Otherwise, if the file object has since been modified (via a POST method request to this endpoint), this date and time should reflect when the file object was last modified. null, then no classification was specified (i.e. the labelId parameter was specified with an empty string or this parameter was omitted) when the file object was initialized or created, or last updated. This means that no classification restrictions (i.e. checks on Covata users' group membership and the association of these groups with individual classifications - see User group endpoints for more information) have been placed on collaborators added to this file object. 0 indicates that this file object is located at the logical root location. object, which in turn indicates that information about item returned from this request is about a file object. null, then no classification was specified (i.e. the labelId parameter was specified with an empty string or this parameter was omitted) when the file object was initialized or created, or last updated (via a POST method request to this endpoint). collaborators - An array containing information about each Covata user who is currently a collaborator on this file object. Each element of this array contains information about one of these Covata users and is represented as an object, containing the following members:
null or 0. A value of null indicates that the file object's location in its hierarchy of folders (e.g. as indicated in a Safe Share application's list of items) are equivalent between this collaborator (i.e. another Covata user account) and the current owner of this file object. A value of 0 indicates that the file object is being shared from the logical root file area/location of this collaborator's account. In Safe Share applications, this occurs when the owner of this file object has shared the file object with this collaborator, but the file object's parent folder has not also been shared with this collaborator. null. Note: Only an empty array is returned from Covata user accounts who are collaborators on this file object and do not have the View Other permission on it.
Example (GET response - from a request using the access token of an authenticated owner of the file object):
Example (GET response - from a request using the access token of an authenticated collaborator on the file object, where this collaborator does not have the 'View Other' permission on this file):
Example (PUT response - modifying a file object):