API input -> dynamic page element -> output, without refresh how?

Hi.

I’m a new user of Wappler. I want to do a certain simple (it seemed to me) thing, but I have no idea from which side to bite it, and the “documentation”, not specially helpful here :wink:

I have an API command on the Wappler side (that I know how to do), which is to receive data, and then this received data (specifically one long text), is to be immediately displayed (without refreshing the page), in a specific text field.

In addition to the API_KEY, and the data, the command will also send the user_id so that it will know on which specific page this information is to be refreshed. Although I would have preferred session_id here, as that would have been “more accurate”.

And that’s what got me through. I have no idea how to achieve such an effect.

Still, to illuminate what exactly I want to achieve.

I have a page with two text elements and a button. Student puts a piece of his code into the first input. He clicks the button.

The code is uploaded to the Jenkins Endpoint, this is where the magic fires, a temporary container is created, the code is tested. A file with the test results is created.
This file, is now to be sent back to Wappler, so that after a few seconds or so, it is displayed in the second text element.

Btw. Is it possible to plug in an editor with code coloring on the Wappler site?

I believe you are overcomplicating things.
How I would do it: Just create a form, send with it whatever you need to your API action (user ID as a hidden form field for example), and on add Dynamic Binding to that form output.
There are different approach how to do it to add Server Connect action to your page, add GET parameter to you backend action and execute Server Connect action with all needed parameters and bind the Dynamic Binding to Server Connect output.

This is not a simple API call, with waiting for a response. Response is after request reach first step (connection with Jenkins). So test result’s can’t be sent back, as a response.

This is why, I’m looking how I can send this result back to the page.

I still don’t see an issue: create value in your back end action that will hold answer from your 3rd party API (Jenkins, or whatever), and mark with “Output” flag. Once your backend API action will receive answer/response from Jenkins - value will be applied and will be sent to your front-end.

Ok, but I have no idea how to execute this exactly step :))))

This is not exactly Documentation how to use API, but a very good example: Connecting to Airtable API