I run a service that has an API. which can help get spot price https://ec2.shop/
Simplify do:
curl 'https://ec2.shop?region=us-west-2&filter=m5&json' | jq
You can pipe it to whatever your system store to get the real time price without dealing with AWS Price API