Amazon cognito 获取价值';[代币]';at';允许的OAuthFlows';未能满足约束错误

Amazon cognito 获取价值';[代币]';at';允许的OAuthFlows';未能满足约束错误,amazon-cognito,aws-cdk,aws-userpools,Amazon Cognito,Aws Cdk,Aws Userpools,我正在尝试使用AWS CDK创建AWS用户池客户端。我正在使用python代码进行此操作。 下面是我的代码- oAuthScopes = ["access-db-data"] supportedIdentityProviders = ["COGNITO"] allowedOAuthFlows = ["Token"] cognito_userpool_clients = _cognito.CfnUserPoolClient(stack, id="user-pool-cli

我正在尝试使用AWS CDK创建AWS用户池客户端。我正在使用python代码进行此操作。 下面是我的代码-

oAuthScopes = ["access-db-data"]
    supportedIdentityProviders = ["COGNITO"]
    allowedOAuthFlows = ["Token"]

    cognito_userpool_clients = _cognito.CfnUserPoolClient(stack, id="user-pool-client-id", user_pool_id="****", client_name="client-name", 
            generate_secret=True, allowed_o_auth_scopes=oAuthScopes, supported_identity_providers=supportedIdentityProviders, allowed_o_auth_flows=allowedOAuthFlows, allowed_o_auth_flows_user_pool_client=True)
我尝试了不同的选项,将allowedOAuthFlows值设置为“TOKEN”、“TOKEN”、“CODE”、“CODE”、“CODE”。但它仍然不起作用。对于以上代码,我得到以下错误-

validation error detected: Value '[Token]' at 'allowedOAuthFlows' failed to satisfy constraint: Member must satisfy constraint: [Member must satisfy enum value set: [implicit, client_credentials, code]] (Service: AWSCognitoIdentityProviderService; Status Code: 400; Error Code: InvalidParameterException;
我不知道这里出了什么问题。我将此链接用于-

解决方案- 我已经将它的值更新为“client_-credentials”,并且成功了