Trying to get better with Rust

Would be very grateful for a review of some code I wrote today.

It interacts with the OpenAI API over HTTP. Any and all thoughts are welcome. Thanks!