Seems that there is no API call for the warm spare status. As a workaround I am using this:
https://developer.cisco.com/meraki/api-v1/#!get-device-appliance-performance
Description: Return the performance score for a single MX. Only primary MX devices supported.
If no data is available, a 204 error code is returned.
So if I have two MXes in one network as warm spare and I get a score, this MX has to be the master.
Does anyone have a better idea?