A classic result in the foundations of Yang-Mills theory, due to Barrett [Int. J. Theor. Phys. 30, 1171–1215 (1991)], establishes that given a “generalized” holonomy map from the space of piece-wise smooth, closed curves based at some point of a manifold to a Lie group, there exists a principal bundle with that group as structure group and a principal connection on that bundle such that the holonomy map corresponds to the holonomies of that connection. Barrett also provided one sense in which this “recovery theorem” yields a unique bundle, up to isomorphism. Here we show that something stronger is true: with an appropriate definition of isomorphism between generalized holonomy maps, there is an equivalence of categories between the category whose objects are generalized holonomy maps on a smooth, connected manifold and whose arrows are holonomy isomorphisms, and the category whose objects are principal connections on principal bundles over a smooth, connected manifold. This result clarifies, and somewhat improves upon, the sense of “unique recovery” in Barrett’s theorems; it also makes precise a sense in which there is no loss of structure involved in moving from a principal bundle formulation of Yang-Mills theory to a holonomy, or “loop,” formulation.