Matching user input to API data to sign user up

Hey everyone,

I tried searching through the forums for this answer and found a couple threads that are sorta-kinda what I’m looking for but still doesn’t seem to be the exact solution.

I’m currently building an app for Realtors. When they are creating an account, they need to input their MLS ID (among other info) in order to confirm that they are, indeed, an active licensed Realtor. I want to be able to confirm that their ID that they have typed into the input is valid before they proceed to the next step.

Ideally, it compares/validates the input immediately, with some conditional feedback (the input border turns green if its valid or red if its not).

For context, I have the MLS API that can search for a specific agent by name, MLS ID, etc. So the API call is currently set up for returning the Realtor’s data based off of searching an ID#.
So I guess I just need to figure out how to takes the user’s input and use that to search for the agent via the API call, and the return a yes/no if the user was found, all in real time

What is the best way to go about setting this up? I’m not very experienced with backend workflows, so maybe thats the answer here?.. :joy:

Thank you for your help!

You would do the When input’s value has changed event, pick the input box, then do the MLS API request (as an Action) with This Input's value for the ID #, if the response shows they are found then set a custom state on page to “yes” (or even save the response in a custom state/database if you need the data in the sign up process later)

Then have your “Continue” button disabled by default, but a condition that when the custom states is “yes” it becomes not disabled.

The When input’s value has changed event will inherently have some delay because the input box will only trigger that after clicking out of the box, or I think after a couple seconds of no typing. This could be a good thing for you so you aren’t doing an API call on every single letter typed, but see how it goes hopfully it is not too slow.