Some users have found success by manually installing older, compatible versions of the WhatsApp Desktop client. Whatsapp Desktop for OS 10.15.7 - Apple Support Community
Error 10157 is an installation failure code that usually appears when using the official WhatsApp.dmg installer or when trying to update the app via the native updater. The full error message often reads:
https://web.whatsapp.com/desktop/mac/files/WhatsApp-23.24.79.dmg
Instead of a standard app, you can create a "web app" that sits in your Dock and feels like a native application: Open Google Chrome or Microsoft Edge WhatsApp Web : Click the three dots (top right) > Save and Share Install page as app : Click the three dots > Install this site as an app
If you specifically need the native app (for features like better system integration), you must find an older version that hasn't yet been completely disabled by Meta’s servers.