Using an API to populate a Vec Struct. How do i use the data in other functions?

at this point i need to suggest reading the rust book before trying to program in rust. im sorry but you seem to be just begging us and making no effort yourself to fix the syntax errors at this point.

try this:

- let resp_osmosis_json = resp_osmosis.json()::<OsmosisAssetInfo>().await?;
+ let resp_osmosis_json = resp_osmosis.json::<OsmosisAssetInfo>().await?;

Yea I've only been doing this for a few weeks and rust is my first programing language. and i have a lot to learn. Thanks for pointing out my mistakes. I'm working my way through the rust book and learning from you all as go.

3 Likes

well, good luck in your journey :+1:

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.