Filter hook 'akismet_request_args'

in WP Core File wp-content/plugins/akismet/class.akismet-rest-api.php at line 370

View Source

akismet_request_args

Filter Hook
Description
Clear the current alert code and message.

Hook Information

File Location wp-content/plugins/akismet/class.akismet-rest-api.php View on GitHub
Hook Type Filter
Line Number 370

Hook Parameters

Type Name Description
WP_REST_Request $request No description available

Usage Examples

Basic Usage
<?php
// Hook into akismet_request_args
add_filter('akismet_request_args', 'my_custom_filter', 10, 1);

function my_custom_filter($request) {
    // Your custom filtering logic here
    return $request;
}

Source Code Context

wp-content/plugins/akismet/class.akismet-rest-api.php:370 - How this hook is used in WordPress core
<?php
 365  		$request_args = array(
 366  			'key'  => $key,
 367  			'blog' => get_option( 'home' ),
 368  		);
 369  
 370  		$request_args = apply_filters( 'akismet_request_args', $request_args, 'verify-key' );
 371  
 372  		$response = Akismet::http_post( Akismet::build_query( $request_args ), 'verify-key' );
 373  
 374  		if ( $response[1] == 'valid' ) {
 375  			return true;

PHP Documentation

<?php
/**
	 * Clear the current alert code and message.
	 *
	 * @param WP_REST_Request $request
	 * @return WP_Error|WP_REST_Response
	 */
Quick Info
  • Hook Type: Filter
  • Parameters: 1
  • File: wp-content/plugins/akismet/class.akismet-rest-api.php
Related Hooks

Related hooks will be displayed here in future updates.