| [ Index ] |
PHP Cross Reference of WordPress Trunk (Updated Daily) |
[Source view] [Print] [Project Stats]
REST API run controller for Abilities API.
| File Size: | 244 lines (7 kb) |
| Included or required: | 0 times |
| Referenced: | 0 times |
| Includes or requires: | 0 files |
WP_REST_Abilities_V1_Run_Controller:: (7 methods):
register_routes()
execute_ability()
validate_request_method()
check_ability_permissions()
get_input_from_request()
get_run_args()
get_run_schema()
Class: WP_REST_Abilities_V1_Run_Controller - X-Ref
Core controller used to execute abilities via the REST API.| register_routes() X-Ref |
| Registers the routes for ability execution. |
| execute_ability( $request ) X-Ref |
| Executes an ability. param: WP_REST_Request $request Full details about the request. return: WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. |
| validate_request_method( string $request_method, array $annotations ) X-Ref |
| Validates if the HTTP method matches the expected method for the ability based on its annotations. param: string $request_method The HTTP method of the request. param: array<string, (null|bool)> $annotations The ability annotations. return: true|WP_Error True on success, or WP_Error object on failure. |
| check_ability_permissions( $request ) X-Ref |
| Checks if a given request has permission to execute a specific ability. param: WP_REST_Request $request Full details about the request. return: true|WP_Error True if the request has execution permission, WP_Error object otherwise. |
| get_input_from_request( $request ) X-Ref |
| Extracts input parameters from the request. param: WP_REST_Request $request The request object. return: mixed|null The input parameters. |
| get_run_args() X-Ref |
| Retrieves the arguments for ability execution endpoint. return: array<string, mixed> Arguments for the run endpoint. |
| get_run_schema() X-Ref |
| Retrieves the schema for ability execution endpoint. return: array<string, mixed> Schema for the run endpoint. |
| Generated : Tue May 5 08:20:14 2026 | Cross-referenced by PHPXref |