So you need two things. First, computing the Bray-Curtis "distance" (or dissimilarity). There seem to be packages that implement it, e.g. {ecodist} or {abdiv}, or it is possible to reimplement it yourself.
Second, you will need to perform hierarchical clustering with Ward linkage, this can be done with the hclust() function (no other package needed). Looking at ?hclust, you will find that it has a method argument, to specify the linkage (see the Details section about Ward), and it has a d argument, where you can give it the distances you've computed previously. You should be able to find tutorials about hclust(), it's a common function.
So, here following the {ecodist} example (this is not an endorsement, I have never used a Bray-Curtis distance), you could use code like that:
library(ecodist)
# load example dataset
data(graze)
# take a look
dim(graze)
graze[1:5,1:5]
# compute distances
dists <- bcdist(graze[, -c(1:2)])
class(dists)
hc <- hclust(dists,
method = "ward.D2")
plot(hc)
# Decide on clusters: choose 4 cluster
my_cut <- cutree(hc, k = 4)
# number of observations in each cluster
table(my_cut)
# make a table for each observation, of label and cluster
data.frame(label = hc$labels,
clust = my_cut)