Solution (source code)

= Solution

Let $\omega=\theta^{-1}(\alpha)$. The preceding invariant formula for the <exterior derivative> identifies the expression in the question with
$$
X(\alpha(Y))-Y(\alpha(X))-\alpha([X,Y])=d\omega(X,Y).
$$
Its vanishing for every pair of global <vector fields> is equivalent to $d\omega=0$: global fields with arbitrary prescribed tangent values are available by bump-function extension. Thus it is exactly the condition that $\omega$ be a <closed differential one-form>.

By definition, the first <de Rham cohomology> is closed one-forms modulo <exact differential forms>. The hypothesis $H^1_{\mathrm{dR}}(M)=0$ makes every closed one-form exact. Hence $d\omega=0$ gives a globally smooth function $g$ with $\omega=dg$, and
$$
\boxed{\alpha(X)=dg(X)=X(g)\quad\text{for every }X.}
$$
Conversely, if $\alpha(X)=X(g)$, then
$$
X(\alpha(Y))-Y(\alpha(X))-\alpha([X,Y])
=X(Yg)-Y(Xg)-[X,Y]g=0
$$
by the definition of the <Lie bracket of vector fields>. Equivalently, $d(dg)=0$. \b[The bracket compatibility condition is necessary and, when $H^1_{\mathrm{dR}}(M)=0$, sufficient for a global potential.] The potential is unique up to a constant on each connected component, since the difference of two potentials has zero differential.