postUrl: request parameter results in internal error -1
When the request parameter is used, this code throws a Creator internal error -1. If the request parameter is not used, this code communicates with the web service OK. I feel like I just need another set of eyes looking at this code. Can anyone spot what is wrong with the request? Thanks.
- response = map();
- url = "https://domain.com/api/pas/agencies/" + "1234";
- header = map();
- header.put("Content-Type", "application/xml");
-
- request = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>";
- request = request + "<agency id=\"" + "1234" + "\">";
- request = request + "<name>" + "Big Business" + "</name>";
- request = request + "</agency>";
- response = postUrl(url, request, header, false);
-
- info response.get("responseText");
- return response.get("responseCode");