Skip to content
v2.276.0

CfnWorkspaceProps Struct ​

Properties for defining a CfnWorkspace.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_connect as connect } from 'aws-cdk-lib';
const cfnWorkspaceProps: connect.CfnWorkspaceProps = {
  instanceArn: 'instanceArn',
  name: 'name',

  // the properties below are optional
  associations: ['associations'],
  description: 'description',
  media: [{
    type: 'type',

    // the properties below are optional
    source: 'source',
  }],
  pages: [{
    page: 'page',
    resourceArn: 'resourceArn',

    // the properties below are optional
    inputData: 'inputData',
    slug: 'slug',
  }],
  tags: [{
    key: 'key',
    value: 'value',
  }],
  theme: {
    dark: {
      palette: {
        canvas: {
          activeBackground: 'activeBackground',
          containerBackground: 'containerBackground',
          pageBackground: 'pageBackground',
        },
        header: {
          background: 'background',
          invertActionsColors: false,
          text: 'text',
          textHover: 'textHover',
        },
        navigation: {
          background: 'background',
          invertActionsColors: false,
          text: 'text',
          textActive: 'textActive',
          textBackgroundActive: 'textBackgroundActive',
          textBackgroundHover: 'textBackgroundHover',
          textHover: 'textHover',
        },
        primary: {
          active: 'active',
          contrastText: 'contrastText',
          default: 'default',
        },
      },
      typography: {
        fontFamily: {
          default: 'default',
        },
      },
    },
    light: {
      palette: {
        canvas: {
          activeBackground: 'activeBackground',
          containerBackground: 'containerBackground',
          pageBackground: 'pageBackground',
        },
        header: {
          background: 'background',
          invertActionsColors: false,
          text: 'text',
          textHover: 'textHover',
        },
        navigation: {
          background: 'background',
          invertActionsColors: false,
          text: 'text',
          textActive: 'textActive',
          textBackgroundActive: 'textBackgroundActive',
          textBackgroundHover: 'textBackgroundHover',
          textHover: 'textHover',
        },
        primary: {
          active: 'active',
          contrastText: 'contrastText',
          default: 'default',
        },
      },
      typography: {
        fontFamily: {
          default: 'default',
        },
      },
    },
  },
  title: 'title',
  visibility: 'visibility',
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_connect as connect

cfn_workspace_props = connect.CfnWorkspaceProps(
    instance_arn="instanceArn",
    name="name",

    # the properties below are optional
    associations=["associations"],
    description="description",
    media=[connect.CfnWorkspace.MediaItemProperty(
        type="type",

        # the properties below are optional
        source="source"
    )],
    pages=[connect.CfnWorkspace.WorkspacePageProperty(
        page="page",
        resource_arn="resourceArn",

        # the properties below are optional
        input_data="inputData",
        slug="slug"
    )],
    tags=[CfnTag(
        key="key",
        value="value"
    )],
    theme=connect.CfnWorkspace.WorkspaceThemeProperty(
        dark=connect.CfnWorkspace.WorkspaceThemeConfigProperty(
            palette=connect.CfnWorkspace.WorkspaceThemePaletteProperty(
                canvas=connect.CfnWorkspace.PaletteCanvasProperty(
                    active_background="activeBackground",
                    container_background="containerBackground",
                    page_background="pageBackground"
                ),
                header=connect.CfnWorkspace.PaletteHeaderProperty(
                    background="background",
                    invert_actions_colors=False,
                    text="text",
                    text_hover="textHover"
                ),
                navigation=connect.CfnWorkspace.PaletteNavigationProperty(
                    background="background",
                    invert_actions_colors=False,
                    text="text",
                    text_active="textActive",
                    text_background_active="textBackgroundActive",
                    text_background_hover="textBackgroundHover",
                    text_hover="textHover"
                ),
                primary=connect.CfnWorkspace.PalettePrimaryProperty(
                    active="active",
                    contrast_text="contrastText",
                    default="default"
                )
            ),
            typography=connect.CfnWorkspace.WorkspaceThemeTypographyProperty(
                font_family=connect.CfnWorkspace.FontFamilyProperty(
                    default="default"
                )
            )
        ),
        light=connect.CfnWorkspace.WorkspaceThemeConfigProperty(
            palette=connect.CfnWorkspace.WorkspaceThemePaletteProperty(
                canvas=connect.CfnWorkspace.PaletteCanvasProperty(
                    active_background="activeBackground",
                    container_background="containerBackground",
                    page_background="pageBackground"
                ),
                header=connect.CfnWorkspace.PaletteHeaderProperty(
                    background="background",
                    invert_actions_colors=False,
                    text="text",
                    text_hover="textHover"
                ),
                navigation=connect.CfnWorkspace.PaletteNavigationProperty(
                    background="background",
                    invert_actions_colors=False,
                    text="text",
                    text_active="textActive",
                    text_background_active="textBackgroundActive",
                    text_background_hover="textBackgroundHover",
                    text_hover="textHover"
                ),
                primary=connect.CfnWorkspace.PalettePrimaryProperty(
                    active="active",
                    contrast_text="contrastText",
                    default="default"
                )
            ),
            typography=connect.CfnWorkspace.WorkspaceThemeTypographyProperty(
                font_family=connect.CfnWorkspace.FontFamilyProperty(
                    default="default"
                )
            )
        )
    ),
    title="title",
    visibility="visibility"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.connect.*;

CfnWorkspaceProps cfnWorkspaceProps = CfnWorkspaceProps.builder()
        .instanceArn("instanceArn")
        .name("name")

        // the properties below are optional
        .associations(List.of("associations"))
        .description("description")
        .media(List.of(MediaItemProperty.builder()
                .type("type")

                // the properties below are optional
                .source("source")
                .build()))
        .pages(List.of(WorkspacePageProperty.builder()
                .page("page")
                .resourceArn("resourceArn")

                // the properties below are optional
                .inputData("inputData")
                .slug("slug")
                .build()))
        .tags(List.of(CfnTag.builder()
                .key("key")
                .value("value")
                .build()))
        .theme(WorkspaceThemeProperty.builder()
                .dark(WorkspaceThemeConfigProperty.builder()
                        .palette(WorkspaceThemePaletteProperty.builder()
                                .canvas(PaletteCanvasProperty.builder()
                                        .activeBackground("activeBackground")
                                        .containerBackground("containerBackground")
                                        .pageBackground("pageBackground")
                                        .build())
                                .header(PaletteHeaderProperty.builder()
                                        .background("background")
                                        .invertActionsColors(false)
                                        .text("text")
                                        .textHover("textHover")
                                        .build())
                                .navigation(PaletteNavigationProperty.builder()
                                        .background("background")
                                        .invertActionsColors(false)
                                        .text("text")
                                        .textActive("textActive")
                                        .textBackgroundActive("textBackgroundActive")
                                        .textBackgroundHover("textBackgroundHover")
                                        .textHover("textHover")
                                        .build())
                                .primary(PalettePrimaryProperty.builder()
                                        .active("active")
                                        .contrastText("contrastText")
                                        .default("default")
                                        .build())
                                .build())
                        .typography(WorkspaceThemeTypographyProperty.builder()
                                .fontFamily(FontFamilyProperty.builder()
                                        .default("default")
                                        .build())
                                .build())
                        .build())
                .light(WorkspaceThemeConfigProperty.builder()
                        .palette(WorkspaceThemePaletteProperty.builder()
                                .canvas(PaletteCanvasProperty.builder()
                                        .activeBackground("activeBackground")
                                        .containerBackground("containerBackground")
                                        .pageBackground("pageBackground")
                                        .build())
                                .header(PaletteHeaderProperty.builder()
                                        .background("background")
                                        .invertActionsColors(false)
                                        .text("text")
                                        .textHover("textHover")
                                        .build())
                                .navigation(PaletteNavigationProperty.builder()
                                        .background("background")
                                        .invertActionsColors(false)
                                        .text("text")
                                        .textActive("textActive")
                                        .textBackgroundActive("textBackgroundActive")
                                        .textBackgroundHover("textBackgroundHover")
                                        .textHover("textHover")
                                        .build())
                                .primary(PalettePrimaryProperty.builder()
                                        .active("active")
                                        .contrastText("contrastText")
                                        .default("default")
                                        .build())
                                .build())
                        .typography(WorkspaceThemeTypographyProperty.builder()
                                .fontFamily(FontFamilyProperty.builder()
                                        .default("default")
                                        .build())
                                .build())
                        .build())
                .build())
        .title("title")
        .visibility("visibility")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Connect;

var cfnWorkspaceProps = new CfnWorkspaceProps {
    InstanceArn = "instanceArn",
    Name = "name",

    // the properties below are optional
    Associations = new [] { "associations" },
    Description = "description",
    Media = new [] { new MediaItemProperty {
        Type = "type",

        // the properties below are optional
        Source = "source"
    } },
    Pages = new [] { new WorkspacePageProperty {
        Page = "page",
        ResourceArn = "resourceArn",

        // the properties below are optional
        InputData = "inputData",
        Slug = "slug"
    } },
    Tags = new [] { new CfnTag {
        Key = "key",
        Value = "value"
    } },
    Theme = new WorkspaceThemeProperty {
        Dark = new WorkspaceThemeConfigProperty {
            Palette = new WorkspaceThemePaletteProperty {
                Canvas = new PaletteCanvasProperty {
                    ActiveBackground = "activeBackground",
                    ContainerBackground = "containerBackground",
                    PageBackground = "pageBackground"
                },
                Header = new PaletteHeaderProperty {
                    Background = "background",
                    InvertActionsColors = false,
                    Text = "text",
                    TextHover = "textHover"
                },
                Navigation = new PaletteNavigationProperty {
                    Background = "background",
                    InvertActionsColors = false,
                    Text = "text",
                    TextActive = "textActive",
                    TextBackgroundActive = "textBackgroundActive",
                    TextBackgroundHover = "textBackgroundHover",
                    TextHover = "textHover"
                },
                Primary = new PalettePrimaryProperty {
                    Active = "active",
                    ContrastText = "contrastText",
                    Default = "default"
                }
            },
            Typography = new WorkspaceThemeTypographyProperty {
                FontFamily = new FontFamilyProperty {
                    Default = "default"
                }
            }
        },
        Light = new WorkspaceThemeConfigProperty {
            Palette = new WorkspaceThemePaletteProperty {
                Canvas = new PaletteCanvasProperty {
                    ActiveBackground = "activeBackground",
                    ContainerBackground = "containerBackground",
                    PageBackground = "pageBackground"
                },
                Header = new PaletteHeaderProperty {
                    Background = "background",
                    InvertActionsColors = false,
                    Text = "text",
                    TextHover = "textHover"
                },
                Navigation = new PaletteNavigationProperty {
                    Background = "background",
                    InvertActionsColors = false,
                    Text = "text",
                    TextActive = "textActive",
                    TextBackgroundActive = "textBackgroundActive",
                    TextBackgroundHover = "textBackgroundHover",
                    TextHover = "textHover"
                },
                Primary = new PalettePrimaryProperty {
                    Active = "active",
                    ContrastText = "contrastText",
                    Default = "default"
                }
            },
            Typography = new WorkspaceThemeTypographyProperty {
                FontFamily = new FontFamilyProperty {
                    Default = "default"
                }
            }
        }
    },
    Title = "title",
    Visibility = "visibility"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnWorkspaceProps := &CfnWorkspaceProps{
	InstanceArn: jsii.String("instanceArn"),
	Name: jsii.String("name"),

	// the properties below are optional
	Associations: []*string{
		jsii.String("associations"),
	},
	Description: jsii.String("description"),
	Media: []interface{}{
		&MediaItemProperty{
			Type: jsii.String("type"),

			// the properties below are optional
			Source: jsii.String("source"),
		},
	},
	Pages: []interface{}{
		&WorkspacePageProperty{
			Page: jsii.String("page"),
			ResourceArn: jsii.String("resourceArn"),

			// the properties below are optional
			InputData: jsii.String("inputData"),
			Slug: jsii.String("slug"),
		},
	},
	Tags: []CfnTag{
		&CfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
	Theme: &WorkspaceThemeProperty{
		Dark: &WorkspaceThemeConfigProperty{
			Palette: &WorkspaceThemePaletteProperty{
				Canvas: &PaletteCanvasProperty{
					ActiveBackground: jsii.String("activeBackground"),
					ContainerBackground: jsii.String("containerBackground"),
					PageBackground: jsii.String("pageBackground"),
				},
				Header: &PaletteHeaderProperty{
					Background: jsii.String("background"),
					InvertActionsColors: jsii.Boolean(false),
					Text: jsii.String("text"),
					TextHover: jsii.String("textHover"),
				},
				Navigation: &PaletteNavigationProperty{
					Background: jsii.String("background"),
					InvertActionsColors: jsii.Boolean(false),
					Text: jsii.String("text"),
					TextActive: jsii.String("textActive"),
					TextBackgroundActive: jsii.String("textBackgroundActive"),
					TextBackgroundHover: jsii.String("textBackgroundHover"),
					TextHover: jsii.String("textHover"),
				},
				Primary: &PalettePrimaryProperty{
					Active: jsii.String("active"),
					ContrastText: jsii.String("contrastText"),
					Default: jsii.String("default"),
				},
			},
			Typography: &WorkspaceThemeTypographyProperty{
				FontFamily: &FontFamilyProperty{
					Default: jsii.String("default"),
				},
			},
		},
		Light: &WorkspaceThemeConfigProperty{
			Palette: &WorkspaceThemePaletteProperty{
				Canvas: &PaletteCanvasProperty{
					ActiveBackground: jsii.String("activeBackground"),
					ContainerBackground: jsii.String("containerBackground"),
					PageBackground: jsii.String("pageBackground"),
				},
				Header: &PaletteHeaderProperty{
					Background: jsii.String("background"),
					InvertActionsColors: jsii.Boolean(false),
					Text: jsii.String("text"),
					TextHover: jsii.String("textHover"),
				},
				Navigation: &PaletteNavigationProperty{
					Background: jsii.String("background"),
					InvertActionsColors: jsii.Boolean(false),
					Text: jsii.String("text"),
					TextActive: jsii.String("textActive"),
					TextBackgroundActive: jsii.String("textBackgroundActive"),
					TextBackgroundHover: jsii.String("textBackgroundHover"),
					TextHover: jsii.String("textHover"),
				},
				Primary: &PalettePrimaryProperty{
					Active: jsii.String("active"),
					ContrastText: jsii.String("contrastText"),
					Default: jsii.String("default"),
				},
			},
			Typography: &WorkspaceThemeTypographyProperty{
				FontFamily: &FontFamilyProperty{
					Default: jsii.String("default"),
				},
			},
		},
	},
	Title: jsii.String("title"),
	Visibility: jsii.String("visibility"),
}

Properties ​

associationsoptionalstring[]associationsoptionaltyping.List[str]associationsoptionalList<String>Associationsoptionalstring[]Associationsoptional*[]*string#
The resource ARNs associated with the workspace.
descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string#
The description of the workspace.
instanceArnstringinstance_arnstrinstanceArnStringInstanceArnstringInstanceArn*stringrequired#
The Amazon Resource Name (ARN) of the instance.
mediaoptionalIResolvable | IResolvable | CfnWorkspace.MediaItemProperty[]mediaoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, MediaItemProperty]]]mediaoptionalIResolvableMediaoptionalIResolvableMediaoptionalinterface{}#
The media items for the workspace.
namestringnamestrnameStringNamestringName*stringrequired#
The name of the workspace.
pagesoptionalIResolvable | IResolvable | CfnWorkspace.WorkspacePageProperty[]pagesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, WorkspacePageProperty]]]pagesoptionalIResolvablePagesoptionalIResolvablePagesoptionalinterface{}#
The pages associated with the workspace.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag#
The tags used to organize, track, or control access for the workspace.
themeoptionalIResolvable | CfnWorkspace.WorkspaceThemePropertythemeoptionaltyping.Union[IResolvable, WorkspaceThemeProperty]themeoptionalIResolvableThemeoptionalIResolvableThemeoptionalinterface{}#
The theme configuration for the workspace, including colors and styling.
titleoptionalstringtitleoptionalstrtitleoptionalStringTitleoptionalstringTitleoptional*string#
The title displayed for the workspace.
visibilityoptionalstringvisibilityoptionalstrvisibilityoptionalStringVisibilityoptionalstringVisibilityoptional*string#
Controls who can access the workspace.

Valid values are: ALL (all users), ASSIGNED (only assigned users and routing profiles), and NONE (not visible).