We show that the Duffin-Kemmer-Petiau equation, minimally coupled to an Abelian gauge field, can be regarded as a matrix equation for the gauge potential produced internally from the matter fields. This can be solved as a rational expression in terms of currents bilinear in the matter wave function, together with a similar expression for the field strength tensor, thus providing a gauge invariant formulation of the self-interacting DKP equations. We give the derivation of this result for the 5 component DKP system, by analogy with the Dirac equation case. To this end, we establish the algebraic structure of the set of bilinear currents, and the properties of the minimal generating set, which consists of two scalars and two four-vectors, together with a single quadratic constraint.