# elementor/3.5.3/includes/template-library/data/endpoints/templates.php

Elementor Website Builder – more than just a page builder, version 3.5.3. 24 lines.

- Page: https://pluginprobe.com/plugins/elementor/3.5.3/code/includes/template-library/data/endpoints/templates.php
- Raw: https://pluginprobe.com/plugins/elementor/3.5.3/raw/includes/template-library/data/endpoints/templates.php
- Modified: 2021-11-17T08:27:36+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/elementor/3.5.3/code/includes/template-library/data/endpoints/templates.php#L10-L20`.

```php
<?php
namespace Elementor\Includes\TemplateLibrary\Data\Endpoints;

use Elementor\Data\V2\Base\Endpoint;
use Elementor\Plugin;

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}

class Templates extends Endpoint {
	public function get_name() {
		return 'templates';
	}

	public function get_format() {
		return 'template-library/templates';
	}

	public function get_items( $request ) {
		return Plugin::$instance->templates_manager->get_library_data( [ 'filter_sources' => [ $request->get_param( 'source' ) ] ] );
	}
}

```
