0

我正在尝试手动请求邮递员注册。有一个带有标头的 POST 请求:

Content-Type:application/x-amz-json-1.1
X-Amz-Target:AWSCognitoIdentityProviderService.SignUp

原始的身体看起来像这样:

{
    "ClientId": "xxxxxxxxx",
    "Password": "xxxxxxxx",
    "UserAttributes": [ 
                        {
                            "Name": "Name",
                            "Value": "xxxxxx@dd.com"
                        }
                    ],
    "Username": "xxxxxxx"
} 

我得到,在响应这个错误:

{"__type":"UnknownOperationException"}

任何线索为什么我会收到此错误?

4

1 回答 1

0

请参考cognito API - AdminCreateUser

所以json数据应该是:

{
   "DesiredDeliveryMediums": [ "string" ],
   "ForceAliasCreation": boolean,
   "MessageAction": "string",
   "TemporaryPassword": "string",
   "UserAttributes": [ 
      { 
         "Name": "string",
         "Value": "string"
      }
   ],
   "Username": "string",
   "UserPoolId": "string",
   "ValidationData": [ 
      { 
         "Name": "string",
         "Value": "string"
      }
   ]
}

没有ClientId

于 2018-04-30T14:22:05.220 回答