CfnWorkspace

class aws_cdk.aws_grafana.CfnWorkspace(scope, id, *, account_access_type, authentication_providers, permission_type, client_token=None, data_sources=None, description=None, grafana_version=None, name=None, network_access_control=None, notification_destinations=None, organizational_units=None, organization_role_name=None, plugin_admin_enabled=None, role_arn=None, saml_configuration=None, stack_set_name=None, vpc_configuration=None)

Bases: CfnResource

Specifies a workspace .

In a workspace, you can create Grafana dashboards and visualizations to analyze your metrics, logs, and traces. You don’t have to build, package, or deploy any hardware to run the Grafana server.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-grafana-workspace.html

CloudformationResource:

AWS::Grafana::Workspace

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

cfn_workspace = grafana.CfnWorkspace(self, "MyCfnWorkspace",
    account_access_type="accountAccessType",
    authentication_providers=["authenticationProviders"],
    permission_type="permissionType",

    # the properties below are optional
    client_token="clientToken",
    data_sources=["dataSources"],
    description="description",
    grafana_version="grafanaVersion",
    name="name",
    network_access_control=grafana.CfnWorkspace.NetworkAccessControlProperty(
        prefix_list_ids=["prefixListIds"],
        vpce_ids=["vpceIds"]
    ),
    notification_destinations=["notificationDestinations"],
    organizational_units=["organizationalUnits"],
    organization_role_name="organizationRoleName",
    plugin_admin_enabled=False,
    role_arn="roleArn",
    saml_configuration=grafana.CfnWorkspace.SamlConfigurationProperty(
        idp_metadata=grafana.CfnWorkspace.IdpMetadataProperty(
            url="url",
            xml="xml"
        ),

        # the properties below are optional
        allowed_organizations=["allowedOrganizations"],
        assertion_attributes=grafana.CfnWorkspace.AssertionAttributesProperty(
            email="email",
            groups="groups",
            login="login",
            name="name",
            org="org",
            role="role"
        ),
        login_validity_duration=123,
        role_values=grafana.CfnWorkspace.RoleValuesProperty(
            admin=["admin"],
            editor=["editor"]
        )
    ),
    stack_set_name="stackSetName",
    vpc_configuration=grafana.CfnWorkspace.VpcConfigurationProperty(
        security_group_ids=["securityGroupIds"],
        subnet_ids=["subnetIds"]
    )
)
Parameters:
  • scope (Construct) – Scope in which this resource is defined.

  • id (str) – Construct identifier for this resource (unique in its scope).

  • account_access_type (str) – Specifies whether the workspace can access AWS resources in this AWS account only, or whether it can also access AWS resources in other accounts in the same organization. If this is ORGANIZATION , the OrganizationalUnits parameter specifies which organizational units the workspace can access.

  • authentication_providers (Sequence[str]) – Specifies whether this workspace uses SAML 2.0, AWS IAM Identity Center , or both to authenticate users for using the Grafana console within a workspace. For more information, see User authentication in Amazon Managed Grafana .

  • permission_type (str) – If this is SERVICE_MANAGED , and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use AWS data sources and notification channels. If this is CUSTOMER_MANAGED , you must manage those roles and permissions yourself. If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other AWS accounts in the organization, this parameter must be set to CUSTOMER_MANAGED . For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels . For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for AWS data sources and notification channels

  • client_token (Optional[str]) – A unique, case-sensitive, user-provided identifier to ensure the idempotency of the request.

  • data_sources (Optional[Sequence[str]]) – Specifies the AWS data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources. This list is only used when the workspace was created through the AWS console, and the permissionType is SERVICE_MANAGED .

  • description (Optional[str]) – The user-defined description of the workspace.

  • grafana_version (Optional[str]) – Specifies the version of Grafana to support in the workspace. Defaults to the latest version on create (for example, 9.4), or the current version of the workspace on update. Can only be used to upgrade (for example, from 8.4 to 9.4), not downgrade (for example, from 9.4 to 8.4). To know what versions are available to upgrade to for a specific workspace, see the ListVersions operation.

  • name (Optional[str]) – The name of the workspace.

  • network_access_control (Union[IResolvable, NetworkAccessControlProperty, Dict[str, Any], None]) – The configuration settings for network access to your workspace.

  • notification_destinations (Optional[Sequence[str]]) – The AWS notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

  • organizational_units (Optional[Sequence[str]]) – Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

  • organization_role_name (Optional[str]) – The name of the IAM role that is used to access resources through Organizations .

  • plugin_admin_enabled (Union[bool, IResolvable, None]) – Whether plugin administration is enabled in the workspace. Setting to true allows workspace admins to install, uninstall, and update plugins from within the Grafana workspace. .. epigraph:: This option is only valid for workspaces that support Grafana version 9 or newer.

  • role_arn (Optional[str]) – The IAM role that grants permissions to the AWS resources that the workspace will view data from. This role must already exist.

  • saml_configuration (Union[IResolvable, SamlConfigurationProperty, Dict[str, Any], None]) – If the workspace uses SAML, use this structure to map SAML assertion attributes to workspace user information and define which groups in the assertion attribute are to have the Admin and Editor roles in the workspace.

  • stack_set_name (Optional[str]) – The name of the AWS CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

  • vpc_configuration (Union[IResolvable, VpcConfigurationProperty, Dict[str, Any], None]) – The configuration settings for an Amazon VPC that contains data sources for your Grafana workspace to connect to. .. epigraph:: Connecting to a private VPC is not yet available in the Asia Pacific (Seoul) Region (ap-northeast-2).

