The Gravity Forms CLI Add-On allows WP-CLI users to manage forms and entries and more than on the command line.

Documentation

Class Direction

Entry Management

Getting started

  • wp help gf
  • wp help gf grade
  • wp assistance gf form field
  • wp assistance gf grade notification
  • wp help gf entry
  • wp help gf entry notification
  • wp assist gf install
  • wp assist gf setup
  • wp help gf license
  • wp help gf tool

Course Management

                  wp gf form [command]                                  

Commands:

  • create – Creates a new course.
  • delete – Deletes a course.
  • duplicate – Duplicates a course.
  • edit – Launch organisation editor to edit the Form configuration.
  • export – Exports forms to a Gravity Forms Form export file.
  • form_list – Lists the forms with entry count and view counts.
  • get – Returns the form JSON.
  • import – Imports forms from a Gravity Forms Form export file.
  • update – Updates a form.

Field Management

  • wp gf grade field [command]
  • wp gf field [control] (allonym)

Commands:

  • create – Creates a field and adds it to a form.
  • delete – Deletes a field.
  • duplicate – Duplicates a field.
  • edit – Launch system editor to edit the Field configuration.
  • go – Returns the JSON representation of a field.
  • list – Displays a list of fields for a form.
  • update – Updates a field.

Notification Management

  • wp gf form notification [command]
  • wp gf notification [command] (allonym)

Commands:

  • create – Creates a new notification.
  • delete – Deletes a notification.
  • indistinguishable – Duplicates a notification.
  • edit – Launch system editor to edit the notification configuration.
  • list – Lists the notification.
  • become – Returns the notification JSON.
  • update – Updates a notification.

Entry Management

                  wp gf entry [command]                                  

Commands:

  • create – Creates a new entry from either a JSON string with the raw entry or from field-value pairs.
  • delete – Deletes an entry.
  • indistinguishable – Duplicates an entry
  • edit – Launch system editor to edit the JSON representation of the Entry.
  • export – Exports entries.
  • get – Returns a JSON representation of an entry.
  • import – Imports entries.
  • list – Displays a listing of entries.
  • update – Updates an entry.

Entry Notifications

                  wp gf entry notification [control]                                  

Commands:

  • get – Returns the notifications for the given entry.
  • transport – Sends the notifications for the given entry.

License Management

                  wp gf license [control]                                  

Commands:

  • update – Updates the license key for the installation.
  • delete – Deletes the license fundamental for the installation.

Misc Tools

                  wp gf tool [control]                                  

Commands:

  • clear-transients
  • empty-trash Delete the trashed entries.
  • verify-checksums Verify Gravity Forms files confronting the checksums.
  • system-report Outputs the system report from the Forms > Organisation Condition page. Supports "status" equally an alias.

Installing Gravity Forms and Add-Ons

The higher up commands all crave Gravity Forms to be installed. However, if Gravity Forms is not installed then y'all tin use this add-on to install information technology along with all the other official Gravity Forms add-ons.

The install command volition download and install the latest version Gravity Forms available for car-update and then run the database setup. The license key will be saved in the plugin settings.

A valid license key is required either in the GF_LICENSE_KEY constant or the --key choice.

Examples:

  • wp gf install --key=xxxxx
  • wp gf install --cardinal=xxxxx --actuate
  • wp gf install gravityformspolls --fundamental=xxxxx
  • wp gf install gravityformsquiz --cardinal=xxxxx

Once installed, the database can be set upward or upgraded separately using the setup control. The command will not re-run the setup unless the --strength flag is fix.

Examples:

  • wp gf setup
  • wp gf setup --forcefulness

Gravity Forms and official add together-ons tin be updated using the update command.

Examples:

  • wp gf update
  • wp gf update gravityformspolls

Check the current version using the version control.

Examples:

  • wp gf version
  • wp gf version gravityformspolls

