@@ -64,23 +64,20 @@ def run_test():
6464 # "url": "https://httpbin.rs/get"
6565 # }
6666
67- get_request_result = scrappey.request({
68- " cmd" : " request.get" ,
67+ get_request_result = scrappey.get({
6968 ' session' : session[' session' ],
7069 ' url' : ' https://httpbin.rs/get' ,
7170 })
7271 print (' GET Request Result:' , get_request_result)
7372
74- post_request_result = scrappey.request({
75- " cmd" : " request.post" ,
73+ post_request_result = scrappey.post({
7674 " url" : " https://httpbin.rs/post" ,
7775 " postData" : " test=test&test2=test2"
7876 })
7977 print (' POST Request Result:' , post_request_result)
8078
8179 # JSON request example
82- post_request_result_json = scrappey.request({
83- " cmd" : " request.post" ,
80+ post_request_result_json = scrappey.post({
8481 " url" : " https://backend.scrappey.com/api/auth/login" ,
8582 " postData" : " {\" email\" :\" email\" ,\" password\" :\" password\" }" ,
8683 " customHeaders" : {
@@ -96,10 +93,57 @@ def run_test():
9693
9794run_test()
9895
99- ```
10096
97+ ```
10198For more information, please visit the [ official Scrappey documentation] ( https://wiki.scrappey.com/getting-started ) . 📚
10299
100+ Here are some other examples from the builder (https://app.scrappey.com/#/builder ).
101+
102+ ``` json
103+ {
104+ "cmd" : " request.get" ,
105+ "url" : " https://httpbin.rs/get" ,
106+ "customHeaders" : {
107+ "auth" : " test"
108+ },
109+ "cookiejar" : [
110+ {
111+ "key" : " cookiekey" ,
112+ "value" : " cookievalue" ,
113+ "domain" : " httpbin.rs" ,
114+ "path" : " /"
115+ }
116+ ],
117+ "session" : " 86908d12-b225-446c-bb16-dc5c283e1d59" ,
118+ "autoparse" : true ,
119+ "properties" : " parse using ai, product name" ,
120+ "proxy" : " http://proxystring"
121+ }
122+
123+ {
124+ "cmd" : " request.post" ,
125+ "url" : " https://httpbin.rs/get" ,
126+ "postData" : " {\" happy\" :\" true}" ,
127+ "customHeaders" : {
128+ "content-type" : " application/json" ,
129+ "auth" : " test"
130+ },
131+ "cookiejar" : [
132+ {
133+ "key" : " cookiekey" ,
134+ "value" : " cookievalue" ,
135+ "domain" : " httpbin.rs" ,
136+ "path" : " /"
137+ }
138+ ],
139+ "session" : " 86908d12-b225-446c-bb16-dc5c283e1d59" ,
140+ "autoparse" : true ,
141+ "properties" : " parse using ai, product name" ,
142+ "proxy" : " http://proxystring"
143+ }
144+ ```
145+
146+
103147## License
104148
105149This project is licensed under the MIT License.
0 commit comments