I tried to use the library as demonstrated.
const {Srp} = require('aws-cognito-srp-client');
const identityPoolId = "us-east-1_xYZZcH2"
const srp = new Srp(identityPoolId);
const srpA = srp.getA();
It throws following error.
ERROR Invoke Error {
"errorType": "TypeError",
"errorMessage": "Srp is not a constructor",
"stack": [
"TypeError: Srp is not a constructor",
" at Runtime.exports.login [as handler] (/var/task/cognitoUtil.js:11:15)",
" at Runtime.handleOnceNonStreaming (file:///var/runtime/index.mjs:1085:29)"
]
}
I tried to use the library as demonstrated. const {Srp} = require('aws-cognito-srp-client'); const identityPoolId = "us-east-1_xYZZcH2" const srp = new Srp(identityPoolId); const srpA = srp.getA();
It throws following error.
ERROR Invoke Error { "errorType": "TypeError", "errorMessage": "Srp is not a constructor", "stack": [ "TypeError: Srp is not a constructor", " at Runtime.exports.login [as handler] (/var/task/cognitoUtil.js:11:15)", " at Runtime.handleOnceNonStreaming (file:///var/runtime/index.mjs:1085:29)" ] }