How to create a publicly accessible REST API in Moqui

ぐ巨炮叔叔 提交于 2019-12-08 13:16:52

问题


What is the best way to create a publicly accessible REST API in Moqui? By public I mean an API that does not require prior authentication.

The only work around I found so far was to create a user "public_api" and grant him access to the desired services. The client applications then use this user to authenticate with the Moqui server.


回答1:


There is now an update in moqui-framework commit #44272ba to support the require-authentication element on the Service REST API resource, id, and method elements. Set this to anonymous-view or anonymous-all to allow access to REST API services without authentication or authorization. This follows the same pattern as is used for XML Screens to be accessible without login (like the POP Commerce ecommerce app).



来源:https://stackoverflow.com/questions/38638825/how-to-create-a-publicly-accessible-rest-api-in-moqui

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!