Upload
This documentation is currently outdated and in the process of being updated. This documentation is provided as a temporary reference to various API endpoints and output. This warning will be at the top of each outdated page. As the documentation is updated, this warning will be removed.
Listing Uploads in a Client
List uploads in a client.
API Call: GET/client/{clientId}/upload
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
User Roles
The user roles that can list uploads in a client are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample list_upload Snippet
import json
import requests
platform = 'https://platform.risksense.com'
api_key = '<INSERT API KEY HERE>'
client_id = <INSERT CLIENT ID HERE>
assessment_id = <INSERT ASSESSMENT ID HERE>
page_size = 150
page_num = 0
header = {
"x-api-key": api_key,
"content-type": "application/json"
}
params = {
"assessmentId": assessment_id,
"size": page_size,
"page": page_num
}
url = platform + "/api/v1/client/" + str(client_id) + "/upload"
response = requests.get(url, headers=header, params=json.dumps(params))
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
cURL
cURL Sample list_upload Snippet
curl -X GET "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
Response Parameters
Sample Response
{
"page": {
"size": <SIZE>,
"totalElements": <TOTALELEMENTS>,
"totalPages": <TOTALPAGES>,
"number": <NUMBER>
},
"_embedded": {
"uploads": [
{
"id": <ID>,
"name": "<NAME>",
"assessmentId": <ASSESSMENTID>,
"networkId": <NETWORKID>,
"state": "<STATE>",
"connectorId": <CONNECTORID>,
"created": "<CREATED>",
"userId": <USERID>
}
]
},
"_links": {
"first": {
"href": "http://platform.risksense.com/api/v1/client/<CLIENTID>/upload?page<NUMBER>&size=<SIZE>"
},
"self": {
"href": "http://platform.risksense.com/api/v1/client/<CLIENTID>/upload?page=<NUMBER>&size=<SIZE>"
},
"next": {
"href": "http://platform.risksense.com/api/v1/client/<CLIENTID>/upload?page=<NUMBERNEXT>&size=<SIZE>"
},
"last": {
"href": "http://platform.risksense.com/api/v1/client/<CLIENTID>/upload?page=<NUMBERLAST>&size=<SIZE>"
}
}
}
Name | Description | Additional Information |
---|---|---|
SIZE | Page size requested. | integer
|
TOTALELEMENTS | Total viewable elements. | integer
|
TOTALPAGES | Total page count. | integer
|
NUMBER | Page to view. | Note that 0 is the first page. |
ID | Upload ID number. | integer
|
NAME | Upload name. | |
ASSESSMENTID | Assessment ID number | |
NETWORKID | Network ID number | |
STATE | Upload state. | |
CONNECTORID | Connector ID number. | |
CREATED | Date/Time upload created. | |
USERID | User ID number that created upload. | |
CLIENTID | Client ID number. | integer
|
NUMBERNEXT | Next page number. | integer
|
NUMBERLAST | Last page number. | integer
|
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
200 Sample Response
"_embedded": {
"uploads": [
{
"id": 12
}
]
},
"page": {
"size": 0,
"totalElements": 0,
"totalPages": 0,
"number": 0
}
}
Code | Description |
---|---|
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Creating a New Upload
API Call: POST/client/{clientId}/upload
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
User Roles
The user roles that can create a new upload are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample create_upload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample create_upload Snippet
curl -X POST "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
-H "Content-Type: application/json"
-d "{ \"assessmentId\": <ASSESSMENTID>, \"networkId\": <NETWORKID>, \"name\": \"<NAME>\"}"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
ASSESSMENTID | Assessment ID number. | |
NETWORKID | Network ID number. | |
NAME | Upload name. |
Response Parameters
Sample Response
{
"id": <ID>
}
Name | Description | Type |
---|---|---|
ID | Upload ID number. | integer
|
HTTP Status Codes
Code | Description |
---|---|
201 | Job Created |
201 Sample Response
{
"id": 12
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Viewing the State of an Upload
View upload state.
API Call: GET/client/{clientId}/upload/{uploadId}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can view the state of an upload are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample view_uploadstate Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
cURL
cURL Sample view_uploadstate Snippet
curl -X GET "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
UPLOADID | Upload ID number. |
Response Parameters
Sample Response
{
"id": <ID>,
"name": "<NAME>",
"assessmentId": <ASSESSMENTID>,
"networkId": <NETWORKID>,
"state": "<STATE>",
"connectorId": <CONNECTORID>,
"created": "<CREATED>",
"userId": <USERID>
}
Name | Description | Additional Information |
---|---|---|
ID | Upload ID number. | integer
|
NAME | Upload name. | string
|
ASSESSMENTID | Assessment ID number | integer
|
NETWORKID | Network ID number | integer
|
STATE | Upload state. | string Options: Pending, FingerPrinting, Processing, PartialSuccess, Failure |
CONNECTORID | Connector ID number. | integer
|
CREATED | Date/Time upload created. | string($date-time)
|
USERID | User ID number that created upload. | integer
|
HTTP Status Codes
Code | Description |
---|---|
200 | Job Created |
200 Sample Response
{
"id": 12
}
Code | Description |
---|---|
400 | User Error |
200 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Updating an Upload
Update an upload.
This API call is only available before an upload starts processing.
API Call: PUT/client/{clientId}/upload/{uploadId}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can update an upload are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample update_upload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
cURL
cURL Sample update_upload Snippet
curl -X PUT "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
-H "Content-Type: application/json"
-d "{ \"assessmentID\": <ASSESSMENTID>, \"networkId\": <NETWORKID>, \"name\": \"<NAME>\"}"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | integer
|
CLIENTID | Client ID number. | integer
|
UPLOADID | Upload ID number. | integer
|
APIKEY | Your API key. | Generating an API Token |
ASSESSMENTID | Assessment ID number. | integer
|
NETWORKID | Network ID number. | integer
|
NAME | Updated Assessment name. | string
|
Response Parameters
Sample Response
{
"id": <ID>
}
Name | Description | Type |
---|---|---|
ID | ID number. | integer
|
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
200 Sample Response
{
"id": 12
}
Code | Description |
---|---|
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Deleting an Upload
Delete an upload.
This API call is only available while the upload is not processing (i.e., before the upload starts and after the files are done processing).
API Call: DELETE/client/{clientId}/upload/{uploadId}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can update an upload are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample delete_upload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your API key. | Generating an API Token |
cURL
cURL Sample delete_upload Snippet
curl -X DELETE "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | integer
|
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | integer
|
APIKEY | Your API key. | Generating an API Token |
HTTP Status Codes
Code | Description |
---|---|
200 | Job Created |
401 | Unauthorized |
404 | Not Found |
Listing Files in an Upload
List files in an upload.
API Call: GET/client/{clientId}/upload/{uploadId}/file
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can list files in an upload are:
- Group Manager with upload permissions
- Manager
Python
Python Sample list_filesUpload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample list_filesUpload Snippet
curl -X GET "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file?size=<SIZE>&page=<PAGE>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | integer
|
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | |
SIZE | Size of page requested. | |
PAGE | Page number requested. | Value of 0 for first page. |
APIKEY | Your designated API key. | Generating an API Token |
Response Parameters
Sample Response
{
"_embedded": {
"files": [
{
"id": <ID>,
"scannerName": "<SCANNERNAME>",
"scannerUuid": "<SCANNERUUID>",
"assessmentId": <ASSESSMENTID>,
"networkId": <NETWORKID>,
"applicationId": <APPLICATIONID>,
"state": "<STATE>"
}
]
},
"page": {
"size": <SIZE>,
"totalElements": <TOTALELEMENTS>,
"totalPages": <TOTALPAGES>,
"number": <NUMBER>
}
}
Name | Description | Type |
---|---|---|
ID | File ID number. | integer
|
SCANNERNAME | Scanner Name. | string
|
SCANNERUUID | Scanner UUID. | string
|
ASSESSMENTID | Assessment ID number. | integer
|
NETWORKID | Network ID number. | integer
|
APPLICATIONID | Application ID number. | integer
|
STATE | Upload state. | string
|
SIZE | Size of page requested | integer
|
TOTALELEMENTS | Total number of items. | integer
|
TOTAL PAGES | Total number of pages. | integer
|
NUMBER | Page number requested. | integer First Page = 0 |
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
200 Sample Response
{
"_embedded": {
"files": [
{
"id": 53606,
"scannerName": "Nexpose",
"scannerUuid": "NEXPOSE",
"assessmentId": 8070,
"networkId": 15,
"applicationId": null,
"state": "PROCESSED"
}
]
},
"page": {
"size": 0,
"totalElements": 0,
"totalPages": 0,
"number": 0
}
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Adding a File to an Upload
Add a file to an upload.
API Call: POST/client/{clientId}/upload/{uploadId}/file
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can add files to an upload are:
- Group Manager with upload permissions
- Manager
Python
Python Sample add_fileUpload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample add_fileUpload Snippet
curl -X POST "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
-H "Content-Type: multipart/form-data"
-F "scanFile=@<FILENAME>;type=<FILETYPE>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | |
APIKEY | Your designated API key. | Generating an API Token |
FILENAME | File name. | |
FILETYPE | File type. |
Response Parameters
Sample Response
[
{
"id": <ID>,
"scannerName": "<SCANNERNAME>",
"scannerUuid": "<SCANNERUUID>",
"assessmentId": <ASSESSMENTID>,
"networkId": <NETWORKID>,
"applicationId": <APPLICATIONID>,
"state": "<STATE>"
}
]
Name | Description | Additional Information |
---|---|---|
ID | File ID number. | integer
|
SCANNERNAME | Scanner Name. | string
|
SCANNERUUID | Scanner UUID. | integer
|
ASSESSMENTID | Assessment ID number. | integer
|
NETWORKID | Network ID number. | integer
|
APPLICATIONID | Application ID number. | integer
|
STATE | Upload state. | string
|
HTTP Status Codes
Code | Description |
---|---|
201 | Success |
201 Sample Response
[
{
"id": 53606,
"scannerName": "Nexpose",
"scannerUuid": "NEXPOSE",
"assessmentId": 8070,
"networkId": 15,
"applicationId": null,
"state": "PROCESSED"
}
]
Code | Description |
---|---|
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Configuring an Upload File
Configure an Upload File
API Call: PUT/client/{clientId}/upload/{uploadId}/file/{fileId}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEID | File ID number. |
User Roles
The user roles that can configure an upload file are:
- Group Manager with upload permissions
- Manager
Python
Python Sample configure_upload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample configure_upload Snippet
curl -X PUT "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
-H "Content-Type: application/json"
-d "{ \"assessmentId\": <ASSESSMENTID>, \"networkId\": <NETWORKID>, \"applicationId\": <APPLICATIONID>}"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEID | File ID number. | integer
|
APIKEY | Your designated API key. | Generating an API Token |
ASSESSMENTID | Assessment ID number. | integer
|
NETWORKID | Network ID number. | integer
|
APPLICATIONID | Application ID number. | integer
|
Response Parameters
Sample Response
[
{
"id": <ID>,
"scannerName": "<SCANNERNAME>",
"scannerUuid": "<SCANNERUUID>",
"assessmentId": <ASSESSMENTID>,
"networkId": <NETWORKID>,
"applicationId": <APPLICATIONID>,
"state": "<STATE>"
}
]
Name | Description | Additional Information |
---|---|---|
ID | File ID number. | integer
|
SCANNERNAME | Scanner Name. | string
|
SCANNERUUID | Scanner UUID. | integer
|
ASSESSMENTID | Assessment ID number. | integer
|
NETWORKID | Network ID number. | integer
|
APPLICATIONID | Application ID number. | integer
|
STATE | Upload state. | string
|
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
200 Sample Response
{
"id": 53606,
"scannerName": "Nexpose",
"scannerUuid": "NEXPOSE",
"assessmentId": 8070,
"networkId": 15,
"applicationId": null,
"state": "PROCESSED"
}
Code | Description |
---|---|
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
Removing a File from an Upload
Remove file from an upload.
API Call: DELETE/client/{clientId}/upload/{uploadId}/file/{fileId}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEID | File ID number. |
User Roles
The user roles that can remove a file from an upload are:
- Group Manager with upload permissions
- Manager
Python
Python Sample delete_uploadFile Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample delete_uploadFile Snippet
curl -X DELETE "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | integer
|
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEID | File ID number. | integer
|
APIKEY | Your API key. | Generating an API Token |
HTTP Status Codes
Code | Description |
---|---|
204 | Success |
401 | Unauthorized |
404 | Not Found |
Downloading All Upload Files in an Upload
Download all upload files in an upload.
API Call: GET/client/{clientId}/upload/{uploadId}/file/download
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/download
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
User Roles
The user roles that can download all upload files in an upload are:
- Group Manager with upload permissions
- Manager
Python
Python Sample downloadAll_uploadFiles Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample downloadAll_uploadFiles Snippet
curl -X GET "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/download"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | integer
|
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | integer
|
APIKEY | Your designated API key. | Generating an API Token |
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
406 | MIME Mismatch |
Try changing from application/octet-stream to application/json or vice-versa.
Fetching an Upload File by UUID
Fetch an upload file by UUID.
API Call: GET/client/{clientId}/upload/{uploadId}/file/{fileUUID}
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEUUID>
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEUUID | File UIID. |
User Roles
The user roles that can fetch an upload file by UUID are:
- Group Manager with upload permissions
- Manager
Python
Python Sample fetch_uploadUuid Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample fetch_uploadUuid Snippet
curl -X GET "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/file/<FILEUUID>"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | Listing Uploads in Client |
FILEUUID | File UIID. | |
APIKEY | Your designated API key. | Generating an API Token |
HTTP Status Codes
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |
406 | MIME Mismatch |
Try changing from application/octet-stream to application/json or vice-versa.
Starting Processing an Upload
Start processing an upload.
API Call: POST/client/{clientId}/upload/{uploadId}/start
URL: https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/start
URL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | If you are on platform 1, you do not need to put a number. |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. |
User Roles
The user roles that can start processing an upload are:
- Group Manager with Upload Permissions
- Manager
Python
Python Sample start_upload Snippet
TBA
Make sure to replace the angle bracket parameters here with your own values.
Python Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
APIKEY | Your designated API key. | Generating an API Token |
cURL
cURL Sample start_upload Snippet
curl -X POST "https://platform<PLATFORM>.risksense.com/api/v1/client/<CLIENTID>/upload/<UPLOADID>/start"
-H "accept: application/json"
-H "x-api-key: <APIKEY>"
-H "Content-Type: application/json"
-d "{ \"autoUrba\": <AUTOURBA>}"
Make sure to replace the angle bracket parameters here with your own values.
cURL Parameters
Name | Description | Additional Information |
---|---|---|
PLATFORM | Platform number. | |
CLIENTID | Client ID number. | Finding Your Client ID |
UPLOADID | Upload ID number. | integer
|
APIKEY | Your API key. | Generating an API Token |
AUTOURBA | Run Auto Update Remediation by Assessment. |
Response Parameters
Sample Response
{
"id": <ID>
}
Name | Description | Type |
---|---|---|
ID | Job ID number. | integer
|
HTTP Status Codes
Code | Description |
---|---|
200 | Success |
200 Sample Response
{
"id": 12
}
Code | Description |
---|---|
400 | User Error |
400 Sample Response
{
"status": 0,
"path": "string",
"errors": [
{
"field": "string",
"code": "string"
}
]
}
Code | Description |
---|---|
401 | Unauthorized |
404 | Not Found |