AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::ResourceExplorer2::View

CfnView

Creates a view that users can query by using the [Search](https://docs.aws.amazon.com/resource-explorer/latest/apireference/API_Search.html) operation. Results from queries that you make using this view include only resources that match the view's `Filters` .

Import

import { CfnView } from 'aws-cdk-lib/aws-resourceexplorer2';

Or use the module namespace:

import * as resourceexplorer2 from 'aws-cdk-lib/aws-resourceexplorer2';
// resourceexplorer2.CfnView

Properties

Configuration passed to the constructor as CfnViewProps.

viewNameRequired
string

The name of the new view.

filtersOptional
IResolvable | FiltersProperty

An array of strings that include search keywords, prefixes, and operators that filter the results that are returned for queries made using this view. When you use this view in a [Search](https://docs.aws.amazon.com/resource-explorer/latest/apireference/API_Search.html) operation, the filter string is combined with the search's `QueryString` parameter using a logical `AND` operator. For information about the supported syntax, see [Search query reference for Resource Explorer](https://docs.aws.amazon.com/resource-explorer/latest/userguide/using-search-query-syntax.html) in the *AWS Resource Explorer User Guide* . > This query string in the context of this operation supports only [filter prefixes](https://docs.aws.amazon.com/resource-explorer/latest/userguide/using-search-query-syntax.html#query-syntax-filters) with optional [operators](https://docs.aws.amazon.com/resource-explorer/latest/userguide/using-search-query-syntax.html#query-syntax-operators) . It doesn't support free-form text. For example, the string `region:us* service:ec2 -tag:stage=prod` includes all Amazon EC2 resources in any AWS Region that begin with the letters `us` and are *not* tagged with a key `Stage` that has the value `prod` .

includedPropertiesOptional
IResolvable | IResolvable | IncludedPropertyProperty[]

A list of fields that provide additional information about the view.

scopeOptional
string

The root ARN of the account, an organizational unit (OU), or an organization ARN. If left empty, the default is account.

tagsOptional
{ [key: string]: string }

Tag key and value pairs that are attached to the view.

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter

Quick Facts

LevelL1 (CloudFormation)
Moduleaws-resourceexplorer2
CFN TypeAWS::ResourceExplorer2::View
Properties5

Related Constructs

External Links