I am trying to build exposed API that is called by another web service in order to insert data.
Here is DB structure. Table name: bad_domain attributes are : domain(string) modified_by(string) cereated_by(string) risk(Boolean) Here is my code in defauly.py auth.settings.allow_basic_login = True @auth.requires_login() @request.restful() def api(): def POST(table_name,**vars): return db[table_name].validate_and_insert(**vars) return locals() Here is my curl curl --user t...@gmail.com:1234 http://127.0.0.1:8000/test/default/api/bad_domain.json {"content": [{"domain": “www.google.com”,”modified_by”:”test”, "created_by": "test", "risk": True}]} curl dose not work. Any idea how to fix curl commend. I am pretty new to web2py Thank you. -- --- 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. For more options, visit https://groups.google.com/groups/opt_out.