Hi,
I'm green so need help. How oh how I can connect correctly from my script to Bitbucket to create / delete repositories (for now).
Habe so far this:
import requests
username = 'user@mail.com'
password = 'password'
headers = {"Content-Type": 'application/json'}
auth = (username, password)
bb_base_url = f"https://api.bitbucket.org/2.0/repositories/username/reponame"
res = requests.put(bb_base_url, headers=headers, auth=auth)
print(res)
Geting 401 code in responce. With same code just instead of put I'm using delete method I can delete repository created via web browser... What i'm doing wrong?