Did you also change the way you submit your request? If you come from Davinci you have to keep in mind that you also have to change your request body?
(OpenAI API compared to OpenAI API)
Hello fellow Kotlin developer!
I imagine you also come from an Android dev background? Can I just say, I absolutely love Jetpack Compose. Reactive UI is the bees knees. I prefer it over ReactJS, anyday.
Your request seems strange. What are you using to make the actual API request? Retrofit?
In my opinion, you should be setting up an intercepting object to implement your headers. Otherwise you will be manually setting them on each call - which defeats DRY principles.