Tried searching for this but couldn't find any resources.
Is there a way to access the Rest API from a Pipelines script without the need for authentication to the API?
Because the way I see it, the build runners run within BitBucket and you've configured the scripts yourself for which you would've needed appropriate permissions anyway. So there's no need for further authentication (or is there?).
My specific use-case: I need to comment on a Pull Request being created with code-coverage results, for which I need to access the Rest API from the Pipelines script.
Authentication is still required to access the Bitbucket API within Pipelines. You can easily do this however by setting up an App password (see https://confluence.atlassian.com/bitbucket/app-passwords-828781300.html) and adding that password as a secure environment variable (see https://confluence.atlassian.com/bitbucket/variables-in-pipelines-794502608.html) in Pipelines for use within your build script.
Yup that's how I've got it setup at the moment. Just seems like redundant authentication.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.