It has contacts marked A B I - + (not in that order).
Connect A and B to separate GPIO. Connect - to a Pi ground (say pin 6) and + to 5V (say pin 2). You may leave I unconnected. Configure the software you are using by specifying the GPIO connected to A and B.