Can I build a screensaver from the command line?
You can: Screensavers by Zaweba has a --build-html builder that turns a folder with an index.html into a .scr with no window, with clear exit codes.

You can. Screensavers by Zaweba has a command-line builder: run ZawebaScreensavers.exe with --build-html, a folder and a name, and it builds a .scr with no window at all. Add --out to choose where the file goes and --install to install it as well. It reports how it went with an exit code, so it fits neatly into a script.
The command line is the same builder the app uses when you make a screensaver from a web page folder, just without the clicking. It suits anyone who makes screensavers often, or who wants to build them as part of a larger process.
The command
The full form is ZawebaScreensavers.exe --build-html folder --name name, optionally followed by --out file.scr and --install. The folder must contain an index.html, which is the page that runs full screen. The name is what the screensaver will be called. Use --out when you want to choose the exact file and folder for the result. With --install, the built screensaver is installed too.
When the build works, the path of the new .scr is written to standard output, so a script can pick it up and do something with it, such as copy it to a shared folder.
Reading the exit codes
Every run ends with an exit code. 0 means success. 2 means the arguments were wrong, for instance a missing name. 3 means the folder or its index.html wasn't there. 4 means the build itself failed. 5 means the screensaver was built but installing it failed, so you have a .scr but it isn't the current one.
Checking the code in a batch file or PowerShell script is the reliable way to know what happened, because there's no window to show a message.
What the folder should hold
The page in your folder runs full screen with no network access, so everything it needs must be in the folder: scripts, styles, pictures and fonts. It closes on input like any other screensaver. It can read window.ZAWEBA_SAVER for its settings, and an optional saver.json in the folder adds a description and settings, the same as when you build from the app's File menu.
Test the page in a browser first. If it works there without fetching anything from the internet, it will usually build cleanly.
When it's useful
A teacher could build a screensaver from each pupil's web project in one go, instead of opening the app for each. Someone who generates a page from data, a dashboard or a photo set say, can rebuild the screensaver each time the data changes. Kinetion by Zaweba uses the same route in spirit: its File menu has Export as Screensaver, which exports the animation with its web player and builds and installs the .scr through Screensavers.
The windowed way
If you'd rather click, open Screensavers by Zaweba and choose File, then Make a screensaver from a web page folder. Pick the folder, give it a name, and press Build and use or Save .scr file. Either way, the result is a single .scr: a small host program followed by a zip of your web files, which you can copy to another PC.
The command line just makes that repeatable. Write the command once, and the next build takes a second.