File tree 4 files changed +7
-9
lines changed
functions/technologies/libs
4 files changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -246,7 +246,6 @@ Returns a JSON object with the following schema:
246
246
247
247
The following parameters can be used to filter the data:
248
248
249
- - ` client ` (optional): A string with the client: ` mobile ` or ` desktop ` .
250
249
- ` technology ` (optional): A comma-separated string representing the technology name(s) or ` ALL ` .
251
250
- ` category ` (optional): A comma-separated string representing the category name(s).
252
251
- ` onlyname ` (optional): No value required. If present, only the technology names will be returned.
@@ -255,7 +254,7 @@ The following parameters can be used to filter the data:
255
254
256
255
``` bash
257
256
curl --request GET \
258
- --url ' https://{{HOST}}/v1/technologies?category=Live%20chat%2C%20blog&technology=Smartsupp&client=mobile '
257
+ --url ' https://{{HOST}}/v1/technologies?category=Live%20chat%2C%20blog&technology=Smartsupp'
259
258
```
260
259
261
260
Returns a JSON object with the following schema:
@@ -266,7 +265,10 @@ Returns a JSON object with the following schema:
266
265
"client" : " mobile" ,
267
266
"similar_technologies" : null ,
268
267
"description" : " Smartsupp is a live chat tool that offers visitor recording feature." ,
269
- "origins" : 25649 ,
268
+ "origins" : {
269
+ "desktop" : 22178 ,
270
+ "mobile" : 25649
271
+ },
270
272
"technology" : " Smartsupp" ,
271
273
"category" : " Live chat"
272
274
}
Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ class Presenters:
3
3
@staticmethod
4
4
def technology (item ):
5
5
return {
6
- 'client' : item ['client' ],
7
6
'similar_technologies' : item ['similar_technologies' ],
8
7
'description' : item ['description' ],
9
8
'origins' : item ['origins' ],
Original file line number Diff line number Diff line change @@ -29,13 +29,10 @@ def list_data(params):
29
29
filter = FieldFilter ("category_obj" , "array_contains_any" , params_array )
30
30
)
31
31
32
- if "client" in params :
33
- query = query .where (filter = FieldFilter ("client" , "==" , params ["client" ]))
34
-
35
32
documents = query .stream ()
36
33
data = []
37
34
38
- if "onlyname" in params and "client" not in params :
35
+ if "onlyname" in params :
39
36
appended_tech = set ()
40
37
for doc in documents :
41
38
tech = doc .get ("technology" )
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ def validate(self):
13
13
# self.add_error("technology", "missing technology parameter")
14
14
15
15
return Result (errors = self .errors , result = self .params )
16
-
16
+
17
17
def add_error (self , key , error ):
18
18
self .errors .append ([key , error ])
19
19
You can’t perform that action at this time.
0 commit comments