In case an exception is thrown I want to write in my log file as much as possible, to debug it later: including HTTP response headers!
It is great that .headers() are available in OpenAIServiceException.
Good.
Now make .headers() available in OpenAIInvalidDataException, OpenAIIoException, OpenAIException.
HTTP response headers are extremely important!