{"id":15984851,"url":"https://github.com/gggeek/ggwebservices","last_synced_at":"2025-03-18T00:31:35.255Z","repository":{"id":2590192,"uuid":"3571920","full_name":"gggeek/ggwebservices","owner":"gggeek","description":"eZ Publish Legacy extension which makes it easy to act as webservices/rest client or server","archived":false,"fork":false,"pushed_at":"2022-02-03T18:01:14.000Z","size":1442,"stargazers_count":5,"open_issues_count":0,"forks_count":9,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-28T06:04:23.305Z","etag":null,"topics":["ezpublish","jsonrpc","rest","soap","webservice","xmlrpc"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gggeek.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-02-28T14:42:57.000Z","updated_at":"2022-12-06T17:40:47.000Z","dependencies_parsed_at":"2022-08-28T12:13:26.223Z","dependency_job_id":null,"html_url":"https://github.com/gggeek/ggwebservices","commit_stats":null,"previous_names":[],"tags_count":21,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gggeek%2Fggwebservices","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gggeek%2Fggwebservices/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gggeek%2Fggwebservices/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gggeek%2Fggwebservices/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gggeek","download_url":"https://codeload.github.com/gggeek/ggwebservices/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243893849,"owners_count":20364918,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ezpublish","jsonrpc","rest","soap","webservice","xmlrpc"],"created_at":"2024-10-08T02:10:47.726Z","updated_at":"2025-03-18T00:31:34.933Z","avatar_url":"https://github.com/gggeek.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"GG Webservices extension for eZ Publish\r\n=======================================\r\n\r\nAn extension that adds/improves the native capabilities of eZ Publish to work as\r\n\r\n- webservices server\r\n- webservices client\r\n\r\nwith a visual webservices debugger thrown in for good measure\r\n\r\n\r\nFeatures\r\n--------\r\n\r\nAllows to easily execute calls to remote servers using JSONRPC, XMLRPC and SOAP\r\nprotocols or REST schemes (both from within php code and templates)\r\n\r\nAllows to expose existing functionality as JSONRPC or XMLRPC, REST and (better\r\nthan eZ native) SOAP webservices, similar to what can already be done with SOAP\r\nand eZJSCore in any eZ Publish installation\r\n\r\nAllows to expose functionality as webservice regardless of the protocol used by\r\nthe client - without having to duplicate code\r\n\r\nProvides a proxy module allowing javascript code served by an eZ Publish server\r\nto execute cross-domain webservice calls (without resorting to jsonp or html tricks)\r\nand even cross-protocol calls\r\n\r\nAllows easy debugging of webservice calls by providing a complete graphical\r\ninterface for debugging\r\n\r\nAdds support for WSDL in SOAP calls (both server-side and client-side)\r\n\r\nImproves the existing http client adding features such as support for more\r\nauthentication schemes, compressed requests etc...\r\n\r\nAllows usage of JSONRPC or XMLRPC (and eventually SOAP) to call functions exposed\r\nvia the ezjscore extension API\r\n\r\nKeeps the same API as the existing eZP SOAP classes for maximum interoperability\r\n\r\nAnd much more :-)\r\n\r\nPrerequisites\r\n-------------\r\n\r\n- PHP 5 / eZP 4.0+\r\n- to execute/receive jsonrpc calls, the php JSON extension is needed\r\n- to execute/receive rest calls, the php SIMPLEXML or JSON extensions are needed\r\n- to execute/receive xmlrpc calls, the php XMLRPC extension is needed\r\n- to call remote services using wsdl descriptions the php SOAP extension is needed\r\n- to integrate with the ezjscore extension, eZP 4.2 is needed (and the ezjscore\r\n  extension too, of course)\r\n- to make ajax calls to the server itself using the integrated javascript library\r\n  the ezjscore extension is recommended. Any other javascript library for xmlrpc/\r\n  jsorpc can also do.\r\n- to receive soap/xmlrpc/jsonrpc/rest+post calls from users authenticated via the\r\n  standard session mechanism (such as e.g. ajax calls), the ezformtoken extension\r\n  has to be disabled\r\n\r\nBasics\r\n------\r\nServer (eZPublish exposes webservices):\r\n\r\n- to receive xmlrpc, jsonrpc or 'rest' calls, you need to:\r\n    1. modify the configuration in ``wsproviders.ini`` and possibly in ``site.ini.append.php``\r\n    2. create a file ``extension/\u003cxxx\u003e/\u003cjsonrpc|xmlrpc|rest\u003e/initialize.php`` with the\r\n       php code to be exposed as webservice\r\n    3. manage access control to the exposed services via the administration interface\r\n       and/or configuration settings\r\n\r\nClient (eZPublish accesses webservices exposed by other systems):\r\n\r\n- every remote webservice server that has to be accessed from the eZ Publish\r\n  server itself has to be defined in ``wsproviders.ini``\r\n- to call remote webservices from within templates use the template fetch function\r\n  ``fetch( 'webservices', 'call', hash( paramname, value, ... ) )``\r\n  Please remember to desactivate the view cache where needed for node templates\r\n  that execute webservice calls\r\n- to call remote webservices from php code use\r\n  ``ggeZWebServicesClient::call( $server, $metod, $params=array(), $options=array() );``\r\n\r\nFor more details on usage of the extension, look in the doc/ directory.\r\n\r\n\r\nKnown limitations\r\n-----------------\r\n\r\n- support for WSDL is limited, as is support for SOAP 1.2\r\n- jsonrpc support is only available for version 1.0, not for 2.0\r\n- the ws client does not support automatic cookie management\r\n- the ws client does not support oauth authentication\r\n- the proxy view works exposing an xmlrpc+jsonrpc api. This means that it can not\r\n  be used to emulate the richer semantics of soap/rest calls. E.g. at the moment\r\n  it can not be used to send POST calls to upstream rest webservices\r\n- rest support is far from perfect, as the extension was developed based on rpc\r\n  semantics (call a *method* which takes a *hash of parameters*).\r\n  Currently:\r\n    * for the rest client, the parameters will be translated into query\r\n      string or http request payload, not into a slash-separated part of the url.\r\n    * for the rest server, there is no support for having slash-separated\r\n      parameters or complex routing rules\r\n- and much more: read doc/todo to get a detailed list of bits which could improve\r\n\r\n\r\nFAQ\r\n---\r\n  Q: how do I debug webservices without going insane?\r\n  \r\n  A1: you're a lucky guy, since this extension provides a nice graphical debugger\r\n      within the standard admin interface\r\n  \r\n  A2: when DebugSettings/DebugOutput and TemplateSettings/DevelopmentMode are\r\n      both enabled, the requests sent by the fetch function webservices/call\r\n      will be displayed as part of the standard debug output\r\n  \r\n  A3: by enabling logging, you n00b!\r\n      There is an ini setting in wsproviders.ini that controls verbosity for a\r\n      log file dedicated to webservices: var/\u003cvardir\u003e/log/webservices.log\r\n\r\n  Q: how secure is this extension?\r\n  \r\n  A: the main author prides himself with being an extremely security-focused\r\n     developer - he learnt many things about webservices and security in the\r\n     infamous \"lupii worm\" incident, and later even worked as security consultant\r\n     for a short time.\r\n     Having said that, the codebase is by now quite large, and the amount of\r\n     functionality available staggering.\r\n     There is no guarantee whatsoever, either implicit or explicit, that using\r\n     it will not expose your data, or data of your customers, to fraudulent use.\r\n     If this poses a problem to you, please sponsor a security audit.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgggeek%2Fggwebservices","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgggeek%2Fggwebservices","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgggeek%2Fggwebservices/lists"}