AnsweredAssumed Answered

How to structure an AJAX request to execute Process via RESTish API?

Question asked by NathanWisman1191 on Aug 25, 2014
Latest reply on Aug 27, 2014 by NathanWisman1191
I want to use a javascript app to send a request to the Boomi REST API, in order to execute a process.

Here is the request that doesn't work (with all username, password, and ID values filled in of course):

          callBoomiProcess: function() {
                          return {
                              url:         '',
                              type:        'POST',
                              contentType: 'text/xml',
                              username: '',
                              password: '<password here>',
                              data: '<ProcessExecutionRequest processId="process Id here" atomId="atom Id here" xmlns="">' +
                                      '<ProcessProperties>'  +
                                          '<!—Zero or more repetitions:—>' +
                                          '<ProcessProperty>' +
                                              '<Name>fileID</Name>' +
                                              '<Value><fileId here></Value>' +
                                          '</ProcessProperty>' +
                                      '</ProcessProperties>' +

I've tried many variants of this request (providing a data-type parameter, putting username and password in headers, etc.). I get any number of errors from these variants.

Here's the error for the above request:
<?xml version="1.0" encoding="UTF-8" standalone="no"?><error><message>Unable to read message body.  Please make sure the XML structure and namespace are correct.</message></error>