private Uri GetUsersUri(string domain, string username = null) { var builder = new UriBuilder(_context.GetRandomNode().ManagementUri) { Path = $"settings/rbac/users/{domain}" }; if (!string.IsNullOrWhiteSpace(username)) { builder.Path += $"/{username}"; } return(builder.Uri); }
private Uri GetUri(string scopeName = null, string collectionName = null) { var builder = new UriBuilder(_context.GetRandomNode().ManagementUri) { Path = $"pools/default/buckets/{_bucketName}/collections" }; if (!string.IsNullOrWhiteSpace(scopeName)) { builder.Path += $"/{scopeName}"; } if (!string.IsNullOrWhiteSpace(collectionName)) { builder.Path += $"/{collectionName}"; } return(builder.Uri); }