GravityKit\GravityMigrate\Abilities\Migration\RunMigration
Moves forms between Gravity Forms and another form plugin, and creates them.
No dry-run flag: \GravityKit\GravityMigrate\Abilities\Discovery\AnalyzeMigration is
the dry run, and separate tools are what let one be annotated readonly and this one not.
Every form asked about is reported, including the ones that failed: a batch that stopped at the first failure would leave nobody able to say which of the rest are on the site.
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:30
Details
- Kind:
class - Namespace:
GravityKit\GravityMigrate\Abilities\Migration - Extends:
Ability
Methods
| Method | Description |
|---|---|
name() | The ability name, gk-gravitymigrate/{object}-{verb}. |
label() | The short human label, shown in Foundation's settings list. |
description() | What this ability does, written for the agent that has to choose between it and the one |
category() | The category slug, which must be one {@see Bootstrap::categories()} declares. |
input_schema() | JSON Schema for the input. |
output_schema() | JSON Schema for the output. |
annotations() | WordPress's own annotation vocabulary for this ability. |
execute() | Does the work. |
permission() | Whether this caller may run it. |
Method Reference
name()
public static function name(): string
The ability name, gk-gravitymigrate/{object}-{verb}.
Permanent once published: the MCP tool name is derived from it, so renaming one breaks every client already bound to it.
Returns
string
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:35
label()
public static function label(): string
The short human label, shown in Foundation's settings list.
Returns
string
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:42
description()
public static function description(): string
What this ability does, written for the agent that has to choose between it and the one
next to it. It is the only documentation an MCP client ever sees.
Returns
string
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:49
category()
public static function category(): string
The category slug, which must be one {@see Bootstrap::categories()} declares.
Foundation derives gk_scope from the suffix, so only a gk-gravitymigrate-{scope} slug
is reachable through a cross-product scope filter.
Returns
string
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:61
input_schema()
public static function input_schema(): array
JSON Schema for the input.
Returns
array
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:68
output_schema()
public static function output_schema(): array
JSON Schema for the output.
Returns
array
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:80
annotations()
public static function annotations(): array
WordPress's own annotation vocabulary for this ability.
Not idempotent: running it twice makes two forms. Not destructive: a second call leaves a duplicate, not a loss.
Returns
array{readonly:bool,— destructive:bool, idempotent:bool}
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:118
execute()
public static function execute( array $input )
Does the work.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$input | array | Input as received. |
Returns
array|\WP_Error
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:133
permission()
public static function permission( array $input=[] )
Whether this caller may run it.
The same gate the wizard applies to the button and wp gk migrate to to the command,
asked of the same function.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$input | array | [] | Input as received. |
Returns
bool|\WP_Error
Since: %ver%
Source: src/Abilities/Migration/RunMigration.php:165