The railgun API in https://raw.github.com/rapid7/metasploit-framework/master/lib/rex/post/meterpreter/extensions/stdapi/railgun/api_constants.rb defines most of these as constants.

e.g. You can pass ```"SERVICE_AUTO_START"``` as a string to the ```CreateServiceA``` and railgun will convert it to the relevant constant already. Therefore you wont have to define these constants here unless you are checking out values from an existing service.