A WordPress-centric search engine for devs and theme authors

wp-includes/rest-api.php ›

REST API functions.

Function Short description
create_initial_rest_routesRegisters default REST API routes.
get_rest_urlRetrieves the URL to a REST endpoint on a site.
register_rest_fieldRegisters a new field on an existing WordPress object type.
register_rest_routeRegisters a REST API route.
rest_api_default_filtersRegisters the default REST API filters.
rest_api_initRegisters rewrite rules for the API.
rest_api_loadedLoads the REST API.
rest_api_register_rewritesAdds REST rewrite rules.
rest_authorization_required_codeReturns a contextual HTTP error code for authorization failure.
rest_cookie_check_errorsChecks for errors when using cookie-based authentication.
rest_cookie_collect_statusCollects cookie authentication status.
rest_do_requestDo a REST request.
rest_ensure_requestEnsures request arguments are a request object (for consistency).
rest_ensure_responseEnsures a REST response is a response object (for consistency).
rest_filter_response_fieldsFilter the API response to include only a white-listed set of response object fields.
rest_get_avatar_sizesRetrieves the pixel sizes for avatars.
rest_get_avatar_urlsRetrieves the avatar urls in various sizes.
rest_get_date_with_gmtParses a date into both its local and UTC equivalent, in MySQL datetime format.
rest_get_serverRetrieves the current REST server instance.
rest_get_url_prefixRetrieves the URL prefix for any API resource.
rest_handle_deprecated_argumentHandles _deprecated_argument() errors.
rest_handle_deprecated_functionHandles _deprecated_function() errors.
rest_handle_options_requestHandles OPTIONS requests for the server.
rest_is_booleanDetermines if a given value is boolean-like.
rest_is_field_includedGiven an array of fields to include in a response, some of which may be `nested.fields`, determine whether the provided field should be included in the response body.
rest_is_ip_addressDetermines if an IP address is valid.
rest_output_link_headerSends a Link header for the REST API.
rest_output_link_wp_headOutputs the REST API link tag into page header.
rest_output_rsdAdds the REST API URL to the WP RSD endpoint.
rest_parse_dateParses an RFC3339 time into a Unix timestamp.
rest_parse_request_argParse a request argument based on details registered to the route.
rest_preload_api_requestAppend result of internal request to REST API for purpose of preloading data to be attached to a page.
rest_sanitize_booleanChanges a boolean-like value into the proper boolean value.
rest_sanitize_request_argSanitize a request argument based on details registered to the route.
rest_sanitize_value_from_schemaSanitize a value based on a schema.
rest_send_allow_headerSends the "Allow" header to state all methods that can be sent to the current route.
rest_send_cors_headersSends Cross-Origin Resource Sharing headers with API requests.
rest_urlRetrieves the URL to a REST endpoint.
rest_validate_request_argValidate a request argument based on details registered to the route.
rest_validate_value_from_schemaValidate a value based on a schema.
_rest_array_intersect_key_recursiveRecursively computes the intersection of arrays using keys for comparison.