Can I validate file format of the file within a zip file, using Playwright?

I have a scenario where I need to download a file using Playwright.
When I download, I get the file in a zip format. How can I validate the file format of the actual file that is zipped. While validating manually, I can extract it and see the file format.
How can I do it with Playwright automation? (I’m working with Javascript)