public function get_item_schema() {

		$schema = parent::get_item_schema();

		$schema['properties']['alt_text'] = array(
			'description'     => __( 'Alternative text to display when resource is not displayed.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit', 'embed' ),
			'arg_options'     => array(
				'sanitize_callback' => 'sanitize_text_field',
			),
		);
		$schema['properties']['caption'] = array(
			'description'     => __( 'The caption for the resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit' ),
			'arg_options'     => array(
				'sanitize_callback' => 'wp_filter_post_kses',
			),
		);
		$schema['properties']['description'] = array(
			'description'     => __( 'The description for the resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit' ),
			'arg_options'     => array(
				'sanitize_callback' => 'wp_filter_post_kses',
			),
		);
		$schema['properties']['media_type'] = array(
			'description'     => __( 'Type of resource.' ),
			'type'            => 'string',
			'enum'            => array( 'image', 'file' ),
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['mime_type'] = array(
			'description'     => __( 'MIME type of resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['media_details'] = array(
			'description'     => __( 'Details about the resource file, specific to its type.' ),
			'type'            => 'object',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['post'] = array(
			'description'     => __( 'The id for the associated post of the resource.' ),
			'type'            => 'integer',
			'context'         => array( 'view', 'edit' ),
		);
		$schema['properties']['source_url'] = array(
			'description'     => __( 'URL to the original resource file.' ),
			'type'            => 'string',
			'format'          => 'uri',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		return $schema;
	}
public function get_item_schema() {

		$schema = parent::get_item_schema();

		$schema['properties']['alt_text'] = array(
			'description'     => __( 'Alternative text to display when resource is not displayed.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit', 'embed' ),
			'arg_options'     => array(
				'sanitize_callback' => 'sanitize_text_field',
			),
		);
		$schema['properties']['caption'] = array(
			'description'     => __( 'The caption for the resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit' ),
			'arg_options'     => array(
				'sanitize_callback' => 'wp_filter_post_kses',
			),
		);
		$schema['properties']['description'] = array(
			'description'     => __( 'The description for the resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit' ),
			'arg_options'     => array(
				'sanitize_callback' => 'wp_filter_post_kses',
			),
		);
		$schema['properties']['media_type'] = array(
			'description'     => __( 'Type of resource.' ),
			'type'            => 'string',
			'enum'            => array( 'image', 'file' ),
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['mime_type'] = array(
			'description'     => __( 'MIME type of resource.' ),
			'type'            => 'string',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['media_details'] = array(
			'description'     => __( 'Details about the resource file, specific to its type.' ),
			'type'            => 'object',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		$schema['properties']['post'] = array(
			'description'     => __( 'The id for the associated post of the resource.' ),
			'type'            => 'integer',
			'context'         => array( 'view', 'edit' ),
		);
		$schema['properties']['source_url'] = array(
			'description'     => __( 'URL to the original resource file.' ),
			'type'            => 'string',
			'format'          => 'uri',
			'context'         => array( 'view', 'edit', 'embed' ),
			'readonly'        => true,
		);
		return $schema;
	}
public function get_item_schema ( ) { $ schema = parent :: get_item_schema ( ) ; $ schema [ 'properties' ] [ 'alt_text' ] = array ( 'description' => __ ( 'Alternative text to display when resource is not displayed.' ) , 'type' => 'string' , 'context' => array ( 'view' , 'edit' , 'embed' ) , 'arg_options' => array ( 'sanitize_callback' => 'sanitize_text_field' , ) , ) ; $ schema [ 'properties' ] [ 'caption' ] = array ( 'description' => __ ( 'The caption for the resource.' ) , 'type' => 'string' , 'context' => array ( 'view' , 'edit' ) , 'arg_options' => array ( 'sanitize_callback' => 'wp_filter_post_kses' , ) , ) ; $ schema [ 'properties' ] [ 'description' ] = array ( 'description' => __ ( 'The description for the resource.' ) , 'type' => 'string' , 'context' => array ( 'view' , 'edit' ) , 'arg_options' => array ( 'sanitize_callback' => 'wp_filter_post_kses' , ) , ) ; $ schema [ 'properties' ] [ 'media_type' ] = array ( 'description' => __ ( 'Type of resource.' ) , 'type' => 'string' , 'enum' => array ( 'image' , 'file' ) , 'context' => array ( 'view' , 'edit' , 'embed' ) , 'readonly' => true , ) ; $ schema [ 'properties' ] [ 'mime_type' ] = array ( 'description' => __ ( 'MIME type of resource.' ) , 'type' => 'string' , 'context' => array ( 'view' , 'edit' , 'embed' ) , 'readonly' => true , ) ; $ schema [ 'properties' ] [ 'media_details' ] = array ( 'description' => __ ( 'Details about the resource file, specific to its type.' ) , 'type' => 'object' , 'context' => array ( 'view' , 'edit' , 'embed' ) , 'readonly' => true , ) ; $ schema [ 'properties' ] [ 'post' ] = array ( 'description' => __ ( 'The id for the associated post of the resource.' ) , 'type' => 'integer' , 'context' => array ( 'view' , 'edit' ) , ) ; $ schema [ 'properties' ] [ 'source_url' ] = array ( 'description' => __ ( 'URL to the original resource file.' ) , 'type' => 'string' , 'format' => 'uri' , 'context' => array ( 'view' , 'edit' , 'embed' ) , 'readonly' => true , ) ; return $ schema ; }
Get the Attachment's schema, conforming to JSON Schema.

@return array Item schema as an array.
Get the Attachment s schema conforming to JSON Schema .