Very simple to test which is motor power and ground with a DC motor as the DC should not be referenced to ground, the conductor that shows continuity to the motor frame will be the ground.
With encoders, the power and common as a general rule is Red and Black, in this case it is black not green as the DC common may not be at ground potential.
Unfortunately they tend to use the term Ground when common is implied, which can be misleading.
The index or marker pulse on an encoder is a once per rev pulse output which is usually used as a home reference marker on closed loop systems. Usually not used with Mach.
With the encoders you have the data sheet to go by.
I just looked at your encoder sheet again and it looks like they did not use standard wire colours, go by the pin out.
If you are an Electrician you have a head start on the Electrics.
Al.
CNC, Mechatronics Integration and Custom Machine Design
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.