title: how do I add a 'groups' custom claim to id_token issued by Cognito?
body: <p>I want to use a custom claim on an open id connect id_token to indicate the groups that the user belongs to.</p>
  
  <p>I have this working with Okta and Spring Security 5. With Okta there was a simple way to set-up a custom claim and associate it with a user's groups.</p>
  
  <p>Now I want to do the same with Cognito. </p>
  
  <p>How do I use Spring Securities group/role authorities in conjunction with Cognito?</p>
  
  <p>I have open id connect login working with Spring Security 5, Webflux &amp; Cognito but now I want to add some role based, group membership coarse-grained entitlements.</p>
  
  <p>I have added a custom attribute to my user-pool but can't see how to populate it.</p>
  
  <p>thanks</p>