According to https://ncatlab.org/nlab/show/delooping#delooping_of_a_group_to_a_groupoid we can think of delooping of a group as the one object groupoid $BG$ consisting of a single object and whose morphisms are the elements of the group $G$ and the composition of morphisms are given by the group multiplication.
Now let us consider a category $C$ with a group object $\bar{G}$.
Now if $C$ has a forgetful functor to $Sets$ then there is a natural way to associate a one object groupoid to the group object (For example the way we talk about delooping of a Topological group, Lie group..etc).
My question is the following:
Let $D$ be a category with a group object $G'$(without any other further assumptions). Is there an analogous way to associate a one object groupoid to $G'$ ?
Or is there any necessary and /or sufficient condition for doing so?
Apology in advance if my question is not making much sense.