Skip to content

Instantly share code, notes, and snippets.

@jeffhollan
Created May 5, 2016 19:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jeffhollan/cbcfa315ded8949360fa035ee4c7c693 to your computer and use it in GitHub Desktop.
Save jeffhollan/cbcfa315ded8949360fa035ee4c7c693 to your computer and use it in GitHub Desktop.
module.exports = function (context, data) {
context.log('Webhook was triggered!');
var message = data.message;
var rx = /(<\?xml.*>)/g;
var xml = rx.exec(message)[1];
context.res = {
body: xml
};
context.done();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment