https://serverless-stack.com/ logo
#help
Title
# help
s

Sam

11/24/2021, 3:06 PM
Is it safe to use AWS cdk constructs within a serverless stack app? I want to make a user pool group and from what I understand there isn’t a way to add one within serverless stack so I used the
CfnUserPoolGroup
. It seems to be working but want to make sure it wont cause any problems down the line. I’m new to SST so thank you in advance!
Copy code
this.auth = new sst.Auth(this, "Auth", {
  cognito: {
    userPool: userPoolConfiguration,

    // Cognito triggers to run Lambdas
    triggers: {
      postConfirmation: postConfirmationConfiguration,
    },
  },
});

new CfnUserPoolGroup(this, "UserPoolAdminGroup", {
  userPoolId: this.auth.cognitoUserPool.userPoolId,

  description: "Administrator user group. Full access.",
  groupName: "admin",
});
t

thdxr

11/24/2021, 3:10 PM
Yes you can use any valid cdk code inside an sst app
s

Sam

11/24/2021, 3:10 PM
Good to know. Thank you!
4 Views