in lib/custom_resources/create_and_attach_scp.py [0:0]
def create_policies(event):
LOGGER.info("Invoking the CreateSCPs")
# Get the S3 bucket
s3_bucket = get_s3_bucket_name(event)
# Get the ORG role
org_role = get_org_role()
# Assume role using the ORG role for editing the SCPs
setup = assume_role(org_role, "CreateSCPs")
org_client = setup.client('organizations')
create_or_attach_scps(org_session=org_client, bucket_name=s3_bucket)