Intermittent SSLException errors

Hello,
I am noticing intermittent SSLExceptions when I use companies house api.
It seems to happen when I call the API after a long pause. Subsequent calls succeed without issues.
It’s a simple java spring boot app calling companies house with RestTemplate.
What could be the issue?

Example request:
curl -X GET \ https://api.companieshouse.gov.uk/company/06670927/officers \ -H 'Authorization: api-token' \ -H 'cache-control: no-cache'

Exception:
org.springframework.web.client.ResourceAccessException: I/O error on GET request for \"https://api.companieshouse.gov.uk/company/06670927/officers\": Connection reset; nested exception is javax.net.ssl.SSLException: Connection reset

Doesn’t seem to happen anymore. Closing this question.