We present a new solution to the index problem for hypoelliptic operators in the Heisenberg calculus on contact manifolds, by constructing the appropriate topological $K$-theory cocycle for such operators. Its Chern character gives a cohomology class to which the Atiyah-Singer index formula can be applied. Such a $K$-cocycle has already been constructed by Boutet de Monvel for Toeplitz operators, and, more recently, by Melrose and Epstein for the class of Hermite operators. Our construction applies to general hypoelliptic pseudodifferential operators in the Heisenberg calculus. As in the Hermite Index Formula of Melrose and Epstein, our construction gives a vector bundle automorphism of the symmetric tensors of the contact hyperplane bundle. This automorphism is constructed directly from the invertible Heisenberg symbol of the operator, and is easily computed in the case of differential operators.