Finding representatives of conjugacy classes in $\text{Mat}_2(\mathbb{Q})$

Let $A\in S$. From the condition that $A^6=I$ and $A^n\neq I$ for $0<n<6$, we conclude that the characteristic polynomial of $A$ must be $x^2-x+1$. We claim that $A$ is conjugate to $$X:=\begin{bmatrix}1&1\\ -1&0\end{bmatrix}\,.$$ That is, $S$ is a single orbit with representative $X$.

Suppose that $$A=\begin{bmatrix}a&b\\c&d\end{bmatrix}\,,$$ where $a,b,c,d\in\mathbb{Q}$ are such that $a+d=1$ and $ad-bc=1$. Take $$V:=\begin{bmatrix}1&1\\c-d&-a+b\end{bmatrix}\,.$$ Then, $\det(V)=-a+b-c+d$.
First, we claim that $\det(V)\neq 0$. Suppose contrary that $\det(V)=0$. That is, $$a+c=b+d\,.$$ Since $d=1-a$, we have $$c=b-2a+1\,.$$ As $ad-bc=1$, we get $a(1-a)-b(b-2a+1)=1$, or $$(a-b)^2-(a-b)+1=0\,;$$ nonetheless, the equation $t^2-t+1=0$ has no solution $t\in\mathbb{Q}$. This is a contradiction, and the claim is proven.
Note that $$X\,V=\begin{bmatrix}1&1\\-1&0\end{bmatrix}\,\begin{bmatrix}1&1\\c-d&-a+b\end{bmatrix}=\begin{bmatrix}1+c-d&1-a+b\\-1&-1\end{bmatrix}$$ and $$V\,A=\begin{bmatrix}1&1\\c-d& -a+b\end{bmatrix}\,\begin{bmatrix}a&b\\c&d\end{bmatrix}=\begin{bmatrix}a+c&b+d\\-ad+bc&-ad+bc\end{bmatrix}\,.$$ Because $a+d=1$ and $ad-bc=1$, it can be seen immediately that $X\,V=V\,A$, whence $A$ is conjugate to $X$.


Every $A \in \operatorname{Mat}_2(\Bbb Q)$ has a conjugate element $PAP^{-1}$ (with $P \in GL_2(\Bbb Q)$) which is in its Frobenius normal form. Since $S$ is closed under conjugation, we can represent each orbit by enumerating the elements of $S$ which have this normal form.

Any element of $S$ will have a minimal polynomial which divides $x^6 - 1$. Over $\Bbb Q$, the polynomial $x^6 - 1$ factors into the product $$ p(x) = x^6 - 1 = (x-1)(x+1)(x^2 - x + 1)(x^2 + x + 1) $$ We eliminate any matrices whose minimal polynomial divides $x-1$, $x^2 - 1$, or $x^3 - 1$. The only monic polynomial over $\Bbb Q$ which divides $p$ but none of these smaller polynomials is $q(x) = x^2 - x + 1$. Thus, $q$ must be the minimal polynomial of our matrix in $S$.

Conclude that $S$ contains exactly one orbit, which belongs to the representative $$ A = \pmatrix{0&-1\\1&1} $$