MitjaBezensek / SharpBucket

SharpBucket is a .Net wrapper for the Bitbucket's REST API.
MIT License
67 stars 59 forks source link

Lacking an endpoint to fetch activity from ONE pull request #110

Closed johnnyasantoss closed 5 years ago

johnnyasantoss commented 5 years ago

Hello, I would like to know if this endpoint is already covered OR if there's a way to do a custom endpoint call using this lib. More specifically this endpoint which is not listed on Coverage.md

mnivet commented 5 years ago

I've just search the word activity in coverage.md and found this endpoint

It says that it is implemented by PullRequestResource.GetPullRequestActivity() and covered by unit tests so yes you can call this endpoint using this lib

here a micro code sample that should help you to use that lib to perform that call

            var sharpBucket = new SharpBucketV2();
            sharpBucket.NoAuthentication(); // choose the appropriate authentication method instead of that
            sharpBucket.RepositoriesEndPoint()
                .RepositoryResource("account", "repoName")
                .PullRequestsResource()
                .PullRequestResource(42) // 42 = a pull request id
                .GetPullRequestActivity();