Trying to configure test.domain.com with Let's Encrypt SSL support

I’m trying to add a test version of my site with Let’s Encrypt SSL support.

I’m using CloudFlare for the root domain, and the subdomain is proxied through CloudFlare.

In Hestia, I have a Web Domain for the main site (domain.com), and a second Web Domain for test.domain.com.

In the Edit Web Domain settings for the test subdomain, if I try to tick ‘Use Lets Encrypt to obtain SSL certificate’ and Save, it tells me ‘DNS record for test.domain.com doesn’t exist’

If I dig the subdomain I get the response:

id 25526
opcode QUERY
rcode NXDOMAIN
flags QR RD RA
;QUESTION
test.domain.com. IN A
;ANSWER
;AUTHORITY
domain.com. 1617 IN SOA aida.ns.cloudflare.com. dns.cloudflare.com. 2276727314 10000 2400 604800 3600
;ADDITIONAL

And nslookup test.domain.com returns ‘Non-existent domain’

I’m a bit crap with DNS configuration, not sure what I need to do to get it working.
Some help would be appreciated.
Thanks.

EDIT:
Also worth noting Cloudflare is serving its own SSL certificate, the ‘SSL/TLS encryption mode’ is set to Full (Encrypts end-to-end, using a self signed certificate on the server)
But I also have a websocket server that requires a non-proxied subdomain to work, which serves my site’s Lets Encrypt certificate.

bump

Still can’t figure this out. Would really appreciate some help.

You can’t use DNS in Hestia if you have Cloudflare enabled and proxied.

Just delete the DNS domain in HestiaCP

Also disable the proxy for Cloudflare if you want to use Lets encrypt after it has been enabled you can enable it again

Thanks, this worked.
I deleted the DNS for the test domain and I added a CNAME records ‘test’ & ‘www.test’ to my Cloudflare DNS settings, I can now then generate Lets Encrypt SSL Certificates with Hestia for this domain.