Skip to content

WP-CLI

OctaForms ships a small set of WP-CLI commands, all under wp octa-forms. They are the right tool for cron jobs, deploy scripts and CI.

Drain the delivery queue now. This is the command to run from a system cron. See Cron and the delivery queue.

Terminal window
wp octa-forms queue drain

Show the queue’s current state (backlog, worker health):

Terminal window
wp octa-forms queue status

These import form definitions that ship as JSON in your theme. The full workflow is covered in Forms in your theme (sync).

Show the sync status of every theme form file:

Terminal window
wp octa-forms theme status

Import forms from the theme into the database:

Terminal window
wp octa-forms theme import --all # import every file; exits non-zero on any failure (good for CI)
wp octa-forms theme import --slug=contact # import one form
wp octa-forms theme import --all --force # also overwrite conflicts

Import never deletes anything. Removing a theme file leaves the form in the database untouched.