On Monday, March 2, 2020 at 9:31:44 PM UTC-8, Alexei Vinidiktov wrote: > > Hello, > > I'm planning on creating a Chrome extension that will allow the user to > clip web pages or parts of them and save the clips in a web2py app. > > Is it possible to create such an extension? >
> Will it be able to communicate with the web2py app? > > I don't know much about writing extensions, but communicating with the web2py app just involves issuing a request over https, and certainly javascript can do that (e.g., fetch() and such). > I would preferably use json-rpc for communication, but a RESTFUL api would > also be fine. > > Which one would work? > > Web2py has hooks for both json-rpc and a RESTFUL interface. See Chapter 10, especially <URL:http://web2py.com/books/default/chapter/29/10/services#JSONRPC> <URL:http://web2py.com/books/default/chapter/29/10/services#Restful-Web-Services> How would authentication be handled? > Chapter 9 is the big picture on access and authorization <URL:http://web2py.com/books/default/chapter/29/09/access-control> but Chapter 10 has service-specific notes, starting under the REST section: <URL:http://web2py.com/books/default/chapter/29/10/services#Access-Control> and more generally in <URL:http://web2py.com/books/default/chapter/29/10/services#Services-and-Authentication> Note that these answers change somewhat when using py4web instead of web2py, although the DAL is the same. > > Thanks! > > > Good luck! /dps -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/ec6394e5-6fa2-4cd2-bdb9-006ec48b8121%40googlegroups.com.