- 
                Notifications
    You must be signed in to change notification settings 
- Fork 84
activitypub_safe_remote_post_response
        github-actions[bot] edited this page Oct 22, 2025 
        ·
        11 revisions
      
    Action to save the response of the remote POST request.
/**
 * Action to save the response of the remote POST request.
 *
 * @param array|\WP_Error $response 
 * @param string          $url 
 * @param string          $body 
 * @param int             $user_id 
 * @return array|\WP_Error The filtered value.
 */
function my_activitypub_safe_remote_post_response_callback( array|\WP_Error $response, string $url, string $body, int $user_id ) {
    // Your code here.
    return $response;
}
add_filter( 'activitypub_safe_remote_post_response', 'my_activitypub_safe_remote_post_response_callback', 10, 4 );- 
array|\WP_Error$responseThe response of the remote POST request.
- 
string$urlThe URL endpoint.
- 
string$bodyThe Post Body.
- 
int$user_idThe WordPress User-ID.
\do_action( 'activitypub_safe_remote_post_response', $response, $url, $body, $user_id )Follow @[email protected] for updates and news.