You can use that approach or something similar to: Replacing Http-Connector with Jsoup usage. (jsoup is used because it provides a extremely friendly DSL that even basic users can follow)
you can do the same thing with JS, or Groovy, or any scripting language.
Using a delegate can be the same as well. The benefit i have found to using the scripting approach is you can deploy your specific script configs (http request configs) along with the specific bpmn, rather than having to make a whole new WAR