User Tools

Site Tools


engine:webservices:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
engine:webservices:start [2015/07/01 22:56]
asok
engine:webservices:start [2017/06/20 17:13] (current)
asok [Testing a Web Service using catest]
Line 31: Line 31:
 Try the method **ca_test_server.method** for an example of using the web service **ca_test**,​ which is implemented by **ca_test_q.json**,​ **ca_test_r.json** and **ca_test.method**. Try the method **ca_test_server.method** for an example of using the web service **ca_test**,​ which is implemented by **ca_test_q.json**,​ **ca_test_r.json** and **ca_test.method**.
  
-====Creating,​ Extracting and Replacing ​Data in JSONs====+====Creating,​ Extracting and Inserting ​Data in JSONs====
  
 There is a single system function **#json** to manipulate JSONs in DreamApps. It can take up to 3 parameters. There is a single system function **#json** to manipulate JSONs in DreamApps. It can take up to 3 parameters.
Line 60: Line 60:
  
 See the method ​ **ca_test_server.method** for examples of #json usage. See the method ​ **ca_test_server.method** for examples of #json usage.
 +====Testing a Web Service using catest====
 +
 +Here is an example. Run something like the followings: ​
 +<​code>​
 +str host="​http://​ig.dreamapps.com/​da/​ws"​
 +set s=#​json(file "​zx_auth_q.json"​)
 +set s=#​json(s,"​businessid","​630006"​)
 +set s=#​json(s,"​username","​asok@dreamapps.com"​)
 +set s=#​json(s,"​password","​go"​)
 +
 +set s=#​http(host,"​POST",​s)
 + 
 +print s
 +</​code>​
/srv/www/htdocs/wiki/data/attic/engine/webservices/start.1435791399.txt.gz · Last modified: 2015/07/01 22:56 by asok