I don't know how to parse. :-)
Actually this code runs in Mac so it needs to be what ever Mac uses. API can return more than just price but then i need to parse it some how to integer.
what programming language do you use?
Bash? At least internets say that that is used in macOS Terminal app so i think it is Bash.
I can figure out rest of the script, only problem is parsing or finding API which returns just number.