We are talking about Truenas SCALE here, and there you can do a:
#hdparm -C /dev/sdX,
where /dev/sdX is the device you want to query. If the output is standby it is spun down. If it reads active/idle, it is not spun down.
I have never used TrueNas Core or any other *BSD-based system, so I don’t know how you could check it there.