Get Custom File Types

Prev Next

This URLs provides the custom file types.

Resource URL

GET /domain/<domain_id>/filereputation/filetypes

Request Parameters:

URL parameters:

Field Name

Description

Data Type

Mandatory

domain_id

Domain id

Number

Yes

Response Parameters

Following fields are returned if the request parameters are correct, otherwise error details are returned.

Field Name

Description

Data Type

fileStatus

List of file formats and their status

ObjectList

Details of fileStatus:

Field Name

Description

Data Type

fileType

List of file formats and their status

Object

Details of fileType:

Field Name

Description

Data Type

fileFormat

File format

String

enabled

File format status, default is true

boolean

Example

Request

GET https://<NSM_IP>/sdkapi/domain/0/filereputation/filetypes

Payload:

{
       "fileStatus":
       [
           {
               "fileFormat": "apk",
               "enabled": true
           },
           {
               "fileFormat": "cpl",
               "enabled": true
           },
           {
               "fileFormat": "doc",
               "enabled": false
           },
           {
               "fileFormat": "docx",
               "enabled": false
           },
           {
               "fileFormat": "drv",
               "enabled": false
           },
           {
               "fileFormat": "exe",
               "enabled": false
           },
           {
               "fileFormat": "ocx",
               "enabled": false
           },
           {
               "fileFormat": "pdf",
               "enabled": false
           },
           {
               "fileFormat": "ppt",
               "enabled": false
           },
           {
               "fileFormat": "pptx",
               "enabled": false
           },
           {
               "fileFormat": "scr",
               "enabled": false
           },
           {
               "fileFormat": "sys",
               "enabled": false
           },
           {
               "fileFormat": "xls",
               "enabled": false
           },
           {
               "fileFormat": "xlsx",
               "enabled": false
           }
       ]
    }

Response

{
"status":1
}

Error Information

Following error codes are returned by this URL:

S.No

HTTP Error Code

SDK API errorId

SDK API errorMessage

1

400

1105

Invalid domain

2

404

1105

Invalid domain: This operation is only allowed for root domain