BP_REST_Document_Folder_Endpoint::get_item_schema()

Get the document folder schema, conforming to JSON Schema.

Description

Return

(array)

Source

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

1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
public function get_item_schema() {
    $schema = array(
        '$schema'    => 'http://json-schema.org/draft-04/schema#',
        'title'      => 'bp_document_folder',
        'type'       => 'object',
        'properties' => array(),
    );
 
    $schema['properties'] = $this->document_endpoint->get_item_schema()['properties'];
 
    /**
     * Filters the document schema.
     *
     * @param array $schema The endpoint schema.
     */
    return apply_filters( 'bp_rest_document_schema', $this->add_additional_fields_schema( $schema ) );
}

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.