Have you seen the article in php|architect on creating a service with the Reflection API?


(Seems like a lot of people have had a go at this problem–I’ve written something similar as well. In my case it turned out to be really convenient to pull the method name from the “filename” of the URL, and the output type (JSON, text, debug) from the “extension” part of the URL.)

There’s also: