bp_rest_api_is_available()

Check the availability of the BP REST API.

Description

Return

(boolean) True if the BP REST API is available. False otherwise.

Source

File: bp-core/bp-core-rest-api.php

function bp_rest_api_is_available() {

	/**
	 * Filter here to disable the BP REST API.
	 *
	 * The BP REST API requires at least WordPress 4.7.0
	 *
	 * @param boolean $value True if the BP REST API is available. False otherwise.
	 *
	 * @since BuddyBoss 1.3.5
	 */
	return apply_filters( 'bp_rest_api_is_available', function_exists( 'create_initial_rest_routes' ) && bp_rest_in_buddypress() ) || bp_rest_is_plugin_active();
}

Changelog

Changelog
Version Description
BuddyBoss 1.3.5 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.