You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I needed to get PRs in all states, and the state parameter wasn't available so I locally modified GetRepositoryPullRequestsAsync:
public async Task<IEnumerable<PullRequest>> GetRepositoryPullRequestsAsync(string workspaceId, string repositorySlug, int? maxPages = null, string q = null, PullRequestStates[] states = null)
{
var queryParamValues = new Dictionary<string, object>
{
[nameof(q)] = q,
["state"] = states
};
It would be nice to add Dictionary<string, object> otherQueryParameters to all APIs which would be less work than working out which parameters could be added per call, and it futureproofs the library if there are new parameters added to the Bitbucket API.
An alternate/complimentary idea would be to have some sort of callback after SetQueryParams(qpv) to let the query string to be modified. Leads to the potential for other callbacks, although you probably would want to abstract furl away from the callbacks.
Example, although, being lazy, I'd be inclined to create new furl extensions that would combine the existing furl call with the callback.
This enhancement would be fantastic. I ended up scrapping the use of the library due to this limitation and building my own using REST API calls which is a bunch of unnecessary work. This library is very nice and I hope it can be updated soon
I needed to get PRs in all states, and the
state
parameter wasn't available so I locally modifiedGetRepositoryPullRequestsAsync
:It would be nice to add
Dictionary<string, object> otherQueryParameters
to all APIs which would be less work than working out which parameters could be added per call, and it futureproofs the library if there are new parameters added to the Bitbucket API.An alternate/complimentary idea would be to have some sort of callback after
SetQueryParams(qpv)
to let the query string to be modified. Leads to the potential for other callbacks, although you probably would want to abstract furl away from the callbacks.Example, although, being lazy, I'd be inclined to create new furl extensions that would combine the existing furl call with the callback.
Finally, thanks for writing this library!
The text was updated successfully, but these errors were encountered: