I am trying to submit the entire form data using the submit action in AEM forms. I have my own custom submit action which is built on top of the OOTB "sumit to REST endpoint" action. So I am able to hit the end point which I configured within the submit action but I am unable to read the response back to UI. I dont want to redirect it to another thank you page. My app is a single page application so I just want to write the response back to UI so that I can read the response. I have gone through the adobe docs and my code is below:
I think there are some internal GuideSubmitServlet scripts which are intercepting the request and adding these params to the response. Is there a way to stop this and send the my custom response back to UI ?
Checking with the Form team to see if we have any example of this use case. We have use cases on custom actions and handling form data in an OSGi bundle - but not writing out the submitted form back on the original form.