Recently, I started working with Domino Access Services. So far, it is working fine: I can use my GET and POST requests. But I noticed a problem: When posting a large string (I assume 100-200kb+), the data field will be empty even if something else stood there before. As a response, I get a status code 200. If I insert this large string manually into the data field, it is saved. I can access it with the GET request without any problems. The data field is from type "Rich Text".
My POST-Request: (I also tried it with Postman; it works with small strings)
var largeString = "any large string";
var data = JSON.stringify({
"description": largeString
});
var xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === 4) {
console.log(this.responseText);
}
});
var unid = "#{javascript:document1.getDocument().getUniversalID();}";
xhr.open("POST", "./api/data/documents/unid/" + unid);
xhr.setRequestHeader("content-type", "application/json");
xhr.setRequestHeader("x-http-method-override", "PATCH");
xhr.setRequestHeader("cache-control", "no-cache");
xhr.send(data);
I am wondering: Are there any size limitations for POST? Do I miss any headers for larger requests?