'fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/lambda-pipeline-repo/': The requested URL returned error: 403

I am trying to set up My AWS code commit to my local system.

I am trying to clone the repo

git clone https://git-codecommit.us-east-1.amazonaws.com/v1/repos/lambda-pipeline-repo  

when I tried to do that I get this window where I enter my IAM user credentials.

enter image description here

Soon after this, I get

Cloning into 'lambda-pipeline-repo'...
fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/lambda-pipeline-repo/': The requested URL returned error: 403

I am wondering what I am doing wrong.

I also tried things in this link

https://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-https-windows.html

Could anyone help me out of this?



Solution 1:[1]

I have tried multiple ways as mentioned in other links of Stack Overflow, GitHub portals, AWS help site not worked for me.

The method worked for me is as below.

  1. In IAM, select the "Security Credentials"
  2. In My Security Credentials choose the "AWS CodeCommit Credentials"
  3. Under HTTPS Git credentials for AWS CodeCommit, click "Generate credentials"
  4. Use the username & password that got generated.

NOTE: Before this kindly delete the previous credential used.

Steps to delete your Credential Manager

  1. Control Panel
  2. Select "Credential Manager"
  3. Under Generic Credential, delete the appropriate Git Credential.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Swathi Ramesh