[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-08-14 Thread Massimo Di Pierro
I think if you require the dal from the equation, there is almost no overlap any more with web2py. On Wednesday, 13 August 2014 16:32:46 UTC-5, Cliff Kachinske wrote: Massimo, The new recipe you propose is bottle+dal+validators+auth+collection Could it be

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-08-13 Thread Cliff Kachinske
Massimo, The new recipe you propose is bottle+dal+validators+auth+collection Could it be bottle+whatever_you_like+validators+auth+collection? I have found myself needing to execute complex SQL queries. In this situation, in my opinion, psycopg2 would serve me just as well as dal. On Sunday,

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-27 Thread Falko Webpgr
So I created a REST API doc plugin for web2py quite a while ago. Here is what it looks like on the user side http://semanticsbml.org/semanticSBML/plugin_restapidoc/index# http://rumo.biologie.hu-berlin.de/pyMantis/plugin_restapidoc/index I also posted the plugin for this on here, a while ago.

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-26 Thread Massimo Di Pierro
No. At least not in the way web2py uses it. On Wednesday, 25 June 2014 11:58:01 UTC-5, Cliff Kachinske wrote: Massimo, I like the way your thoughts are headed. doesn't the many2many issue goes away if one uses, for example, MongoDB? On Sunday, June 22, 2014 4:45:06 PM UTC-4, Massimo Di

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-25 Thread Cliff Kachinske
Massimo, I like the way your thoughts are headed. doesn't the many2many issue goes away if one uses, for example, MongoDB? On Sunday, June 22, 2014 4:45:06 PM UTC-4, Massimo Di Pierro wrote: I added Hypermedia API support to web2py using Collection+JSON. Experimental. Collection+JSON is a

Re: [web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-23 Thread samuel bonill
Thanks massimo, this is the point, generate many2many relations, with one request get all the information relations to a resource. I'm developing a plugin to generate great RESTful API based in many2many relations. inspired by the Instagram API

Re: [web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-23 Thread samuel bonill
patterns = [ (posts/{post.id}, {coments: {author: auth_user}}] # My implementation parser = Rest.generate(patterns, args, kwargs) This automatically generate, the post with comments associate and user associated to a comment... What do you think about my idea ? 2014-06-23 9:50 GMT-05:00

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-22 Thread samuel bonill
it's good, I use db.parse_as_rest for generate the representation of resources, Collection+JSON help much. other thing, I would like generate a resource with relationship for example patterns = [ (posts/{post.id}, {coments: {author: auth_user}}] # My implementation parser =

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-22 Thread Massimo Di Pierro
This is a automatic in Colleciton+JSON. For example: # assume a model that described things and their attributes db.define_table('thing',Field('name')) db.define_table('attr',Field('thing','reference thing'),Field('name')) and you expose both: def api(): from gluon.contrib.hypermedia import

[web2py] Re: Hypermedia API and Collection+JSON in web2py

2014-06-22 Thread Massimo Di Pierro
Let me add that Collection+JSON is a standard but that does not make it perfect. I find many limitations. I managed to overcome some but utilizing extensions. https://github.com/mamund/collection-json/tree/master/extensions I also made some of my own extensions. Extensions are allowed and