I'm trying to deploy a custom widget with a button to trigger a GP service that's hosted on our enterprise server.
I tried a few methods based on the Geoprocessor API such as geoprocessor | API Reference | ArcGIS Maps SDK for JavaScript 4.32 | Esri Developer, and Geoprocessor | ArcGIS API for JavaScript 4.14, and ended up getting it work with the classical require() method to load up the geoprocessor library and use the submitJob(), waitForJobCompletion() methods.
I'm able to run the GP service successfully with my local ArcGIS Experience Builder developer edition and get the result returned with no issue, but once I get the widget deployed (hosted with a manifest.json, etc.), it's always getting stuck at the first step with an error message that says "t.submitJob() is not a function".

Wondering if anyone has encountered similar issue, and if so, any suggestions on workarounds?
P.S. I'm also able to get plain JS to work with the AMD approach via a standalone webapp, however it won't have the interaction with the existing elements inside the EXB app, which is critical to what I'm trying to do...
Thank you and appreciate any help!