Uploads a reference document for data rules

Open in ChatGPT Open in ChatGPT to ask questions about this page
Open in Claude Open in Claude to ask questions about this page
Copy as MarkdownCopy this page as markdown to use with AI assistants
View as Markdown Open this page as markdown in a new tab

Uploads a reference document used for fingerprint or keyword-based data rules. Allowed file extensions: csv, txt, pdf, doc, docx. Max file size: 76800 bytes.

Request URL

https://{server-hostname}:8383/endpointdlp/api/data-classification/data-rule/reference-file-upload

Scope

EndpointDLP.CREATECopied!

Header

Authorization: d92d4xxxxxxxxxxxxx15f52

Request Parameters

- Request Headers

AcceptstringMandatory
application/uploadReferenceDocument.v1+jsonapplication/uploadReferenceDocument.v1+jsonCopied!
Content-TypestringMandatory
multipart/form-datamultipart/form-dataCopied!

- Request Body

multipart/form-data
JSON object
Hide Sub-Attributes
referenceFilestringMandatory

Reference document file to upload. Allowed extensions: csv, txt, pdf, doc, docx. Max size: 76800 bytes.

Sample Request

Curl
Java
Python
Deluge
PowerShell
Copied!
curl --request POST \
  --url https://appdomain/endpointdlp/api/data-classification/data-rule/reference-file-upload \
  --header 'Accept: application/uploadReferenceDocument.v1+json' \
  --header 'Authorization:  d92d4xxxxxxxxxxxxx15f52' \
  --header 'Content-Type: multipart/form-data' \
  -F 'referenceFile=(binary file content)'
Show full

Sample Request Body

Upload a reference document

Copied!
referenceFile = (binary file content)
Show full

Response Parameters

- HTTP code 200

Response Body - application/json
JSON object
Hide Sub-Attributes
fileNamestring

Name of the uploaded reference file

fileLocationstring

Server-side location of the uploaded file

- HTTP code 500

Response Body - application/json
JSON object
Hide Sub-Attributes
errorCodestring

Internal error code returned when reference file upload fails (validation, size, or persistence)

errorMessagestring

Reason the reference file upload was unsuccessful

Possible Response Codes

200HTTP code
500HTTP code

Sample Response: HTTP 200

Successful file upload

Copied!
  {
    "fileName": "reference_keywords.csv",
    "fileLocation": "/referencefiles/reference_keywords.csv"
  }
                
Show full

Sample Response: HTTP 500

File upload failed

Copied!
  {
    "errorMessage": "File upload is not successful",
    "errorCode": "INTERNAL_ERROR"
  }
                
Show full

Duration: 1 minute | Threshold: 30 | Lock period: 5 minutes

Duration - Time window for the threshold.
Threshold - Number of API calls allowed within the specified duration.
Lock Period - Wait time before consecutive API requests.