apply_filters( 'rest_post_dispatch', WP_HTTP_Response $result, WP_REST_Server $server, WP_REST_Request $request )

Filters the REST API response.

Description Description

Allows modification of the response before returning.

Top ↑

Parameters Parameters


(WP_HTTP_Response) Result to send to the client. Usually a WP_REST_Response.


(WP_REST_Server) Server instance.


(WP_REST_Request) Request used to generate the response.

Top ↑

Source Source

File: wp-includes/rest-api/class-wp-rest-server.php

View on Trac

Top ↑

Changelog Changelog

Version Description
4.5.0 Applied to embedded responses.
4.4.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.