Seeking an example of using AWS C++ SDK to implement get-credentials-for-identity and it’s required get-id input for temporary AWS credentials

  amazon-cognito, aws-sdk-cpp, c++

I am currently building a C++ client which is successfully authenticating to AWS Cognito User Pools. I wish to obtain temporary AWS credentials via exchanging the received ID token from Cognito.

Using the Advanced Flow with AWS CLI it seems to be two separate calls which I have working.

aws cognito-identity get-id
aws cognito-identity get-credentials-for-identity

The end goal is to receive AccessKeyId,SecretKey,SessionToken,IdentityId for subsequent AWS service calls.

Source: Windows Questions C++