not sure what library you are using. can I get a link?
I think I found: GitHub - SocyList/ACMECert: PHP client library for Let's Encrypt (ACME v2)
which is old fork of
https://github.com/skoerfgen/ACMECert/tree/master/src
this looks php and if you just try to use it to get a certificate on webhosting I'd recommend certsage: