Uploads a reference document for data rules 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
Header Authorization: d92d4xxxxxxxxxxxxx15f52
Request Parameters - Request Headers Content-Type string Mandatory
- Request Body multipart/form-data JSON object
Hide Sub-Attributes referenceFile string Mandatory
Reference document file to upload. Allowed extensions: csv, txt, pdf, doc, docx. Max size: 76800 bytes.
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)'import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.io.IOException;
import java.net.http.HttpTimeoutException;
public class Main {
public static void main(String[] args) {
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://appdomain/endpointdlp/api/data-classification/data-rule/reference-file-upload"))
.header("Content-Type", "multipart/form-data")
.header("Accept", "application/uploadReferenceDocument.v1+json")
.header("Authorization", " d92d4xxxxxxxxxxxxx15f52")
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
}
}
import http.client
conn = http.client.HTTPSConnection("appdomain")
headers = {
'Content-Type': "multipart/form-data",
'Accept': "application/uploadReferenceDocument.v1+json",
'Authorization': " d92d4xxxxxxxxxxxxx15f52"
}
conn.request("POST", "/endpointdlp/api/data-classification/data-rule/reference-file-upload", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
headersMap = Map();
headersMap.put("Accept", "application/uploadReferenceDocument.v1+json");
headersMap.put("Content-Type", "multipart/form-data");
list_of_text=List();
list_of_text.add({"paramName":"referenceFile","content":"value","stringPart":"true"});
response = invokeUrl
[
url: "https://appDomain/endpointdlp/api/data-classification/data-rule/reference-file-upload"
type: POST
headers: headersMap
files: list_of_text
connection: connection_name
]
info response;
$headers=@{}
$headers.Add("Content-Type", "multipart/form-data")
$headers.Add("Accept", "application/uploadReferenceDocument.v1+json")
$headers.Add("Authorization", " d92d4xxxxxxxxxxxxx15f52")
$response = Invoke-WebRequest -Uri 'https://appdomain/endpointdlp/api/data-classification/data-rule/reference-file-upload' -Method POST -Headers $headers▼ 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 fileName string
Name of the uploaded reference file
fileLocation string
Server-side location of the uploaded file
- HTTP code 500 Response Body - application/json JSON object
Hide Sub-Attributes errorCode string
Internal error code returned when reference file upload fails (validation, size, or persistence)
errorMessage string
Reason the reference file upload was unsuccessful
Possible Response Codes Sample Response: HTTP 200 {
"fileName": "reference_keywords.csv",
"fileLocation": "/referencefiles/reference_keywords.csv"
}
▼ Show full
Sample Response: HTTP 500 {
"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.
© 2026, Zoho Corporation Pvt. Ltd. All Rights Reserved.
© 2026, Zoho Corporation Pvt. Ltd. All Rights Reserved.