Configuring a bitbucket repository to “activate” pipelines
问题 I have multiple repositories in a BitBucket project. I wish to automatically create a bitbucket repository, and enable pipelines (setting the pipeline configuration should be easy, with pushing a bitbucket-pipelines.yml file). How can I do it using the REST API? 回答1: You can create a repository with the BitBucket REST API. $ curl -X POST -H "Content-Type: application/json" -d '{ "scm": "git", "project": { "key": "Foo" } }' https://api.bitbucket.org/2.0/repositories/<username>/<repo_slug> Push