You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm facing this error "Profile X requires multi-factor authentication, but no MFA code callback was provided" when trying to access AWS resources through AWS NodeJS SDK "@AWS-SDK" by the session generated by the assumed role on my terminal:
I can access the same AWS resources by "aws" CLI with no issues. However, running the "serverless offline" command, it requests an MFA code, I enter a valid one and the server starts running successfully locally but it returns the above error when I try accessing any AWS resource through AWS SDK.
I'm facing this error "Profile X requires multi-factor authentication, but no MFA code callback was provided" when trying to access AWS resources through AWS NodeJS SDK "@AWS-SDK" by the session generated by the assumed role on my terminal:
aws sts assume-role --role-arn [role-arn] --role-session-name [session-name] --serial-number [arn-of-root-account] --token-code [token-code]
I can access the same AWS resources by "aws" CLI with no issues. However, running the "serverless offline" command, it requests an MFA code, I enter a valid one and the server starts running successfully locally but it returns the above error when I try accessing any AWS resource through AWS SDK.
Environment
serverless
v3.38.0serverless-offline
v13.3.3node.js
v21.6.2OS
Windows 11The text was updated successfully, but these errors were encountered: