Versions
#
GET VersionsGet object versions.
GET | |
---|---|
Method | GET Metadata |
URL or EndPoint | โ/api/v{version}/projects/{projectId}/buckets/{name}/objects/{key} |
Headers | Authorization |
Parameters | version, projectId, name, key |
Body | Not Applicable |
Query | maxKeys, keyMarker, versionIdMarker |
The description of the URL parameters is as follows:
URL Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
v{version} | Yes | string | v1 | Shows the version of API |
{projectId} | Yes | Guid | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the id of project |
{name} | Yes | string | randombucket | Shows the bucket name |
{key} | Yes | string | randomobject | Shows the key of the object in the specified bucket |
The description of the parameters is as follows:
Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
Version | Yes | string($uuid) | v1 | Shows the version of API |
Project Id | Yes | string($Guid) | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the project id of API |
Name | Yes | string | randombucket | Shows the bucket name |
Key | Yes | string | randomobject | Shows the key of the object in the specified bucket |
MaxKeys | No | integer($int32) | 0 | Defines the maximum number of retrived objects. |
KeyMarker | No | string | "string" | Specifies from which key to start listing objects. |
VersionIdMarker | No | string | "string" | Specifies from which version to start listing objects. |
#
Request bodyThe request does not have a request body.
#
ResponsesIf the action is successful, the service sends back an HTTP 200 response.
The following data is returned in json format by the service.
{ "success": true, "errors": [ "string" ], "messages": [ "string" ], "result": [ { "key": "string", "versionId": "string", "isLatest": true, "isDeleteMarker": true, "lastModified": "2021-07-16T14:12:27.138Z", "size": 0 } ], "resultInfo": { "totalCount": 0, "pageIndex": 0, "pageSize": 0, "totalPages": 0, "hasNextPage": true, "hasPreviousPage": true }}
Field Name | Type | Example | Description |
---|---|---|---|
success | bool | true | If response is success will return true otherwise will return false |
errors | array [] | "string" | Indicate if there was an error |
messages | array [] | "string" | Returns the response message from back-end |
result | array [object] | ||
key | string | "string" | Returns the object key. |
bucketName | string | "string" | Returns the bucket name. |
isPublic | bool | true | Returns the object permission. |
lastModified | datetime | 2021-07-16T12:56:17.027Z | Returns the last modified date of object. |
expires | datetime | 2021-07-16T12:56:17.027Z | Returns the date of object expires. |
contentType | string | "string" | Returns the content type of an object. |
contentLength | int($int32) | 0 | Returns the size of an object. |
cacheControl | string | "string" | Returns the cache control of an object. |
contentDisposition | string | "string" | Returns the content disposition of an object. |
contentEncoding | string | "string" | Returns the content encoding of an object. |
contentLanguage | string | "string" | Returns the content language of an object. |
metadata | Dictionary < string,string > | "string":"string" | Returns the metadata of an object. |
url | string | "string" | Returns the url of an object. |
previewLink | string | "string" | Returns the preview link of an object. |
Errors
For information about the errors that are common to all actions, see Common Errors:
- HTTP Status Code: 401 Unauthorized
- HTTP Status Code: 403 Forbidden
- HTTP Status Code: 404 Not found
#
PUT Object VersionUpdate Version
PUT | |
---|---|
Method | PUT |
URL or EndPoint | /api/v{version}/projects/{projectId}/buckets/{name}/objects/{key}/version |
Headers | Authorization |
Parameters | projectId, name, version, key |
Body | { versionId } |
The description of the URL parameters is as follows:
URL Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
v{version} | Yes | string | v1 | Shows the version of API |
{projectId} | Yes | Guid | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the id of project |
{name} | Yes | string | randombucket | Shows the bucket name |
{key} | Yes | string | objectName | Shows the object key |
The description of the parameters is as follows:
Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
Version | Yes | string($uuid) | v1 | Shows the version of API |
Project Id | Yes | string($Guid) | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the project id of API |
Name | Yes | string | randombucket | Shows the bucket name |
Key | Yes | string | randomobject | Shows the object key |
#
Request body{ "versionId": "string"}
The description of the parameters is as follows:
Body Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
versionId | Yes | string | "string" | Send a specific object version. |
#
ResponsesIf the action is successful, the service sends back an HTTP 200 response.
The following data is returned in json format by the service.
Errors
For information about the errors that are common to all actions, see Common Errors:
- HTTP Status Code: 400 Bad Request
- HTTP Status Code: 401 Unauthorized
- HTTP Status Code: 403 Forbidden
- HTTP Status Code: 404 Not found
#
Delete VersionDelete object version.
DELETE | |
---|---|
Method | DELETE object version |
URL or EndPoint | โ/api/v{version}/projects/{projectId}/buckets/{name}/objects/{key} |
Headers | Authorization |
Parameters | version, projectId, name, key |
Body | Not Applicable |
The description of the URL parameters is as follows:
URL Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
v{version} | Yes | string | v1 | Shows the version of API |
{projectId} | Yes | Guid | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the id of project |
{name} | Yes | string | randombucket | Shows the bucket name |
{key} | Yes | string | randomobject | Shows the key of the object in the specified bucket |
The description of the parameters is as follows:
Parameter Name | Mandatory | Type | Example | Description |
---|---|---|---|---|
Version | Yes | string($uuid) | v1 | Shows the version of API |
Project Id | Yes | string($Guid) | f5faa2e3-316b-4dd0-8f4d-ab41f6f71bd6 | Shows the project id of API |
Name | Yes | string | randombucket | Shows the bucket name |
Key | Yes | string | randomobject | Shows the key of the object in the specified bucket |
#
Request bodyThe request does not have a request body.
#
ResponsesIf the action is successful, the service sends back an HTTP 200 response.
The following data is returned in json format by the service.
{ "success": true, "errors": [ "string" ], "messages": [ "string" ], "result": true, "resultInfo": { "totalCount": 0, "pageIndex": 0, "pageSize": 0, "totalPages": 0, "hasNextPage": true, "hasPreviousPage": true }}
Field Name | Type | Example | Description |
---|---|---|---|
success | bool | true | If response is success will return true otherwise will return false |
errors | array [] | "string" | Indicate if there was an error |
messages | array [] | "string" | Returns the response message from back-end |
result | bool | true | Returns true if the specific object version is deleted. |
Errors
For information about the errors that are common to all actions, see Common Errors:
- HTTP Status Code: 401 Unauthorized
- HTTP Status Code: 403 Forbidden
- HTTP Status Code: 404 Not found