When generating the fcs.resource.config.php don't generate empty keys, don't generate them at all, which is easy to test for in php, allow the initial resource endpoint's name to be passed as an xml parameter so if the returned initial endpoint's name is "default" it can be replaced by the x-context parameter. If there is no style specified for an endpoint use the default style, don't just send a (wrong) error message.