AWS Verified Access Terraform Code for Verified Access groups Not workingaw

I am trying to implement AWS-verified access using Terraform and while writing the group policy rule I am facing issue

Below is error message:
“api error InvalidParameterValue: PolicyDocument is invalid”

Below is the [Cedar] policy document worked when added manually:

permit(principal,action,resource)
when {
context.okta_trust_provider.email_verified == true
};

This is the corresponding Terraform Code:

policy_document = <<EOT
permit(principal,action,resource)
when {
context.chp-dev-okta-verified-access-trust-provider-02.email_verified == true
};
EOT

Can anyone suggest on this