BP_REST_Document_Details_Endpoint::get_items( WP_REST_Request $request )

Retrieve documents details.

Description

Parameters

$request

(Required) Full details about the request.

Return

(WP_REST_Response) | WP_Error

Source

File: bp-document/classes/class-bp-rest-document-details-endpoint.php

	public function get_items( $request ) {
		$retval = array();

		$retval['tabs']    = $this->get_documents_tabs();
		$retval['privacy'] = $this->get_documents_privacy();

		$response = rest_ensure_response( $retval );

		/**
		 * Fires after a list of documents details is fetched via the REST API.
		 *
		 * @since 0.1.0
		 *
		 * @param WP_REST_Response $response  The response data.
		 * @param WP_REST_Request  $request   The request sent to the API.
		 */
		do_action( 'bp_rest_document_details_get_items', $response, $request );

		return $response;
	}

Changelog

Changelog
Version Description
0.1.0 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.