Forum Academy Marketplace Showcase Pricing Features

How would I send scheduled API calls every few seconds from Bubble to update data on my app?

Hi how’s it going?

I’d like to display the price of a stock in real time - I’m able to connect to an external API and display the price on my page. But how would I do it so it sends updates every few seconds during normal business hours, so that the user can dynamically see the most up-to-date price on the screen?

Thanks so much for your help.

Workflow action Do every X seconds

Sorry I wasn’t able to find in Workflow a Do action every X seconds. Would you mind sending a screenshot of where you see it? I clicked “Click here to add an action” after going into the workflow of the text box where the API call is dynamically updating the data being displayed based on what it’s getting from the API. Is this the right place?

Nevermind I found the Do every X seconds. But how do I trigger the refreshing of an API call? What action should I add under “Click here to add action”? Sorry I’m a bit new to this.

When setting up the API call in the API connector there is a dropdown labeled as “Use as” with the default value set to Data…the only other option is Action.

When you select it to be used as Action it will make it so the API call is performed as a workflow action instead of as a datasource.

You can trigger with do every x seconds, run the api workflow action and then send the result of the api call to the repeating group using the display list workflow action on a repeating group element.

Ok thanks. I’m getting an error on the Display List in repeating group. I set it to “Result of Step 1” but am getting an error message saying “Display list: Data source should be List of prices but right now it is a text”. How would I fix this?