Methods

add_deletion_override(path)

Syntactic sugar for addOverride(path, undefined).

Parameters:

path (str) – The path of the value to delete.

Return type:

None

add_dependency(target)

Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.

This can be used for resources across stacks (or nested stack) boundaries and the dependency will automatically be transferred to the relevant scope.

Parameters:

target (CfnResource) –

Return type:

None

add_depends_on(target)

(deprecated) Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.

Parameters:

target (CfnResource) –

Deprecated:

use addDependency

Stability:

deprecated

Return type:

None

add_metadata(key, value)

Add a value to the CloudFormation Resource Metadata.

Parameters:
  • key (str) –

  • value (Any) –

See:

Return type:

None

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html

Note that this is a different set of metadata from CDK node metadata; this metadata ends up in the stack template under the resource, whereas CDK node metadata ends up in the Cloud Assembly.

add_override(path, value)

Adds an override to the synthesized CloudFormation resource.

To add a property override, either use addPropertyOverride or prefix path with “Properties.” (i.e. Properties.TopicName).

If the override is nested, separate each nested level using a dot (.) in the path parameter. If there is an array as part of the nesting, specify the index in the path.

To include a literal . in the property name, prefix with a \. In most programming languages you will need to write this as "\\." because the \ itself will need to be escaped.

For example:

cfn_resource.add_override("Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes", ["myattribute"])
cfn_resource.add_override("Properties.GlobalSecondaryIndexes.1.ProjectionType", "INCLUDE")

would add the overrides Example:

"Properties": {
  "GlobalSecondaryIndexes": [
    {
      "Projection": {
        "NonKeyAttributes": [ "myattribute" ]
        ...
      }
      ...
    },
    {
      "ProjectionType": "INCLUDE"
      ...
    },
  ]
  ...
}

The value argument to addOverride will not be processed or translated in any way. Pass raw JSON values in here with the correct capitalization for CloudFormation. If you pass CDK classes or structs, they will be rendered with lowercased key names, and CloudFormation will reject the template.

Parameters:
  • path (str) –

    • The path of the property, you can use dot notation to override values in complex types. Any intermediate keys will be created as needed.

  • value (Any) –

    • The value. Could be primitive or complex.

Return type:

None

add_property_deletion_override(property_path)

Adds an override that deletes the value of a property from the resource definition.

Parameters:

property_path (str) – The path to the property.

Return type:

None

add_property_override(property_path, value)

Adds an override to a resource property.

Syntactic sugar for addOverride("Properties.<...>", value).

Parameters:
  • property_path (str) – The path of the property.

  • value (Any) – The value.

Return type:

None

apply_removal_policy(policy=None, *, apply_to_update_replace_policy=None, default=None)

Sets the deletion policy of the resource based on the removal policy specified.

The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you’ve removed it from the CDK application or because you’ve made a change that requires the resource to be replaced.

