Creating POST request upon user clicking link/button/saving case

I am looking to customize my SuiteCRM installation. In the Cases module, I would like a user to be able to click a link or button OR have this action triggered upon the case being saved/updates. The action is to send a POST request to a given url using fields in the case. It would be really nice if I could display the result of the request or forward the user to a url but not required.

It seems there are a few ways to do this:

  • Create a custom module
  • Somehow make URL field able to POST instead of just GET
  • Create an AOC/Workflow custom action
  • Write a PHP script which accepts parameters in GET and forwards them in a POST to the given URL, then link to that script with the URL field
  • Create a custom connector??

Which way is best to go about doing this? It there a more obvious way that doesn’t involve custom-coding in PHP? I just want to take fields from a case and POST them somewhere.

Thank you anybody who is able to offer help and advice on this!

it depends on what exactly you’re trying to do, but its possible to inject javascript and to create your ajax-post from there too. This way, the whole process can be implemented without any redirect.