alternative to onmessage

I successfully sent to a server, the data collected by getorder() using onmessage - postmessage and third part script on the HTML element.
Unfortunately now I would like to sed from the correct domain (not from the iframe created by the HTML element ).
What is the alternative way?
I realised that if I add the third part code in the custom code section, the domain is correct. May I use the data collected using getorder() in the third part code added in the custom code section?

Thanks

Maybe…
https://www.wix.com/velo/reference/wix-http-functions

thank you for your reply, unfortunately it does not suite my needs.
i just need to copy/paste my third part javascript somewhere ad then fullfill the fields with the cdataollected by the velo api. Any other suggestions?