API call not working

hi im creating calls and using bubble.io there api caller is not reading the subgraph

this is the one im using

2 Likes

Hi, I can see that the subgraph is at chain head and returning data.
Can you share the error you are seeing and the query you are making?

3 Likes


so im trying to get calls for a dapp i have taken this api url
https://api.thegraph.com/subgraphs/name/pancakeswap/exchange-v3-bsc

added it to bubble and tried to initalize the call i get this error when i do
saying -

There was an issue setting up your call.

The API call returns a non-object and you picked JSON

in bubble i have put the api call url in place am i missing something

3 Likes

this is what the call looks like in bubble

2 Likes

Have you tried reaching out to Bubble for support? It looks like the issue is on their system. Also, one thing I see is you are using GET, are you able to change that to POST?

2 Likes

i have changed it to post and i get a text box like below i have added the quiery to that and still get a error

2 Likes

this is what i have added to the box that comes up after i change the call to pot

2 Likes

Okay, let me share this error with our team.

2 Likes

@unmadesugar Have you tried using another client to see if it works?

1 Like

what do you mean by another client

1 Like

The team shared this for GraphQL over HTTP POST: https://graphql.org/learn/serving-over-http/#post-request
The query should look like this

 {"query": "pools(...){...}"}
1 Like

trying to work out how that would be wrote

2 Likes

query Pools {
pools(orderBy: totalValueLockedUSD,
orderDirection: desc, first: 5) {
id
totalValueLockedUSD
token0Price
token1Price
token0 {
id
symbol
name
decimals
}
token1 {
id
symbol
name
decimals
}
}
}

1 Like

thats how i have it in sub graph

1 Like

any ideas on how it writes

1 Like