REST call returns JSON but how do I display it in a table now?

Hi everyone,

I’m trying to do an REST API call using GET which returns a list of values. I want to display them in a table. The results look like the below, but I can’t figure out how to actually make use of this, if at all. I’ve tried the documentation but I’m stumped. I thought maybe the Query JSON with SQL, but wasn’t sure how to use it as I wasn’t getting expected results. I’ve shortened the results to make it easier, but any suggestions?

{
    "response": {
        "cursor": 0,
        "results": [
            {
                "Access": "ON NET",
                "Comp Rate": 0.07,
                "Expected Comp": 635.0400000000001,
                "MRR": 252,
                "Opportunity": "1565807849623x730523927008247800",
            },
            {
                "Access": "ON NET",
                "Comp Rate": 0.07,
                "Expected Comp": 763.5600000000001,
                "MRR": 303,
                "Opportunity": "1565807849623x730523927008247800",
            },
            {
                "Access": "ON NET",
                "Comp Rate": 0.07,
                "Expected Comp": 1134,
                "MRR": 450,
                "Opportunity": "1564762821363x116113019870642180",
            },
 ],
        "remaining": 5519,
        "count": 3
    }
}

@alanlee If I understand you correctly, you want to share data between two Retool apps? Please have a look at the following documentation link.

For some reason it used a completely wrong subject unrelated to my post so just edited it. My question is I’m doing a REST API call which returns the above details as JSON. Can I not use that now in a table? It won’t let me select the query it says something about invalid selection and to try again using data that’s in an array.

errr you should be able to - to display your results in a table you’d want to set the table’s data property to something like {{yourqueryname.data.response.results}}

Did that solve it? @alanlee

Yes it did thanks, I actually did a chat with Retool support this morning and she fixed it to exactly what you showed.

Sweet, happy it worked out for ya :slight_smile: