curl -X POST -u "email:password" \
https://bitbucket.org/site/oauth2/access_token \
-d grant_type=client_credentials
curl -sX POST -u "AUTHOKEN" https://bitbucket.org/site/oauth2/access_token -d grant_type=client_credentials
{"access_token": "YOUR_LONG_ACCESS_TOKEN", "scopes": "pullrequest:write project:write account:write issue:write pipeline:variable snippet:write team:write webhook reposi...
body=$(cat << EOF
{
"name": "Mars Project",
"key": "MARS",
"description": "Software for colonizing mars.",
"is_private": false
}
EOF
)
curl -s --header "Authorization: Bearer YOUR_LONG_ACCESS_TOKEN" --header "Content-Type: application/json" -X POST -d "$body" https://api.bitbucket.org/2.0/teams/YOUR_TEAM/projects/ | jq .