-
Hello!👋 ...
try {
const response: AxiosResponse<OpenSeaNft> = await axios.get(
`https://api.opensea.io/api/v2/chain/${chain}/account/${address}/nfts`,
{
headers: {
ccept: "application/json",
"x-api-key": process.env.REACT_APP_OPENSEA_API_KEY,
},
}
);
const newNfts = response.data.nfts.map((item) => {
return {
//...
};
});
setNfts(newNfts);
} catch (e) {
console.error(e);
setNfts([]);
}
... |
Beta Was this translation helpful? Give feedback.
Answered by
ryanio
Dec 8, 2023
Replies: 1 comment
-
the subdomain for testnet chains should be |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
ryanio
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
the subdomain for testnet chains should be
testnets-api.opensea.io