Let $k$ be a field of characteristic $p$, and let $q = p^n$. Consider the injection $k(x)\hookrightarrow k(x)$ given by sending $x\mapsto x^q-x$. Via this injection we may view $k(x)$ as an extension of $k(x^q-x)$.
I believe this extension should be finite of degree $q$.
In this case, what is the minimal polynomial of this extension? Ie, what is the polynomial $f\in k[T]$ such that $f(x^q-x) = x$?
You don't have the right definition of the minimal polynomial. The minimal polynomial $f$ for the extension $k(x^q-x) \hookrightarrow k(x)$ should have coefficients in $k(x^q-x)$ and satisfy $f(x) = 0$. It's given by $f(T) = T^q-T - (x^q-x)$.
Here is an argument for the irreducibility of $f$: Assume we have a polynomial of degree $< q$ with coefficients in $k(x^q-x)$ annihilating $x$, say $\sum_{i=0}^{q-1} f_i(x^q-x) x^i = 0$. Multiplying with a suitable factor we can assume that the $f_i$ are polynomials. For $a \in \mathbb F_q$ we get $\sum_{i=0}^{q-1} f_i(0) a^i = 0$ by setting $x = a$ in the relation. Now $\sum_{i=0}^{q-1} f_i(0)T^i$ has $q$ distinct roots, so it is the zero polynomial. Hence $f_i(0) = 0$ for all $i$, so we can cancel $T$ from the $f_i(T)$ and obtain another relation with $f_i$ of smaller degree. The argument can be repeated indefinitely, so we must have $f_i = 0$ for all $i$.