The resource can be deleted (RemovalPolicy.DESTROY), or left in your AWS account for data recovery and cleanup later (RemovalPolicy.RETAIN). In some cases, a snapshot can be taken of the resource prior to deletion (RemovalPolicy.SNAPSHOT). A list of resources that support this policy can be found in the following link:

Parameters:
  • policy (Optional[RemovalPolicy]) –

  • apply_to_update_replace_policy (Optional[bool]) – Apply the same deletion policy to the resource’s “UpdateReplacePolicy”. Default: true

  • default (Optional[RemovalPolicy]) – The default policy to apply in case the removal policy is not defined. Default: - Default value is resource specific. To determine the default value for a resource, please consult that specific resource’s documentation.

See:

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options

Return type:

None

get_att(attribute_name, type_hint=None)

Returns a token for an runtime attribute of this resource.

Ideally, use generated attribute accessors (e.g. resource.arn), but this can be used for future compatibility in case there is no generated attribute.

Parameters:
  • attribute_name (str) – The name of the attribute.

  • type_hint (Optional[ResolutionTypeHint]) –

Return type:

Reference

get_metadata(key)

Retrieve a value value from the CloudFormation Resource Metadata.

Parameters:

key (str) –

See:

Return type:

Any

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html

Note that this is a different set of metadata from CDK node metadata; this metadata ends up in the stack template under the resource, whereas CDK node metadata ends up in the Cloud Assembly.

inspect(inspector)

Examines the CloudFormation resource and discloses attributes.

Parameters:

inspector (TreeInspector) – tree inspector to collect and process attributes.

Return type:

None

obtain_dependencies()

Retrieves an array of resources this resource depends on.

This assembles dependencies on resources across stacks (including nested stacks) automatically.

Return type:

List[Union[Stack, CfnResource]]

obtain_resource_dependencies()

Get a shallow copy of dependencies between this resource and other resources in the same stack.

Return type:

List[CfnResource]

override_logical_id(new_logical_id)

Overrides the auto-generated logical ID with a specific ID.

Parameters:

new_logical_id (str) – The new logical ID to use for this stack element.

Return type:

None

remove_dependency(target)

Indicates that this resource no longer depends on another resource.

This can be used for resources across stacks (including nested stacks) and the dependency will automatically be removed from the relevant scope.

Parameters:

target (CfnResource) –

Return type:

None

replace_dependency(target, new_target)

Replaces one dependency with another.

Parameters:
Return type:

None

to_string()

Returns a string representation of this construct.

Return type:

str

Returns:

a string representation of this resource

Attributes

CFN_RESOURCE_TYPE_NAME = 'AWS::Grafana::Workspace'
account_access_type

Specifies whether the workspace can access AWS resources in this AWS account only, or whether it can also access AWS resources in other accounts in the same organization.

attr_creation_timestamp

The date that the workspace was created.

Type: Timestamp

CloudformationAttribute:

CreationTimestamp

attr_endpoint

The URL that users can use to access the Grafana console in the workspace.

Type: String

CloudformationAttribute:

Endpoint

attr_grafana_version

Specifies the version of Grafana supported by this workspace.

Type: String

CloudformationAttribute:

GrafanaVersion

attr_id

The unique ID of this workspace.

Type: String

CloudformationAttribute:

Id

attr_modification_timestamp

The most recent date that the workspace was modified.

Type: Timestamp

CloudformationAttribute:

ModificationTimestamp

attr_saml_configuration_status

Specifies whether the workspace’s SAML configuration is complete.

Valid values: CONFIGURED | NOT_CONFIGURED

Type: String

CloudformationAttribute:

SamlConfigurationStatus

attr_sso_client_id

The ID of the IAM Identity Center-managed application that is created by Amazon Managed Grafana .

Type: String

CloudformationAttribute:

SsoClientId

attr_status

The current status of the workspace.

Valid values: ACTIVE | CREATING | DELETING | FAILED | UPDATING | UPGRADING | DELETION_FAILED | CREATION_FAILED | UPDATE_FAILED | UPGRADE_FAILED | LICENSE_REMOVAL_FAILED

Type: String

CloudformationAttribute:

Status

authentication_providers

//docs.aws.amazon.com/grafana/latest/userguide/authentication-in-AMG.html>`_ .

Type:

