# Getting started with repositories

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgetting-started-with-repositories%2F28178%3E%5C
**Category:** Beginners\
**Created:** [December 20, 2022, 2:40pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgetting-started-with-repositories%2F28178 "2022-12-20T14:40:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sl02](https://avatars.discourse-cdn.com/v4/letter/s/ba9def/32.png) [@sl02](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fsl02)%5C
**Post date:** [December 20, 2022, 2:40pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgetting-started-with-repositories%2F28178%2F1 "2022-12-20T14:40:37Z")

</div>

I was following the documentation [Repositories](https://huggingface.co/docs/hub/repositories-getting-started) to create a private repository, and then subsequently clone it. I ran the `hugginface_hub` cli command and entered the user access token; the token was successfully added to the git credentials and to the token file in the ~/.huggingface directory. However, when I tried to clone the repository, git threw a “cannot find repo” error. I thought this had something to do with another personal account that I had created.  
I checked the keychain and noted that huggingace had created 2 accounts: one against the personal email id and another with account name `hf_user`. So, I wasn’t sure which account was updated with the new credentials. I deleted both accounts, and reran the `huggingface_hub` command; it executed successfully. This time, in the keychain, I could see an account with user `hf_user`. I tried to clone the repo but it failed with the same error. I deleted the keychain, and ran the `git clone` command directly; this time I was prompted to enter my credentials, which I did, and I was able to successfully clone the repo. In the keychain, I could see the account with my official email id.

So, my questions are: 1) What exactly was the reason for the failure?  
2) Do we need this command to push code to the hub when using git commands? Or is this used with the python API?
