Developers

License

Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

all: The environment
protected: boolean, the webservices are protected or not?
allowed: if the webservices are protected, specify a YAML array of IP addresses that can access the services
protectedRoute: sets the route that non-allowed IP addresses will be redirected to
services: an array of single services configurations
name: the service name ( used in the service URL )
model: the model of the service
methodForQuery: a method for GET requests. If not specified, doctrine will do a `->createQuery()->execute()`
states: allowed request states ( PUT, POST, GET, DELETE ). If not specified, all state are allowed

If you turn on authentication, remember to specify a secure route.
If you have module default enabled, the route can be secure ( which is the name of the default/secure route ).

Requirements

This plugins requires PHP's short open tags parameter set to OFF.
It would not be such a difficult matter to make the plugin work also with short open tags enabled, the point is that you shouldn't work this way.

A specification

Since PHP sucks in so many ways handling PUT requests this plugin handles them with symfony's native REST architecture ( so, not not real PUT requests, but requests with the additional parametere sf_method set to PUT ).