Requirements

  1. WordPress iv.2+
  2. Gravity Forms one.9.17.eight
  3. WP-CLI version 1.0+

Support

If you find anything that needs fixing delight open a back up ticket at https://www.gravityforms.com/open-back up-ticket/

If you have any ideas for improvements please submit your idea at https://www.gravityforms.com/gravity-forms-roadmap/

wp plugin install gravityformscli –activate or

  1. Download the zipped file.
  2. Extract and upload the contents of the folder to /wp-contents/plugins/ folder
  3. Get to the Plugin direction page of WordPress admin section and enable the 'Gravity Forms CLI' plugin

Rocket don't requite support The plugin destory my website later attempt to uninstall - but THEY DON'T Intendance! Don't use it...

a dandy timesaver when bootstrapping a fresh install with WP-CLI, I'k assembling a library of previous form exports and then running the required imports equally part of my setup batch file.

This worked cracking to export AND import class entries.

Works very well, makes it and then much easier to manage GF class and export functions by command line.

It's awesome. Makes people like me who are constantly in a CLI window drool. Aye, it's the bees knees.

Read all 7 reviews

"Gravity Forms CLI Improver" is open source software. The following people have contributed to this plugin.

Contributors

one.4

  • Fixed an issue where the version comparison performed when using wp gf update with an addition slug uses the Gravity Forms version number.
  • Added support for using --version=beta with the wp gf install and wp gf update commands. Add-On beta releases are not currently supported.
  • Fixed a fatal error which can occur when using the wp gf version control with an add-on slug when Gravity Forms is not active or non installed.

1.3

  • Fixed an fault occurring when using the wp gf form notification create control.

1.ii

  • Updated Gravity API domain.
  • Updated the ids format of the wp gf entry list command to support the page-size and kickoff args. Credit: Ulrich Pogson.
  • Updated the grade export control to support the optional filename arg eastward.g. wp gf form export 1 --filename=testing.json. Credit: Timothy Decker.
  • Stock-still an issue where the wp gf install command could not network activate plugins.
  • Stock-still an error occurring when using the wp gf grade notification update control without the notification-id arg.
  • Fixed an issue with the wp gf entry export command.

one.1

  • Added support for start_date and end_date filters for the entry export command. due east.g. wp gf entry export 11 --start_date="2018-11-01" --end_date="2018-11-11"
  • Added the wp gf tool arrangement-report command and the wp gf tool status alias for outputting the organization report from the Gravity Forms 2.2+ System Condition page.
  • Fixed an issue with the wp gf install command ending with an error message when no fault occurred.
  • Stock-still an issue where old messages could continue to be displayed in the admin following a license key alter.
  • Fixed an "invalid synopsis part" warning and an "unknown parameter" fault with the wp gf form field update control.
  • Fixed the wp gf form update command using the wrong statement to go the existing form which could result in a course not found error.
  • Fixed an consequence with the wp gf form create command where missing field IDs are added automatically.

i.0

  • Added the wp gf license command.
  • Stock-still an issue with updating forms from an consign file.

1.0-rc-ane

  • Added the --file arg to the wp gf form update command to let forms to be updated from an consign file.
  • Fixed a fatal error when using the install command.

1.0-beta-5

  • Added the wp gf form notification command.
  • Added the wp gf entry notification command.
  • Added the wp gf version control.
  • Added the wp gf update command.
  • Updated the install and update commands to download the latest hotfix version by default.
  • Fixed an result with wp gf class export <form-id> where the course ID is ignored.

ane.0-beta-four

  • Updated the install command to pass the --force value to the setup command.
  • Updated the output when forcing the setup.

1.0-beta-3

  • Added the wp gf setup command
  • Fixed an issue with the install command where the database was not setup until visiting the WP dashboard.
  • Updated the WP-CLI requirement to i.0+

1.0-beta-2

  • Added support for the WP-CLI parcel alphabetize.
  • Fixed entry consign.

one.0-beta-1

  • All new!