Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

single-user command-line user of git on Linux; how to swtich to using these infernal API tokens?

ryancw
July 19, 2026

Hello. I have been completely flummoxed by this move from app passwords to API tokens. It seems I am not alone in that.

have been using only a tiny subset of git capabilities in my single-user workflow, but it's enough for me. So I"m a long-time but still inexperienced user.

I use git via command line on Linux Mint. I have my credentials stored. (Yes, I know, but I am the only person with physical access to my computers.) So to push and pull (really my only actions) I simply do::

git pull

or

git push

when in my project directory.

How do I switch that to use API tokens? Could someone please share the sequence of commands to:

forget my current credentials

store my token-based credentials

pull and push

Thank you very much.

1 answer

0 votes
Arkadiusz Wroblewski
Community Champion
July 19, 2026

Hello @ryancw 

Your credential.helper store will cache the new token automatically. Ensure it has both read:repository:bitbucket and write:repository:bitbucket scopes, then clear the old credentials by running:

printf "protocol=https\nhost=bitbucket.org\n\n" | git credential reject

Next, run git pull, enter your case-sensitive username, and paste the token as the password to save it. If that fails, you can force Atlassian's token auth by running git remote set-url origin https://x-bitbucket-api-token-auth@bitbucket.org/<workspace>/<repository>.git and pulling again, just don't put the actual token string in the URL.

Best,

Arek 🤠

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events