GravityKit\GravityMigrate\Abilities\Discovery\GetStatus
Whether a migration is running on this site, how far along, and what is in the way.
What an agent polls: a site-to-site import runs for minutes in a background job, so the call that starts one cannot also finish it.
Bundle work only. migration-run moves forms between plugins synchronously and touches
neither the import lock nor either job option, so it never appears here.
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:29
Details
- Kind:
class - Namespace:
GravityKit\GravityMigrate\Abilities\Discovery - 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/Discovery/GetStatus.php:34
label()
public static function label(): string
The short human label, shown in Foundation's settings list.
Returns
string
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:41
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/Discovery/GetStatus.php:48
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/Discovery/GetStatus.php:60
input_schema()
public static function input_schema(): array
JSON Schema for the input.
Returns
array
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:67
output_schema()
public static function output_schema(): array
JSON Schema for the output.
Returns
array
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:84
annotations()
public static function annotations(): array
WordPress's own annotation vocabulary for this ability.
The HTTP method is derived from these: readonly is a GET, destructive plus
idempotent a DELETE, anything else a POST. A write annotated readonly is therefore
called with a verb WordPress refuses.
Returns
array{readonly:bool,— destructive:bool, idempotent:bool}
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:194
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/Discovery/GetStatus.php:209
permission()
public static function permission( array $input=[] )
Whether this caller may run it.
Administrator only, which is stricter than wp gk migrate status: that command requires a
shell on the server, and this is reachable by anything holding a connection.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$input | array | [] | Input as received. |
Returns
bool|\WP_Error
Since: %ver%
Source: src/Abilities/Discovery/GetStatus.php:232