I could solve it using this matrix
https://developer.vuforia.com/resources/dev-guide/pose-matrix-explained
I got the rotation matrix from the pose matrix and calculated the orientation from http://planning.cs.uiuc.edu/node103.html
Hope this helps someone.