Rest call is implemented in Java. same thing i want to implement in mule,
Java code is below:
URL url = new URL(RestUriConstants.BUSINESS_PROCESS_BASE + businessProcessName);
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
conn.setRequestProperty("Content-Type", "application/x-www-form-urlencoded");
conn.setRequestProperty("Accept","application/json");
OutputStreamWriter writer = new OutputStreamWriter(conn.getOutputStream());
writer.write(data);
writer.flush();
in mule i'm sending two things
1. URL
2. pay load
the json is like below:
{"url":"http://mysystem.com:8080/rest/processData","param":{"claimNo":"9","status":"open", "customerName":"Rajesh"}}
how can i pass that url dynamically, as well as i need to pass param value into the rest call..
---UPDATE----
payload value is like
"action=start¶ms={'input':#[json:param]}&createTask=false&parts=all"
example:
<set-payload value="action=start¶ms={'input':#[json:param]}&createTask=false&parts=all"/>
but it is giving error.
thanks.