Specifies whether this workspace uses SAML 2.0, AWS IAM Identity Center , or both to authenticate users for using the Grafana console within a workspace. For more information, see `User authentication in Amazon Managed Grafana <https

cfn_options

Options for this resource, such as condition, update policy etc.

cfn_resource_type

AWS resource type.

client_token

A unique, case-sensitive, user-provided identifier to ensure the idempotency of the request.

creation_stack

return:

the stack trace of the point where this Resource was created from, sourced from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most node +internal+ entries filtered.

data_sources

Specifies the AWS data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

description

The user-defined description of the workspace.

grafana_version

Specifies the version of Grafana to support in the workspace.

logical_id

The logical ID for this CloudFormation stack element.

The logical ID of the element is calculated from the path of the resource node in the construct tree.

To override this value, use overrideLogicalId(newLogicalId).

Returns:

the logical ID as a stringified token. This value will only get resolved during synthesis.

name

The name of the workspace.

network_access_control

The configuration settings for network access to your workspace.

node

The tree node.

notification_destinations

The AWS notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

organization_role_name

The name of the IAM role that is used to access resources through Organizations .

organizational_units

Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

permission_type

If this is SERVICE_MANAGED , and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use AWS data sources and notification channels.

plugin_admin_enabled

Whether plugin administration is enabled in the workspace.

ref

Return a string that will be resolved to a CloudFormation { Ref } for this element.

If, by any chance, the intrinsic reference of a resource is not a string, you could coerce it to an IResolvable through Lazy.any({ produce: resource.ref }).

role_arn

The IAM role that grants permissions to the AWS resources that the workspace will view data from.

saml_configuration

If the workspace uses SAML, use this structure to map SAML assertion attributes to workspace user information and define which groups in the assertion attribute are to have the Admin and Editor roles in the workspace.

stack

The stack in which this element is defined.

CfnElements must be defined within a stack scope (directly or indirectly).

stack_set_name

The name of the AWS CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

vpc_configuration

The configuration settings for an Amazon VPC that contains data sources for your Grafana workspace to connect to.

Static Methods

classmethod is_cfn_element(x)

Returns true if a construct is a stack element (i.e. part of the synthesized cloudformation template).

Uses duck-typing instead of instanceof to allow stack elements from different versions of this library to be included in the same stack.

Parameters:

x (Any) –

Return type:

bool

Returns:

The construct as a stack element or undefined if it is not a stack element.

classmethod is_cfn_resource(x)

Check whether the given object is a CfnResource.

Parameters:

x (Any) –

Return type:

bool

classmethod is_construct(x)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Construct.

AssertionAttributesProperty

class CfnWorkspace.AssertionAttributesProperty(*, email=None, groups=None, login=None, name=None, org=None, role=None)

Bases: object

A structure that defines which attributes in the IdP assertion are to be used to define information about the users authenticated by the IdP to use the workspace.

Parameters:
  • email (Optional[str]) – The name of the attribute within the SAML assertion to use as the email names for SAML users.

  • groups (Optional[str]) – The name of the attribute within the SAML assertion to use as the user full “friendly” names for user groups.

  • login (Optional[str]) – The name of the attribute within the SAML assertion to use as the login names for SAML users.

  • name (Optional[str]) – The name of the attribute within the SAML assertion to use as the user full “friendly” names for SAML users.

  • org (Optional[str]) – The name of the attribute within the SAML assertion to use as the user full “friendly” names for the users’ organizations.

  • role (Optional[str]) – The name of the attribute within the SAML assertion to use as the user roles.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

assertion_attributes_property = grafana.CfnWorkspace.AssertionAttributesProperty(
    email="email",
    groups="groups",
    login="login",
    name="name",
    org="org",
    role="role"
)

Attributes

email

The name of the attribute within the SAML assertion to use as the email names for SAML users.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-email

groups

The name of the attribute within the SAML assertion to use as the user full “friendly” names for user groups.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-groups

login

The name of the attribute within the SAML assertion to use as the login names for SAML users.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-login

name

The name of the attribute within the SAML assertion to use as the user full “friendly” names for SAML users.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-name

org

The name of the attribute within the SAML assertion to use as the user full “friendly” names for the users’ organizations.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-org

role

The name of the attribute within the SAML assertion to use as the user roles.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html#cfn-grafana-workspace-assertionattributes-role

IdpMetadataProperty

class CfnWorkspace.IdpMetadataProperty(*, url=None, xml=None)

Bases: object

A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

You can specify the metadata either by providing a URL to its location in the url parameter, or by specifying the full metadata in XML format in the xml parameter. Specifying both will cause an error.

Parameters:
  • url (Optional[str]) – The URL of the location containing the IdP metadata.

  • xml (Optional[str]) – The full IdP metadata, in XML format.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-idpmetadata.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

idp_metadata_property = grafana.CfnWorkspace.IdpMetadataProperty(
    url="url",
    xml="xml"
)

Attributes

url

The URL of the location containing the IdP metadata.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-idpmetadata.html#cfn-grafana-workspace-idpmetadata-url

xml

The full IdP metadata, in XML format.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-idpmetadata.html#cfn-grafana-workspace-idpmetadata-xml

NetworkAccessControlProperty

class CfnWorkspace.NetworkAccessControlProperty(*, prefix_list_ids=None, vpce_ids=None)

Bases: object

The configuration settings for in-bound network access to your workspace.

When this is configured, only listed IP addresses and VPC endpoints will be able to access your workspace. Standard Grafana authentication and authorization are still required.

Access is granted to a caller that is in either the IP address list or the VPC endpoint list - they do not need to be in both.

If this is not configured, or is removed, then all IP addresses and VPC endpoints are allowed. Standard Grafana authentication and authorization are still required. .. epigraph:

While both ``prefixListIds`` and ``vpceIds`` are required, you can pass in an empty array of strings for either parameter if you do not want to allow any of that type.

If both are passed as empty arrays, no traffic is allowed to the workspace, because only *explicitly* allowed connections are accepted.
Parameters:
  • prefix_list_ids (Optional[Sequence[str]]) – An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console. Prefix list IDs have the format pl- *1a2b3c4d* . For more information about prefix lists, see Group CIDR blocks using managed prefix lists in the Amazon Virtual Private Cloud User Guide .

  • vpce_ids (Optional[Sequence[str]]) – An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace. VPC endpoint IDs have the format vpce- *1a2b3c4d* . For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide . .. epigraph:: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-networkaccesscontrol.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

network_access_control_property = grafana.CfnWorkspace.NetworkAccessControlProperty(
    prefix_list_ids=["prefixListIds"],
    vpce_ids=["vpceIds"]
)

Attributes

prefix_list_ids

An array of prefix list IDs.

A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

Prefix list IDs have the format pl- *1a2b3c4d* .

For more information about prefix lists, see Group CIDR blocks using managed prefix lists in the Amazon Virtual Private Cloud User Guide .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-networkaccesscontrol.html#cfn-grafana-workspace-networkaccesscontrol-prefixlistids

vpce_ids

An array of Amazon VPC endpoint IDs for the workspace.

You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

VPC endpoint IDs have the format vpce- *1a2b3c4d* .

For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide . .. epigraph:

The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the ``com.amazonaws.[region].grafana-workspace`` service endpoint). Other VPC endpoints are ignored.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-networkaccesscontrol.html#cfn-grafana-workspace-networkaccesscontrol-vpceids

RoleValuesProperty

class CfnWorkspace.RoleValuesProperty(*, admin=None, editor=None)

Bases: object

This structure defines which groups defined in the SAML assertion attribute are to be mapped to the Grafana Admin and Editor roles in the workspace.

SAML authenticated users not part of Admin or Editor role groups have Viewer permission over the workspace.

Parameters:
  • admin (Optional[Sequence[str]]) – A list of groups from the SAML assertion attribute to grant the Grafana Admin role to.

  • editor (Optional[Sequence[str]]) – A list of groups from the SAML assertion attribute to grant the Grafana Editor role to.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-rolevalues.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

role_values_property = grafana.CfnWorkspace.RoleValuesProperty(
    admin=["admin"],
    editor=["editor"]
)

Attributes

admin

A list of groups from the SAML assertion attribute to grant the Grafana Admin role to.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-rolevalues.html#cfn-grafana-workspace-rolevalues-admin

editor

A list of groups from the SAML assertion attribute to grant the Grafana Editor role to.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-rolevalues.html#cfn-grafana-workspace-rolevalues-editor

SamlConfigurationProperty

class CfnWorkspace.SamlConfigurationProperty(*, idp_metadata, allowed_organizations=None, assertion_attributes=None, login_validity_duration=None, role_values=None)

Bases: object

A structure containing information about how this workspace works with SAML.

Parameters:
  • idp_metadata (Union[IResolvable, IdpMetadataProperty, Dict[str, Any]]) – A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

  • allowed_organizations (Optional[Sequence[str]]) – Lists which organizations defined in the SAML assertion are allowed to use the Amazon Managed Grafana workspace. If this is empty, all organizations in the assertion attribute have access.

  • assertion_attributes (Union[IResolvable, AssertionAttributesProperty, Dict[str, Any], None]) – A structure that defines which attributes in the SAML assertion are to be used to define information about the users authenticated by that IdP to use the workspace.

  • login_validity_duration (Union[int, float, None]) – How long a sign-on session by a SAML user is valid, before the user has to sign on again.

  • role_values (Union[IResolvable, RoleValuesProperty, Dict[str, Any], None]) – A structure containing arrays that map group names in the SAML assertion to the Grafana Admin and Editor roles in the workspace.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

saml_configuration_property = grafana.CfnWorkspace.SamlConfigurationProperty(
    idp_metadata=grafana.CfnWorkspace.IdpMetadataProperty(
        url="url",
        xml="xml"
    ),

    # the properties below are optional
    allowed_organizations=["allowedOrganizations"],
    assertion_attributes=grafana.CfnWorkspace.AssertionAttributesProperty(
        email="email",
        groups="groups",
        login="login",
        name="name",
        org="org",
        role="role"
    ),
    login_validity_duration=123,
    role_values=grafana.CfnWorkspace.RoleValuesProperty(
        admin=["admin"],
        editor=["editor"]
    )
)

Attributes

allowed_organizations

Lists which organizations defined in the SAML assertion are allowed to use the Amazon Managed Grafana workspace.

If this is empty, all organizations in the assertion attribute have access.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html#cfn-grafana-workspace-samlconfiguration-allowedorganizations

assertion_attributes

A structure that defines which attributes in the SAML assertion are to be used to define information about the users authenticated by that IdP to use the workspace.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html#cfn-grafana-workspace-samlconfiguration-assertionattributes

idp_metadata

A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html#cfn-grafana-workspace-samlconfiguration-idpmetadata

login_validity_duration

How long a sign-on session by a SAML user is valid, before the user has to sign on again.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html#cfn-grafana-workspace-samlconfiguration-loginvalidityduration

role_values

A structure containing arrays that map group names in the SAML assertion to the Grafana Admin and Editor roles in the workspace.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-samlconfiguration.html#cfn-grafana-workspace-samlconfiguration-rolevalues

VpcConfigurationProperty

class CfnWorkspace.VpcConfigurationProperty(*, security_group_ids, subnet_ids)

Bases: object

The configuration settings for an Amazon VPC that contains data sources for your Grafana workspace to connect to.

Provided securityGroupIds and subnetIds must be part of the same VPC.

Connecting to a private VPC is not yet available in the Asia Pacific (Seoul) Region (ap-northeast-2).

Parameters:
  • security_group_ids (Sequence[str]) – The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed. Array Members : Minimum number of 1 items. Maximum number of 5 items. Length : Minimum length of 0. Maximum length of 255.

  • subnet_ids (Sequence[str]) – The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed. Array Members : Minimum number of 2 items. Maximum number of 6 items. Length : Minimum length of 0. Maximum length of 255.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-vpcconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_grafana as grafana

vpc_configuration_property = grafana.CfnWorkspace.VpcConfigurationProperty(
    security_group_ids=["securityGroupIds"],
    subnet_ids=["subnetIds"]
)

Attributes

security_group_ids

The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect.

Duplicates not allowed.

Array Members : Minimum number of 1 items. Maximum number of 5 items.

Length : Minimum length of 0. Maximum length of 255.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-vpcconfiguration.html#cfn-grafana-workspace-vpcconfiguration-securitygroupids

subnet_ids

The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect.

Duplicates not allowed.

Array Members : Minimum number of 2 items. Maximum number of 6 items.

Length : Minimum length of 0. Maximum length of 255.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-vpcconfiguration.html#cfn-grafana-workspace-vpcconfiguration-subnetids