GET Presigned URL to View File
Overview
The following table contains important information about the GET method in regards to retrieve presigned url to view file.
| GET Presigned URL to view file | |
|---|---|
| Method | GET |
| URL or Endpoint | /api/projects/projectId/uploads/url/requestKey |
| Headers | Authorization |
| Parameters | requestKey, projectId |
| Body | Not applicable |
The description of the URL parameter is as follows:
requestKeyURL Parameter | |
|---|---|
| URL Parameter Name | requestKey |
| Mandatory | Yes |
| Type | string |
| Description | Key that is provided after a successful upload |
projectId URL Parameter | |
|---|---|
| URL Parameter Name | projectId |
| Mandatory | Yes |
| Type | string |
| Description | Unique Id of the project. |
Request Body
The GET request does not have a request body
Response
{
"success": true,
"errors": [],
"messages": [],
"result": {
"uploadFileDetailsId": 0,
"url": "{url}",
"requestKey": "{requestKey}",
"filePath": "{filePath}"
},
"resultInfo": null,
"statusCode": 200
}
The description to the fields in the code are written in the table below.
| Parameter Name | Type | Description |
|---|---|---|
| success | bool | If the response is successful, it will return true. Otherwise, it will return false. |
| errors | array[string] | Indicates if there was an error. |
| messages | array[string] | Returns the response message from the back-end. |
| result | object | Returns the response object. |
| uploadFileDetailsId | integer($int32) | The ID of upload file details. |
| url | string | The URL where the resource can be accessed. |
| requestKey | string | A unique key associated with the request. |
| filePath | string | The file path of the resource. |
| resultInfo | string | Returns extra information about the result. |
| statusCode | integer($int32) | Returns the HTTP Status Code. |
If the action is successful, the service sends back an HTTP 200 or 201 response.
If a project has a deletion policy and the retention period has passed, the endpoint will return:
HTTP 410 Gone
To enable this behavior for your project, please contact our team.
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: Result Not Found
HTTP Status Code 410: Gone
HTTP Status Code 500: Internal Server Error
HTTP Status Code 503: Backend Fetch Failed