{"action":"created","issue":{"url":"https://api.github.com/repos/Elgg/Elgg/issues/8605","labels_url":"https://api.github.com/repos/Elgg/Elgg/issues/8605/labels{/name}","comments_url":"https://api.github.com/repos/Elgg/Elgg/issues/8605/comments","events_url":"https://api.github.com/repos/Elgg/Elgg/issues/8605/events","html_url":"https://github.com/Elgg/Elgg/issues/8605","id":91464271,"number":8605,"title":"Writing web services should require less work","user":{"login":"hypeJunction","id":1202761,"avatar_url":"https://avatars.githubusercontent.com/u/1202761?v=3","gravatar_id":"","url":"https://api.github.com/users/hypeJunction","html_url":"https://github.com/hypeJunction","followers_url":"https://api.github.com/users/hypeJunction/followers","following_url":"https://api.github.com/users/hypeJunction/following{/other_user}","gists_url":"https://api.github.com/users/hypeJunction/gists{/gist_id}","starred_url":"https://api.github.com/users/hypeJunction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hypeJunction/subscriptions","organizations_url":"https://api.github.com/users/hypeJunction/orgs","repos_url":"https://api.github.com/users/hypeJunction/repos","events_url":"https://api.github.com/users/hypeJunction/events{/privacy}","received_events_url":"https://api.github.com/users/hypeJunction/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-06-27T13:26:26Z","updated_at":"2015-06-27T18:51:18Z","closed_at":null,"body":"I feel like exposing functions currently requires too many repetitive steps. First, you need to document all the parameters when exposing the function. Then you need to list all those parameters as arguments in your function, then document them all over again.\r\n\r\nI am thinking of adding an associative array of parameters as the last argument passed to the function on method execution. That way the method function can skip listing all arguments and use ```func_get_args()``` to get an assoc array that it can work with. In the long run, we should however consider making a breaking change and switching to assoc array by default. If the web service needs 10 or 20 or more parameters to run, using them all as arguments is tiresome.\r\n\r\nI am open to other ideas if anyone has them."},"comment":{"url":"https://api.github.com/repos/Elgg/Elgg/issues/comments/116117607","html_url":"https://github.com/Elgg/Elgg/issues/8605#issuecomment-116117607","issue_url":"https://api.github.com/repos/Elgg/Elgg/issues/8605","id":116117607,"user":{"login":"hypeJunction","id":1202761,"avatar_url":"https://avatars.githubusercontent.com/u/1202761?v=3","gravatar_id":"","url":"https://api.github.com/users/hypeJunction","html_url":"https://github.com/hypeJunction","followers_url":"https://api.github.com/users/hypeJunction/followers","following_url":"https://api.github.com/users/hypeJunction/following{/other_user}","gists_url":"https://api.github.com/users/hypeJunction/gists{/gist_id}","starred_url":"https://api.github.com/users/hypeJunction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hypeJunction/subscriptions","organizations_url":"https://api.github.com/users/hypeJunction/orgs","repos_url":"https://api.github.com/users/hypeJunction/repos","events_url":"https://api.github.com/users/hypeJunction/events{/privacy}","received_events_url":"https://api.github.com/users/hypeJunction/received_events","type":"User","site_admin":false},"created_at":"2015-06-27T18:51:18Z","updated_at":"2015-06-27T18:51:18Z","body":"Proposed implementation here: #8610 \r\nWill deprecate thing in 1.12 once we know if that's the direction we want to head"}}