Septzzz commited on
Commit
0bd6ccf
·
verified ·
1 Parent(s): 7d0f0c3

Upload folder using huggingface_hub (part 26)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. toolbench/toolenv/tools/Weather/ambee_air_quality.json +163 -0
  2. toolbench/toolenv/tools/Weather/ambee_air_quality/api.py +133 -0
  3. toolbench/toolenv/tools/Weather/ambee_water_vapor_data.json +94 -0
  4. toolbench/toolenv/tools/Weather/ambee_water_vapor_data/api.py +54 -0
  5. toolbench/toolenv/tools/Weather/ambee_weather_data.json +50 -0
  6. toolbench/toolenv/tools/Weather/ambee_weather_data/api.py +31 -0
  7. toolbench/toolenv/tools/Weather/apii/api.py +29 -0
  8. toolbench/toolenv/tools/Weather/apjoy_weather_forecast.json +44 -0
  9. toolbench/toolenv/tools/Weather/apjoy_weather_forecast/api.py +33 -0
  10. toolbench/toolenv/tools/Weather/aviation_weather_center.json +197 -0
  11. toolbench/toolenv/tools/Weather/aviation_weather_center/api.py +132 -0
  12. toolbench/toolenv/tools/Weather/climate/api.py +50 -0
  13. toolbench/toolenv/tools/Weather/climate_api.json +53 -0
  14. toolbench/toolenv/tools/Weather/climate_api/api.py +50 -0
  15. toolbench/toolenv/tools/Weather/climate_app.json +47 -0
  16. toolbench/toolenv/tools/Weather/climate_app/api.py +50 -0
  17. toolbench/toolenv/tools/Weather/climate_change/api.py +50 -0
  18. toolbench/toolenv/tools/Weather/climate_change_live_at.json +47 -0
  19. toolbench/toolenv/tools/Weather/climate_change_live_at/api.py +50 -0
  20. toolbench/toolenv/tools/Weather/climate_change_news.json +44 -0
  21. toolbench/toolenv/tools/Weather/climate_change_news/api.py +50 -0
  22. toolbench/toolenv/tools/Weather/climate_change_v2/api.py +71 -0
  23. toolbench/toolenv/tools/Weather/climate_change_v3/api.py +50 -0
  24. toolbench/toolenv/tools/Weather/climate_data.json +134 -0
  25. toolbench/toolenv/tools/Weather/climate_data/api.py +120 -0
  26. toolbench/toolenv/tools/Weather/climate_news.json +157 -0
  27. toolbench/toolenv/tools/Weather/climate_news/api.py +92 -0
  28. toolbench/toolenv/tools/Weather/climates.json +44 -0
  29. toolbench/toolenv/tools/Weather/climates/api.py +50 -0
  30. toolbench/toolenv/tools/Weather/cloud_cast.json +137 -0
  31. toolbench/toolenv/tools/Weather/cloud_cast/api.py +134 -0
  32. toolbench/toolenv/tools/Weather/currencyconverter.json +24 -0
  33. toolbench/toolenv/tools/Weather/currencyconverter/api.py +29 -0
  34. toolbench/toolenv/tools/Weather/daily_limit_check.json +31 -0
  35. toolbench/toolenv/tools/Weather/daily_limit_check/api.py +31 -0
  36. toolbench/toolenv/tools/Weather/dark_sky/api.py +76 -0
  37. toolbench/toolenv/tools/Weather/darksky.json +117 -0
  38. toolbench/toolenv/tools/Weather/demo_project.json +105 -0
  39. toolbench/toolenv/tools/Weather/dz_meteo_live.json +50 -0
  40. toolbench/toolenv/tools/Weather/dz_meteo_live/api.py +60 -0
  41. toolbench/toolenv/tools/Weather/easy_air_quality.json +37 -0
  42. toolbench/toolenv/tools/Weather/easy_air_quality/api.py +29 -0
  43. toolbench/toolenv/tools/Weather/easy_weather.json +0 -0
  44. toolbench/toolenv/tools/Weather/easy_weather/api.py +220 -0
  45. toolbench/toolenv/tools/Weather/evilbudz_net.json +24 -0
  46. toolbench/toolenv/tools/Weather/excarta_apis.json +69 -0
  47. toolbench/toolenv/tools/Weather/excarta_apis/api.py +50 -0
  48. toolbench/toolenv/tools/Weather/fliteintel.json +211 -0
  49. toolbench/toolenv/tools/Weather/fliteintel/api.py +218 -0
  50. toolbench/toolenv/tools/Weather/forcast_base.json +24 -0
toolbench/toolenv/tools/Weather/ambee_air_quality.json ADDED
@@ -0,0 +1,163 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Ambee Air Quality",
3
+ "tool_description":"Global hyperlocal real-time air quality API for 1M+ postcodes. Test an API call. Get accurate & actionable air quality data.",
4
+ "title":"Ambee Air Quality",
5
+ "pricing":"FREE",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":208,
9
+ "avgSuccessRate":0,
10
+ "popularityScore":0.1,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/subhashambee/api/ambee-air-quality/",
14
+ "host":"ambee-air-quality.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"By Coordinates",
18
+ "url":"https://ambee-air-quality.p.rapidapi.com/latest/by-lat-lng",
19
+ "description":"Get nearest places readings based around the given latitude and longitude",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"lat",
24
+ "type":"NUMBER",
25
+ "description":"Specifies latitude",
26
+ "default":"20.59"
27
+ },
28
+ {
29
+ "name":"lng",
30
+ "type":"NUMBER",
31
+ "description":"Specifies longitude",
32
+ "default":"78.96"
33
+ }
34
+ ],
35
+ "optional_parameters":[
36
+ {
37
+ "name":"limit",
38
+ "type":"NUMBER",
39
+ "description":"Limits the number of rows returned",
40
+ "default":"10"
41
+ }
42
+ ],
43
+ "code":"import requests\n\nurl = \"https://ambee-air-quality.p.rapidapi.com/latest/by-lat-lng\"\nquerystring = {\"lat\": lat, \"lng\": lng, \"limit\": limit}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
44
+ "statuscode":111,
45
+ "body":"",
46
+ "headers":"",
47
+ "schema":""
48
+ },
49
+ {
50
+ "name":"By Postal Code",
51
+ "url":"https://ambee-air-quality.p.rapidapi.com/latest/by-postal-code",
52
+ "description":"Check air quality for your postal code",
53
+ "method":"GET",
54
+ "required_parameters":[
55
+ {
56
+ "name":"postalCode",
57
+ "type":"NUMBER",
58
+ "description":"Postal code to display the air quality for",
59
+ "default":"560001"
60
+ }
61
+ ],
62
+ "optional_parameters":[
63
+ {
64
+ "name":"limit",
65
+ "type":"NUMBER",
66
+ "description":"The number of rows to be displayed",
67
+ "default":"10"
68
+ }
69
+ ],
70
+ "code":"import requests\n\nurl = \"https://ambee-air-quality.p.rapidapi.com/latest/by-postal-code\"\nquerystring = {\"postalCode\": postalcode, \"limit\": limit}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
71
+ "statuscode":111,
72
+ "body":"",
73
+ "headers":"",
74
+ "schema":""
75
+ },
76
+ {
77
+ "name":"By City",
78
+ "url":"https://ambee-air-quality.p.rapidapi.com/latest/by-city",
79
+ "description":"Get the latest air quality data for your city",
80
+ "method":"GET",
81
+ "required_parameters":[
82
+ {
83
+ "name":"city",
84
+ "type":"STRING",
85
+ "description":"The name of the city for which you want the air quality",
86
+ "default":"Mumbai"
87
+ },
88
+ {
89
+ "name":"limit",
90
+ "type":"NUMBER",
91
+ "description":"The number of rows to be returned",
92
+ "default":"10"
93
+ }
94
+ ],
95
+ "optional_parameters":[],
96
+ "code":"import requests\n\nurl = \"https://ambee-air-quality.p.rapidapi.com/latest/by-city\"\nquerystring = {\"city\": city, \"limit\": limit}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
97
+ "statuscode":111,
98
+ "body":"",
99
+ "headers":"",
100
+ "schema":""
101
+ },
102
+ {
103
+ "name":"By Country",
104
+ "url":"https://ambee-air-quality.p.rapidapi.com/latest/by-country-code",
105
+ "description":"Provides the air quality data for a country",
106
+ "method":"GET",
107
+ "required_parameters":[
108
+ {
109
+ "name":"countryCode",
110
+ "type":"STRING",
111
+ "description":"The international country code for the country you want the air quality for",
112
+ "default":"IN"
113
+ }
114
+ ],
115
+ "optional_parameters":[
116
+ {
117
+ "name":"limit",
118
+ "type":"NUMBER",
119
+ "description":"The number of rows to be returned",
120
+ "default":"10"
121
+ }
122
+ ],
123
+ "code":"import requests\n\nurl = \"https://ambee-air-quality.p.rapidapi.com/latest/by-country-code\"\nquerystring = {\"limit\": limit, \"countryCode\": countrycode}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
124
+ "statuscode":111,
125
+ "body":"",
126
+ "headers":"",
127
+ "schema":""
128
+ },
129
+ {
130
+ "name":"Weather",
131
+ "url":"https://ambee-air-quality.p.rapidapi.com/weather/by-lat-lng",
132
+ "description":"Get weather data for any place based on coordinates",
133
+ "method":"GET",
134
+ "required_parameters":[
135
+ {
136
+ "name":"lat",
137
+ "type":"NUMBER",
138
+ "description":"Latitude of the coordinate to get the weather",
139
+ "default":"12"
140
+ },
141
+ {
142
+ "name":"lng",
143
+ "type":"NUMBER",
144
+ "description":"Longitude of the coordinate to find the weather",
145
+ "default":"77"
146
+ }
147
+ ],
148
+ "optional_parameters":[
149
+ {
150
+ "name":"limit",
151
+ "type":"NUMBER",
152
+ "description":"The number of rows to be returned",
153
+ "default":"10"
154
+ }
155
+ ],
156
+ "code":"import requests\n\nurl = \"https://ambee-air-quality.p.rapidapi.com/weather/by-lat-lng\"\nquerystring = {\"lat\": lat, \"lng\": lng, \"limit\": limit}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
157
+ "statuscode":111,
158
+ "body":"",
159
+ "headers":"",
160
+ "schema":""
161
+ }
162
+ ]
163
+ }
toolbench/toolenv/tools/Weather/ambee_air_quality/api.py ADDED
@@ -0,0 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def by_coordinates(lat: int, lng: int, limit: int=10, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get nearest places readings based around the given latitude and longitude"
12
+ lat: Specifies latitude
13
+ lng: Specifies longitude
14
+ limit: Limits the number of rows returned
15
+
16
+ """
17
+ url = f"https://ambee-air-quality.p.rapidapi.com/latest/by-lat-lng"
18
+ querystring = {'lat': lat, 'lng': lng, }
19
+ if limit:
20
+ querystring['limit'] = limit
21
+
22
+ headers = {
23
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
24
+ "X-RapidAPI-Host": "ambee-air-quality.p.rapidapi.com"
25
+ }
26
+
27
+
28
+ response = requests.get(url, headers=headers, params=querystring)
29
+ try:
30
+ observation = response.json()
31
+ except:
32
+ observation = response.text
33
+ return observation
34
+
35
+ def by_postal_code(postalcode: int, limit: int=10, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
36
+ """
37
+ "Check air quality for your postal code"
38
+ postalcode: Postal code to display the air quality for
39
+ limit: The number of rows to be displayed
40
+
41
+ """
42
+ url = f"https://ambee-air-quality.p.rapidapi.com/latest/by-postal-code"
43
+ querystring = {'postalCode': postalcode, }
44
+ if limit:
45
+ querystring['limit'] = limit
46
+
47
+ headers = {
48
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
49
+ "X-RapidAPI-Host": "ambee-air-quality.p.rapidapi.com"
50
+ }
51
+
52
+
53
+ response = requests.get(url, headers=headers, params=querystring)
54
+ try:
55
+ observation = response.json()
56
+ except:
57
+ observation = response.text
58
+ return observation
59
+
60
+ def by_city(city: str, limit: int, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
61
+ """
62
+ "Get the latest air quality data for your city"
63
+ city: The name of the city for which you want the air quality
64
+ limit: The number of rows to be returned
65
+
66
+ """
67
+ url = f"https://ambee-air-quality.p.rapidapi.com/latest/by-city"
68
+ querystring = {'city': city, 'limit': limit, }
69
+
70
+ headers = {
71
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
72
+ "X-RapidAPI-Host": "ambee-air-quality.p.rapidapi.com"
73
+ }
74
+
75
+
76
+ response = requests.get(url, headers=headers, params=querystring)
77
+ try:
78
+ observation = response.json()
79
+ except:
80
+ observation = response.text
81
+ return observation
82
+
83
+ def by_country(countrycode: str, limit: int=10, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
84
+ """
85
+ "Provides the air quality data for a country"
86
+ countrycode: The international country code for the country you want the air quality for
87
+ limit: The number of rows to be returned
88
+
89
+ """
90
+ url = f"https://ambee-air-quality.p.rapidapi.com/latest/by-country-code"
91
+ querystring = {'countryCode': countrycode, }
92
+ if limit:
93
+ querystring['limit'] = limit
94
+
95
+ headers = {
96
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
97
+ "X-RapidAPI-Host": "ambee-air-quality.p.rapidapi.com"
98
+ }
99
+
100
+
101
+ response = requests.get(url, headers=headers, params=querystring)
102
+ try:
103
+ observation = response.json()
104
+ except:
105
+ observation = response.text
106
+ return observation
107
+
108
+ def weather(lat: int, lng: int, limit: int=10, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
109
+ """
110
+ "Get weather data for any place based on coordinates"
111
+ lat: Latitude of the coordinate to get the weather
112
+ lng: Longitude of the coordinate to find the weather
113
+ limit: The number of rows to be returned
114
+
115
+ """
116
+ url = f"https://ambee-air-quality.p.rapidapi.com/weather/by-lat-lng"
117
+ querystring = {'lat': lat, 'lng': lng, }
118
+ if limit:
119
+ querystring['limit'] = limit
120
+
121
+ headers = {
122
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
123
+ "X-RapidAPI-Host": "ambee-air-quality.p.rapidapi.com"
124
+ }
125
+
126
+
127
+ response = requests.get(url, headers=headers, params=querystring)
128
+ try:
129
+ observation = response.json()
130
+ except:
131
+ observation = response.text
132
+ return observation
133
+
toolbench/toolenv/tools/Weather/ambee_water_vapor_data.json ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Ambee Water Vapor Data",
3
+ "tool_description":"World’s first ever water vapor API. Integrate water vapor API for global real-time water vapor information. Test an API call. Get accurate & actionable data insights.",
4
+ "title":"Ambee Water Vapor Data",
5
+ "pricing":"FREE",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":182,
9
+ "avgSuccessRate":0,
10
+ "popularityScore":0.1,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/subhashambee/api/ambee-water-vapor-data/",
14
+ "host":"ambee-water-vapor-data.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Water Vapour Data By Coordinates",
18
+ "url":"https://ambee-water-vapor-data.p.rapidapi.com/waterVapor/latest/by-lat-lng",
19
+ "description":"Get Water Vapour data by Coordinates",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"lat",
24
+ "type":"NUMBER",
25
+ "description":"",
26
+ "default":"12.9716"
27
+ },
28
+ {
29
+ "name":"lng",
30
+ "type":"NUMBER",
31
+ "description":"",
32
+ "default":"77.5946"
33
+ }
34
+ ],
35
+ "optional_parameters":[
36
+ {
37
+ "name":"maxDistance",
38
+ "type":"NUMBER",
39
+ "description":"",
40
+ "default":""
41
+ },
42
+ {
43
+ "name":"limit",
44
+ "type":"NUMBER",
45
+ "description":"",
46
+ "default":""
47
+ }
48
+ ],
49
+ "code":"import requests\n\nurl = \"https://ambee-water-vapor-data.p.rapidapi.com/waterVapor/latest/by-lat-lng\"\nquerystring = {\"lat\": lat, \"lng\": lng}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-water-vapor-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
50
+ "statuscode":111,
51
+ "body":"",
52
+ "headers":"",
53
+ "schema":""
54
+ },
55
+ {
56
+ "name":"Water Vapour History by Lat Lng",
57
+ "url":"https://ambee-water-vapor-data.p.rapidapi.com/waterVapor/history/by-lat-lng",
58
+ "description":"Water vapour History by lat lng",
59
+ "method":"GET",
60
+ "required_parameters":[
61
+ {
62
+ "name":"lat",
63
+ "type":"NUMBER",
64
+ "description":"",
65
+ "default":"20.59"
66
+ },
67
+ {
68
+ "name":"lng",
69
+ "type":"NUMBER",
70
+ "description":"",
71
+ "default":"78.96"
72
+ },
73
+ {
74
+ "name":"endDate",
75
+ "type":"STRING",
76
+ "description":"",
77
+ "default":"'YYYY-MM-DD hh:mm:ss'"
78
+ },
79
+ {
80
+ "name":"startDate",
81
+ "type":"STRING",
82
+ "description":"",
83
+ "default":"'YYYY-MM-DD hh:mm:ss'"
84
+ }
85
+ ],
86
+ "optional_parameters":[],
87
+ "code":"import requests\n\nurl = \"https://ambee-water-vapor-data.p.rapidapi.com/waterVapor/history/by-lat-lng\"\nquerystring = {\"lat\": lat, \"lng\": lng, \"endDate\": enddate, \"startDate\": startdate}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-water-vapor-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
88
+ "statuscode":111,
89
+ "body":"",
90
+ "headers":"",
91
+ "schema":""
92
+ }
93
+ ]
94
+ }
toolbench/toolenv/tools/Weather/ambee_water_vapor_data/api.py ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def water_vapour_data_by_coordinates(lat: int, lng: int, maxdistance: int=None, limit: int=None, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get Water Vapour data by Coordinates"
12
+
13
+ """
14
+ url = f"https://ambee-water-vapor-data.p.rapidapi.com/watervapor/latest/by-lat-lng"
15
+ querystring = {'lat': lat, 'lng': lng, }
16
+ if maxdistance:
17
+ querystring['maxDistance'] = maxdistance
18
+ if limit:
19
+ querystring['limit'] = limit
20
+
21
+ headers = {
22
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
23
+ "X-RapidAPI-Host": "ambee-water-vapor-data.p.rapidapi.com"
24
+ }
25
+
26
+
27
+ response = requests.get(url, headers=headers, params=querystring)
28
+ try:
29
+ observation = response.json()
30
+ except:
31
+ observation = response.text
32
+ return observation
33
+
34
+ def water_vapour_history_by_lat_lng(lat: int, lng: int, enddate: str, startdate: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
35
+ """
36
+ "Water vapour History by lat lng"
37
+
38
+ """
39
+ url = f"https://ambee-water-vapor-data.p.rapidapi.com/watervapor/history/by-lat-lng"
40
+ querystring = {'lat': lat, 'lng': lng, 'endDate': enddate, 'startDate': startdate, }
41
+
42
+ headers = {
43
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
44
+ "X-RapidAPI-Host": "ambee-water-vapor-data.p.rapidapi.com"
45
+ }
46
+
47
+
48
+ response = requests.get(url, headers=headers, params=querystring)
49
+ try:
50
+ observation = response.json()
51
+ except:
52
+ observation = response.text
53
+ return observation
54
+
toolbench/toolenv/tools/Weather/ambee_weather_data.json ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Ambee Weather Data",
3
+ "tool_description":"Ambee’s Weather API enables weather forecasting by providing real-time weather data. Test an API call. Get accurate & actionable proprietary data insights.",
4
+ "title":"Ambee Weather Data",
5
+ "pricing":"FREE",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":246,
9
+ "avgSuccessRate":0,
10
+ "popularityScore":0.1,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/subhashambee/api/ambee-weather-data/",
14
+ "host":"ambee-weather-data.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"By Coordinates",
18
+ "url":"https://ambee-weather-data.p.rapidapi.com/weather/by-lat-lng",
19
+ "description":"Ambee’s Weather API enables weather forecasting by providing real-time weather data. Test an API call. Get accurate & actionable proprietary data insights.",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"lng",
24
+ "type":"NUMBER",
25
+ "description":"",
26
+ "default":""
27
+ },
28
+ {
29
+ "name":"lat",
30
+ "type":"NUMBER",
31
+ "description":"",
32
+ "default":""
33
+ }
34
+ ],
35
+ "optional_parameters":[
36
+ {
37
+ "name":"limit",
38
+ "type":"NUMBER",
39
+ "description":"",
40
+ "default":""
41
+ }
42
+ ],
43
+ "code":"import requests\n\nurl = \"https://ambee-weather-data.p.rapidapi.com/weather/by-lat-lng\"\nquerystring = {\"lng\": lng, \"lat\": lat}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"ambee-weather-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
44
+ "statuscode":111,
45
+ "body":"",
46
+ "headers":"",
47
+ "schema":""
48
+ }
49
+ ]
50
+ }
toolbench/toolenv/tools/Weather/ambee_weather_data/api.py ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def by_coordinates(lng: int, lat: int, limit: int=None, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Ambee’s Weather API enables weather forecasting by providing real-time weather data. Test an API call. Get accurate & actionable proprietary data insights."
12
+
13
+ """
14
+ url = f"https://ambee-weather-data.p.rapidapi.com/weather/by-lat-lng"
15
+ querystring = {'lng': lng, 'lat': lat, }
16
+ if limit:
17
+ querystring['limit'] = limit
18
+
19
+ headers = {
20
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
21
+ "X-RapidAPI-Host": "ambee-weather-data.p.rapidapi.com"
22
+ }
23
+
24
+
25
+ response = requests.get(url, headers=headers, params=querystring)
26
+ try:
27
+ observation = response.json()
28
+ except:
29
+ observation = response.text
30
+ return observation
31
+
toolbench/toolenv/tools/Weather/apii/api.py ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def sunme(daylength: str, sunrise: str, sunset: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "dsfadf"
12
+
13
+ """
14
+ url = f"https://apii7.p.rapidapi.com/{sunrise}/{sunset}/{daylength}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "apii7.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
toolbench/toolenv/tools/Weather/apjoy_weather_forecast.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"APJOY-Weather Forecast",
3
+ "tool_description":"APJOY-Weather Forecast is a comprehensive and reliable weather forecasting API tailored for your location. Access real-time data, including temperature, humidity, wind speed, and precipitation, as well as short-term and long-term forecasts. Plan your day effortlessly with hourly updates and stay ahead with our 7-day and 14-day predictions. Ideal for developers and businesses in sectors like travel, agriculture, event planning, and more. Enhance your applications and services with accurate, lo...",
4
+ "title":"APJOY-Weather Forecast",
5
+ "pricing":"FREEMIUM",
6
+ "score":{
7
+ "avgServiceLevel":99,
8
+ "avgLatency":29908,
9
+ "avgSuccessRate":90,
10
+ "popularityScore":9.5,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/tekoolproducts/api/apjoy-weather-forecast/",
14
+ "host":"apjoy-weather-forecast.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"GetWeatherForecast",
18
+ "url":"https://apjoy-weather-forecast.p.rapidapi.com/forecast",
19
+ "description":"This endpoint provides weather forecast information based on the user's location. It returns the current weather conditions, daily forecasts, and additional weather data, such as temperature, humidity, and wind speed. The data is sourced from OpenWeatherMap, ensuring accurate and reliable information.",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"location",
24
+ "type":"STRING",
25
+ "description":"The name of the city or location for which to retrieve the weather forecast.",
26
+ "default":"London"
27
+ }
28
+ ],
29
+ "optional_parameters":[
30
+ {
31
+ "name":"days",
32
+ "type":"NUMBER",
33
+ "description":"The number of days of forecast data to retrieve (1-16). If not provided, it defaults to 1 day.",
34
+ "default":"3"
35
+ }
36
+ ],
37
+ "code":"import requests\n\nurl = \"https://apjoy-weather-forecast.p.rapidapi.com/forecast\"\nquerystring = {\"days\": days, \"location\": location}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"apjoy-weather-forecast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
38
+ "statuscode":111,
39
+ "body":"",
40
+ "headers":"",
41
+ "schema":""
42
+ }
43
+ ]
44
+ }
toolbench/toolenv/tools/Weather/apjoy_weather_forecast/api.py ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def getweatherforecast(location: str, days: int=3, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "This endpoint provides weather forecast information based on the user's location. It returns the current weather conditions, daily forecasts, and additional weather data, such as temperature, humidity, and wind speed. The data is sourced from OpenWeatherMap, ensuring accurate and reliable information."
12
+ location: The name of the city or location for which to retrieve the weather forecast.
13
+ days: The number of days of forecast data to retrieve (1-16). If not provided, it defaults to 1 day.
14
+
15
+ """
16
+ url = f"https://apjoy-weather-forecast.p.rapidapi.com/forecast"
17
+ querystring = {'location': location, }
18
+ if days:
19
+ querystring['days'] = days
20
+
21
+ headers = {
22
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
23
+ "X-RapidAPI-Host": "apjoy-weather-forecast.p.rapidapi.com"
24
+ }
25
+
26
+
27
+ response = requests.get(url, headers=headers, params=querystring)
28
+ try:
29
+ observation = response.json()
30
+ except:
31
+ observation = response.text
32
+ return observation
33
+
toolbench/toolenv/tools/Weather/aviation_weather_center.json ADDED
@@ -0,0 +1,197 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Aviation Weather Center",
3
+ "tool_description":"This API provides official aviation weather data, including SIGMETs, AIRMETs, METARs, TAFs and PIREPs from NOAA, available on aviationweather.gov",
4
+ "title":"Aviation Weather Center",
5
+ "pricing":"FREE",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":117,
9
+ "avgSuccessRate":100,
10
+ "popularityScore":9.6,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/noaa/api/aviation-weather-center/",
14
+ "host":"aviation-weather-center.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Multiple Stations Info",
18
+ "url":"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam",
19
+ "description":"Information about multiple weather reporting stations.",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"stationString",
24
+ "type":"ARRAY",
25
+ "description":"",
26
+ "default":"KSFO,KDEN,KJFK"
27
+ },
28
+ {
29
+ "name":"datasource",
30
+ "type":"STRING",
31
+ "description":"",
32
+ "default":"stations"
33
+ }
34
+ ],
35
+ "optional_parameters":[],
36
+ "code":"import requests\n\nurl = \"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam\"\nquerystring = {\"stationString\": stationstring, \"datasource\": datasource}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"aviation-weather-center.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
37
+ "statuscode":111,
38
+ "body":"",
39
+ "headers":"",
40
+ "schema":""
41
+ },
42
+ {
43
+ "name":"Station Info",
44
+ "url":"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam",
45
+ "description":"Information about a weather reporting station.",
46
+ "method":"GET",
47
+ "required_parameters":[
48
+ {
49
+ "name":"datasource",
50
+ "type":"STRING",
51
+ "description":"",
52
+ "default":"stations"
53
+ },
54
+ {
55
+ "name":"stationString",
56
+ "type":"STRING",
57
+ "description":"",
58
+ "default":"KSFO"
59
+ }
60
+ ],
61
+ "optional_parameters":[],
62
+ "code":"import requests\n\nurl = \"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam\"\nquerystring = {\"datasource\": datasource, \"stationString\": stationstring}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"aviation-weather-center.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
63
+ "statuscode":111,
64
+ "body":"",
65
+ "headers":"",
66
+ "schema":""
67
+ },
68
+ {
69
+ "name":"Most Recent TAFs",
70
+ "url":"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam",
71
+ "description":"Obtain the most recent TAFs from the past X hours. If you use the `mostRecent` flag only one TAF is returned. Otherwise, all TAFs from the specified time window will be returned.",
72
+ "method":"GET",
73
+ "required_parameters":[],
74
+ "optional_parameters":[
75
+ {
76
+ "name":"mostRecentForEachStation",
77
+ "type":"ENUM",
78
+ "description":"Used to get the most recent value for EACH station when multiple stations are specified\n\n- **constraint** - request the most recent for each METAR station in the fastest fashion. Not appropriate for historical data retrieval\n- **postfilter** - post filter results after applying all other constraints\n- **true** - same as 'postfilter' method\n- **false** - don't get the most recent for each METAR station, equivalent to omitting this parameter",
79
+ "default":""
80
+ },
81
+ {
82
+ "name":"datasource",
83
+ "type":"STRING",
84
+ "description":"",
85
+ "default":"tafs"
86
+ },
87
+ {
88
+ "name":"stationString",
89
+ "type":"STRING",
90
+ "description":"Specify a station as a four character ICAO code (example: `KSFO`).\nCan specify multiple comma separated stations (example: `KSFO,KSQL,KSNS`).",
91
+ "default":"KSFO"
92
+ },
93
+ {
94
+ "name":"mostRecent",
95
+ "type":"BOOLEAN",
96
+ "description":"",
97
+ "default":"true"
98
+ },
99
+ {
100
+ "name":"hoursBeforeNow",
101
+ "type":"NUMBER",
102
+ "description":"",
103
+ "default":"1.5"
104
+ }
105
+ ],
106
+ "code":"import requests\n\nurl = \"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam\"\nquerystring = {\"datasource\": datasource, \"stationString\": stationstring, \"mostRecent\": mostrecent, \"hoursBeforeNow\": hoursbeforenow}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"aviation-weather-center.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
107
+ "statuscode":111,
108
+ "body":"",
109
+ "headers":"",
110
+ "schema":""
111
+ },
112
+ {
113
+ "name":"Most Recent METARs",
114
+ "url":"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam",
115
+ "description":"Obtain the most recent METARs from the past X hours. If you use the `mostRecent` flag only one METAR is returned. Otherwise, all METARs from the specified time window will be returned.",
116
+ "method":"GET",
117
+ "required_parameters":[
118
+ {
119
+ "name":"datasource",
120
+ "type":"STRING",
121
+ "description":"",
122
+ "default":"metars"
123
+ }
124
+ ],
125
+ "optional_parameters":[
126
+ {
127
+ "name":"mostRecentForEachStation",
128
+ "type":"ENUM",
129
+ "description":"Used to get the most recent value for EACH station when multiple stations are specified\n\n- **constraint** - request the most recent for each METAR station in the fastest fashion. Not appropriate for historical data retrieval\n- **postfilter** - post filter results after applying all other constraints\n- **true** - same as 'postfilter' method\n- **false** - don't get the most recent for each METAR station, equivalent to omitting this parameter",
130
+ "default":""
131
+ },
132
+ {
133
+ "name":"hoursBeforeNow",
134
+ "type":"NUMBER",
135
+ "description":"",
136
+ "default":"1.5"
137
+ },
138
+ {
139
+ "name":"mostRecent",
140
+ "type":"BOOLEAN",
141
+ "description":"",
142
+ "default":"true"
143
+ },
144
+ {
145
+ "name":"stationString",
146
+ "type":"STRING",
147
+ "description":"Specify a station as a four character ICAO code (example: `KSFO`).\nCan specify multiple comma separated stations (example: `KSFO,KSQL,KSNS`).",
148
+ "default":"KSQL"
149
+ }
150
+ ],
151
+ "code":"import requests\n\nurl = \"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam\"\nquerystring = {\"datasource\": datasource, \"hoursBeforeNow\": hoursbeforenow, \"mostRecent\": mostrecent, \"stationString\": stationstring}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"aviation-weather-center.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
152
+ "statuscode":111,
153
+ "body":"",
154
+ "headers":"",
155
+ "schema":""
156
+ },
157
+ {
158
+ "name":"METARs in Time Range",
159
+ "url":"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam",
160
+ "description":"Obtain all METARs for a station collected between these start and end times using ISO8601 date/time format, with UTC offset: YYYY-MM-DDThh:mm:ssZ. Please see [W3C date/time formats](http://www.w3.org/TR/NOTE-datetime).",
161
+ "method":"GET",
162
+ "required_parameters":[
163
+ {
164
+ "name":"datasource",
165
+ "type":"STRING",
166
+ "description":"",
167
+ "default":"metars"
168
+ }
169
+ ],
170
+ "optional_parameters":[
171
+ {
172
+ "name":"startTime",
173
+ "type":"STRING",
174
+ "description":"",
175
+ "default":"2021-12-15T16:48:35Z"
176
+ },
177
+ {
178
+ "name":"endTime",
179
+ "type":"STRING",
180
+ "description":"",
181
+ "default":"2021-12-15T18:48:35Z"
182
+ },
183
+ {
184
+ "name":"stationString",
185
+ "type":"STRING",
186
+ "description":"",
187
+ "default":"KSQL"
188
+ }
189
+ ],
190
+ "code":"import requests\n\nurl = \"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam\"\nquerystring = {\"datasource\": datasource, \"startTime\": starttime, \"endTime\": endtime, \"stationString\": stationstring}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"aviation-weather-center.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
191
+ "statuscode":111,
192
+ "body":"",
193
+ "headers":"",
194
+ "schema":""
195
+ }
196
+ ]
197
+ }
toolbench/toolenv/tools/Weather/aviation_weather_center/api.py ADDED
@@ -0,0 +1,132 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def station_info(datasource: str, stationstring: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Information about a weather reporting station."
12
+
13
+ """
14
+ url = f"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam"
15
+ querystring = {'datasource': datasource, 'stationString': stationstring, }
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "aviation-weather-center.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def most_recent_tafs(mostrecentforeachstation: str=None, datasource: str='tafs', stationstring: str='KSFO', mostrecent: bool=None, hoursbeforenow: int=1, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Obtain the most recent TAFs from the past X hours. If you use the `mostRecent` flag only one TAF is returned. Otherwise, all TAFs from the specified time window will be returned."
33
+ mostrecentforeachstation: Used to get the most recent value for EACH station when multiple stations are specified
34
+
35
+ - **constraint** - request the most recent for each METAR station in the fastest fashion. Not appropriate for historical data retrieval
36
+ - **postfilter** - post filter results after applying all other constraints
37
+ - **true** - same as 'postfilter' method
38
+ - **false** - don't get the most recent for each METAR station, equivalent to omitting this parameter
39
+ stationstring: Specify a station as a four character ICAO code (example: `KSFO`).
40
+ Can specify multiple comma separated stations (example: `KSFO,KSQL,KSNS`).
41
+
42
+ """
43
+ url = f"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam"
44
+ querystring = {}
45
+ if mostrecentforeachstation:
46
+ querystring['mostRecentForEachStation'] = mostrecentforeachstation
47
+ if datasource:
48
+ querystring['datasource'] = datasource
49
+ if stationstring:
50
+ querystring['stationString'] = stationstring
51
+ if mostrecent:
52
+ querystring['mostRecent'] = mostrecent
53
+ if hoursbeforenow:
54
+ querystring['hoursBeforeNow'] = hoursbeforenow
55
+
56
+ headers = {
57
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
58
+ "X-RapidAPI-Host": "aviation-weather-center.p.rapidapi.com"
59
+ }
60
+
61
+
62
+ response = requests.get(url, headers=headers, params=querystring)
63
+ try:
64
+ observation = response.json()
65
+ except:
66
+ observation = response.text
67
+ return observation
68
+
69
+ def most_recent_metars(datasource: str, mostrecentforeachstation: str=None, hoursbeforenow: int=1, mostrecent: bool=None, stationstring: str='KSQL', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
70
+ """
71
+ "Obtain the most recent METARs from the past X hours. If you use the `mostRecent` flag only one METAR is returned. Otherwise, all METARs from the specified time window will be returned."
72
+ mostrecentforeachstation: Used to get the most recent value for EACH station when multiple stations are specified
73
+
74
+ - **constraint** - request the most recent for each METAR station in the fastest fashion. Not appropriate for historical data retrieval
75
+ - **postfilter** - post filter results after applying all other constraints
76
+ - **true** - same as 'postfilter' method
77
+ - **false** - don't get the most recent for each METAR station, equivalent to omitting this parameter
78
+ stationstring: Specify a station as a four character ICAO code (example: `KSFO`).
79
+ Can specify multiple comma separated stations (example: `KSFO,KSQL,KSNS`).
80
+
81
+ """
82
+ url = f"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam"
83
+ querystring = {'datasource': datasource, }
84
+ if mostrecentforeachstation:
85
+ querystring['mostRecentForEachStation'] = mostrecentforeachstation
86
+ if hoursbeforenow:
87
+ querystring['hoursBeforeNow'] = hoursbeforenow
88
+ if mostrecent:
89
+ querystring['mostRecent'] = mostrecent
90
+ if stationstring:
91
+ querystring['stationString'] = stationstring
92
+
93
+ headers = {
94
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
95
+ "X-RapidAPI-Host": "aviation-weather-center.p.rapidapi.com"
96
+ }
97
+
98
+
99
+ response = requests.get(url, headers=headers, params=querystring)
100
+ try:
101
+ observation = response.json()
102
+ except:
103
+ observation = response.text
104
+ return observation
105
+
106
+ def metars_in_time_range(datasource: str, starttime: str='2021-12-15T16:48:35Z', endtime: str='2021-12-15T18:48:35Z', stationstring: str='KSQL', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
107
+ """
108
+ "Obtain all METARs for a station collected between these start and end times using ISO8601 date/time format, with UTC offset: YYYY-MM-DDThh:mm:ssZ. Please see [W3C date/time formats](http://www.w3.org/TR/NOTE-datetime)."
109
+
110
+ """
111
+ url = f"https://aviation-weather-center.p.rapidapi.com/adds/dataserver_current/httpparam"
112
+ querystring = {'datasource': datasource, }
113
+ if starttime:
114
+ querystring['startTime'] = starttime
115
+ if endtime:
116
+ querystring['endTime'] = endtime
117
+ if stationstring:
118
+ querystring['stationString'] = stationstring
119
+
120
+ headers = {
121
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
122
+ "X-RapidAPI-Host": "aviation-weather-center.p.rapidapi.com"
123
+ }
124
+
125
+
126
+ response = requests.get(url, headers=headers, params=querystring)
127
+ try:
128
+ observation = response.json()
129
+ except:
130
+ observation = response.text
131
+ return observation
132
+
toolbench/toolenv/tools/Weather/climate/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def search_by_id(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get data from a specific Resource"
12
+
13
+ """
14
+ url = f"https://climate13.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate13.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def myclimate_change_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "lazy description here hehe"
33
+
34
+ """
35
+ url = f"https://climate13.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate13.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_api.json ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"climate-api",
3
+ "tool_description":"climate change news api from different webistes",
4
+ "title":"climate-api",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/AlhassanMousa/api/climate-api1/",
8
+ "host":"climate-api1.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"get individual news source",
12
+ "url":"https://climate-api1.p.rapidapi.com/news/{newspaperid}",
13
+ "description":"get individual news source from different resources",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"Accept-Charset",
18
+ "type":"STRING",
19
+ "description":"",
20
+ "default":"guardian"
21
+ },
22
+ {
23
+ "name":"newspaperId",
24
+ "type":"string",
25
+ "description":"",
26
+ "default":"bbc"
27
+ }
28
+ ],
29
+ "optional_parameters":[],
30
+ "code":"import requests\n\nurl = \"https://climate-api1.p.rapidapi.com/news/{newspaperid}\"\nquerystring = {\"Accept-Charset\": accept_charset}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-api1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
31
+ "statuscode":200,
32
+ "body":{
33
+ "key1":"value",
34
+ "key2":"value"
35
+ },
36
+ "headers":{},
37
+ "schema":{}
38
+ },
39
+ {
40
+ "name":"get all news",
41
+ "url":"https://climate-api1.p.rapidapi.com/news",
42
+ "description":"get all climate change news",
43
+ "method":"GET",
44
+ "required_parameters":[],
45
+ "optional_parameters":[],
46
+ "code":"import requests\n\nurl = \"https://climate-api1.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-api1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
47
+ "statuscode":111,
48
+ "body":"",
49
+ "headers":"",
50
+ "schema":""
51
+ }
52
+ ]
53
+ }
toolbench/toolenv/tools/Weather/climate_api/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_individual_news_source(accept_charset: str, newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "get individual news source from different resources"
12
+
13
+ """
14
+ url = f"https://climate-api1.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {'Accept-Charset': accept_charset, }
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-api1.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "get all climate change news"
33
+
34
+ """
35
+ url = f"https://climate-api1.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-api1.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_app.json ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"climate-app",
3
+ "tool_description":"climate change news",
4
+ "title":"climate-app",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/Mohcinedev/api/climate-app/",
8
+ "host":"climate-app.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"get individual news",
12
+ "url":"https://climate-app.p.rapidapi.com/news/{newspaperid}",
13
+ "description":"get individual news from specified newspaper",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"newspaperId",
18
+ "type":"string",
19
+ "description":"",
20
+ "default":"thetimes"
21
+ }
22
+ ],
23
+ "optional_parameters":[],
24
+ "code":"import requests\n\nurl = \"https://climate-app.p.rapidapi.com/news/{newspaperid}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-app.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
25
+ "statuscode":200,
26
+ "body":{
27
+ "key1":"value",
28
+ "key2":"value"
29
+ },
30
+ "headers":{},
31
+ "schema":{}
32
+ },
33
+ {
34
+ "name":"get all climate news",
35
+ "url":"https://climate-app.p.rapidapi.com/news",
36
+ "description":"get all climate news urls from the available providers",
37
+ "method":"GET",
38
+ "required_parameters":[],
39
+ "optional_parameters":[],
40
+ "code":"import requests\n\nurl = \"https://climate-app.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-app.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
41
+ "statuscode":111,
42
+ "body":"",
43
+ "headers":"",
44
+ "schema":""
45
+ }
46
+ ]
47
+ }
toolbench/toolenv/tools/Weather/climate_app/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_individual_news(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "get individual news from specified newspaper"
12
+
13
+ """
14
+ url = f"https://climate-app.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-app.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_climate_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "get all climate news urls from the available providers"
33
+
34
+ """
35
+ url = f"https://climate-app.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-app.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_change/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_individual_news(newspapersid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "to get individual news"
12
+
13
+ """
14
+ url = f"https://climate-change30.p.rapidapi.com/news/{newspapersid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-change30.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_climate_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "this is end point will return news"
33
+
34
+ """
35
+ url = f"https://climate-change30.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-change30.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_change_live_at.json ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Climate Change Live _ AT",
3
+ "tool_description":"An API showing climate changes from all around the world",
4
+ "title":"Climate Change Live _ AT",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/hadress92/api/climate-change-live-_-at/",
8
+ "host":"climate-change-live-_-at.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"Specific Source Weather Changes",
12
+ "url":"https://climate-change-live-_-at.p.rapidapi.com/news/{newspaperid}",
13
+ "description":"Get all weather news from a specific source.",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"newspaperId",
18
+ "type":"string",
19
+ "description":"",
20
+ "default":"theguardian"
21
+ }
22
+ ],
23
+ "optional_parameters":[],
24
+ "code":"import requests\n\nurl = \"https://climate-change-live-_-at.p.rapidapi.com/news/{newspaperid}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-change-live-_-at.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
25
+ "statuscode":200,
26
+ "body":{
27
+ "key1":"value",
28
+ "key2":"value"
29
+ },
30
+ "headers":{},
31
+ "schema":{}
32
+ },
33
+ {
34
+ "name":"Get All Climate Change News",
35
+ "url":"https://climate-change-live-_-at.p.rapidapi.com/news",
36
+ "description":"This endpoint will return climate changes from all over the world",
37
+ "method":"GET",
38
+ "required_parameters":[],
39
+ "optional_parameters":[],
40
+ "code":"import requests\n\nurl = \"https://climate-change-live-_-at.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-change-live-_-at.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
41
+ "statuscode":111,
42
+ "body":"",
43
+ "headers":"",
44
+ "schema":""
45
+ }
46
+ ]
47
+ }
toolbench/toolenv/tools/Weather/climate_change_live_at/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def specific_source_weather_changes(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get all weather news from a specific source."
12
+
13
+ """
14
+ url = f"https://climate-change-live-_-at.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-change-live-_-at.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_climate_change_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "This endpoint will return climate changes from all over the world"
33
+
34
+ """
35
+ url = f"https://climate-change-live-_-at.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-change-live-_-at.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_change_news.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Climate Change News",
3
+ "tool_description":"It is showing all the latest climate around the world",
4
+ "title":"Climate Change News",
5
+ "pricing":"FREE",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/aniketchavan505-XiS7Z9cU7EN/api/climate-change-news57/",
8
+ "host":"climate-change-news57.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"Get Individual news from source",
12
+ "url":"https://climate-change-news57.p.rapidapi.com/news/{newspaperid}",
13
+ "description":"specific data",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"newspaperId",
18
+ "type":"string",
19
+ "description":"",
20
+ "default":"thetimes"
21
+ }
22
+ ],
23
+ "optional_parameters":[],
24
+ "code":"import requests\n\nurl = \"https://climate-change-news57.p.rapidapi.com/news/{newspaperid}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-change-news57.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
25
+ "statuscode":111,
26
+ "body":"",
27
+ "headers":"",
28
+ "schema":""
29
+ },
30
+ {
31
+ "name":"Get all climate Change news",
32
+ "url":"https://climate-change-news57.p.rapidapi.com/news",
33
+ "description":"this endpoint will return all climate all over the world",
34
+ "method":"GET",
35
+ "required_parameters":[],
36
+ "optional_parameters":[],
37
+ "code":"import requests\n\nurl = \"https://climate-change-news57.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-change-news57.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
38
+ "statuscode":111,
39
+ "body":"",
40
+ "headers":"",
41
+ "schema":""
42
+ }
43
+ ]
44
+ }
toolbench/toolenv/tools/Weather/climate_change_news/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_individual_news_from_source(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "specific data"
12
+
13
+ """
14
+ url = f"https://climate-change-news57.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-change-news57.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_climate_change_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "this endpoint will return all climate all over the world"
33
+
34
+ """
35
+ url = f"https://climate-change-news57.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-change-news57.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_change_v2/api.py ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_nasa_climate_change_evidences(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "return a list of evidences of climate change from the nasa page arch evidence contains a title, content and image"
12
+
13
+ """
14
+ url = f"https://climate-change23.p.rapidapi.com/evidence"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-change23.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_news_from_an_spesific_source(paper: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Return news from an epesific source"
33
+
34
+ """
35
+ url = f"https://climate-change23.p.rapidapi.com/news/{paper}"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-change23.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
51
+ def get_all_climate_change_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
52
+ """
53
+ "this endpoint return a list of news group by paper (four papers)"
54
+
55
+ """
56
+ url = f"https://climate-change23.p.rapidapi.com/news"
57
+ querystring = {}
58
+
59
+ headers = {
60
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
61
+ "X-RapidAPI-Host": "climate-change23.p.rapidapi.com"
62
+ }
63
+
64
+
65
+ response = requests.get(url, headers=headers, params=querystring)
66
+ try:
67
+ observation = response.json()
68
+ except:
69
+ observation = response.text
70
+ return observation
71
+
toolbench/toolenv/tools/Weather/climate_change_v3/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def climate_changed_individual_news(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "This endpoint will return all news related to global climate change."
12
+
13
+ """
14
+ url = f"https://climate-change76.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-change76.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def climate_changed_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "This endpoint will return all news related to global climate change."
33
+
34
+ """
35
+ url = f"https://climate-change76.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-change76.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/climate_data.json ADDED
@@ -0,0 +1,134 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"climate data",
3
+ "tool_description":"climate data worldwide",
4
+ "title":"climate data",
5
+ "pricing":"FREEMIUM",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":642,
9
+ "avgSuccessRate":100,
10
+ "popularityScore":9.2,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/weatheronline/api/climate-data/",
14
+ "host":"climate-data.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Search location by Name or zip code",
18
+ "url":"https://climate-data.p.rapidapi.com/api/getlocation",
19
+ "description":"Search location by Name or zip code and get the key for the forecast",
20
+ "method":"GET",
21
+ "required_parameters":[],
22
+ "optional_parameters":[
23
+ {
24
+ "name":"CITY",
25
+ "type":"STRING",
26
+ "description":"name of a city",
27
+ "default":"New York"
28
+ },
29
+ {
30
+ "name":"LANG",
31
+ "type":"STRING",
32
+ "description":"language [en,fr,nl,es,pt,it,tr,gr,cz,pl,ru,cn]",
33
+ "default":"en"
34
+ },
35
+ {
36
+ "name":"ZIPCODE",
37
+ "type":"STRING",
38
+ "description":"zip code of the city",
39
+ "default":""
40
+ }
41
+ ],
42
+ "code":"import requests\n\nurl = \"https://climate-data.p.rapidapi.com/api/getlocation\"\nquerystring = {\"CITY\": city, \"LANG\": lang}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
43
+ "statuscode":111,
44
+ "body":"",
45
+ "headers":"",
46
+ "schema":""
47
+ },
48
+ {
49
+ "name":"List of cities in one Country",
50
+ "url":"https://climate-data.p.rapidapi.com/api/countrycitylist",
51
+ "description":"List of cities in one Country",
52
+ "method":"GET",
53
+ "required_parameters":[
54
+ {
55
+ "name":"COUNTRY",
56
+ "type":"STRING",
57
+ "description":"Country Code",
58
+ "default":"UK"
59
+ }
60
+ ],
61
+ "optional_parameters":[
62
+ {
63
+ "name":"LANG",
64
+ "type":"STRING",
65
+ "description":"Language [en,fr,pl,pt,es,it,gr,tr,ru,cn,cz]",
66
+ "default":"en"
67
+ }
68
+ ],
69
+ "code":"import requests\n\nurl = \"https://climate-data.p.rapidapi.com/api/countrycitylist\"\nquerystring = {\"COUNTRY\": country, \"LANG\": lang}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
70
+ "statuscode":111,
71
+ "body":"",
72
+ "headers":"",
73
+ "schema":""
74
+ },
75
+ {
76
+ "name":"List of all Countries",
77
+ "url":"https://climate-data.p.rapidapi.com/api/countrycitylist",
78
+ "description":"List of all Countries",
79
+ "method":"GET",
80
+ "required_parameters":[],
81
+ "optional_parameters":[
82
+ {
83
+ "name":"LANG",
84
+ "type":"STRING",
85
+ "description":"Language [en,fr,de,nl,es,pt,pl,tr,gr,tr,cn]",
86
+ "default":"en"
87
+ }
88
+ ],
89
+ "code":"import requests\n\nurl = \"https://climate-data.p.rapidapi.com/api/countrycitylist\"\nquerystring = {\"LANG\": lang}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
90
+ "statuscode":111,
91
+ "body":"",
92
+ "headers":"",
93
+ "schema":""
94
+ },
95
+ {
96
+ "name":"Get climate data by lat/lon or Key",
97
+ "url":"https://climate-data.p.rapidapi.com/api/getclimatedata",
98
+ "description":"get climate for the location Lat/Lon",
99
+ "method":"GET",
100
+ "required_parameters":[],
101
+ "optional_parameters":[
102
+ {
103
+ "name":"LAT",
104
+ "type":"NUMBER",
105
+ "description":"latitude",
106
+ "default":"45"
107
+ },
108
+ {
109
+ "name":"LON",
110
+ "type":"NUMBER",
111
+ "description":"longitude",
112
+ "default":"-70"
113
+ },
114
+ {
115
+ "name":"KEY",
116
+ "type":"STRING",
117
+ "description":"key of city from List of cities",
118
+ "default":""
119
+ },
120
+ {
121
+ "name":"LANG",
122
+ "type":"STRING",
123
+ "description":"Language [en,de,nl,fr,pl,gr,it,cn,ru,cz,pt,es]",
124
+ "default":"en"
125
+ }
126
+ ],
127
+ "code":"import requests\n\nurl = \"https://climate-data.p.rapidapi.com/api/getclimatedata\"\nquerystring = {\"LAT\": lat, \"LON\": lon, \"LANG\": lang}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-data.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
128
+ "statuscode":111,
129
+ "body":"",
130
+ "headers":"",
131
+ "schema":""
132
+ }
133
+ ]
134
+ }
toolbench/toolenv/tools/Weather/climate_data/api.py ADDED
@@ -0,0 +1,120 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def search_location_by_name_or_zip_code(city: str='New York', lang: str='en', zipcode: str=None, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Search location by Name or zip code and get the key for the forecast"
12
+ city: name of a city
13
+ lang: language [en,fr,nl,es,pt,it,tr,gr,cz,pl,ru,cn]
14
+ zipcode: zip code of the city
15
+
16
+ """
17
+ url = f"https://climate-data.p.rapidapi.com/api/getlocation"
18
+ querystring = {}
19
+ if city:
20
+ querystring['CITY'] = city
21
+ if lang:
22
+ querystring['LANG'] = lang
23
+ if zipcode:
24
+ querystring['ZIPCODE'] = zipcode
25
+
26
+ headers = {
27
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
28
+ "X-RapidAPI-Host": "climate-data.p.rapidapi.com"
29
+ }
30
+
31
+
32
+ response = requests.get(url, headers=headers, params=querystring)
33
+ try:
34
+ observation = response.json()
35
+ except:
36
+ observation = response.text
37
+ return observation
38
+
39
+ def list_of_cities_in_one_country(country: str, lang: str='en', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
40
+ """
41
+ "List of cities in one Country"
42
+ country: Country Code
43
+ lang: Language [en,fr,pl,pt,es,it,gr,tr,ru,cn,cz]
44
+
45
+ """
46
+ url = f"https://climate-data.p.rapidapi.com/api/countrycitylist"
47
+ querystring = {'COUNTRY': country, }
48
+ if lang:
49
+ querystring['LANG'] = lang
50
+
51
+ headers = {
52
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
53
+ "X-RapidAPI-Host": "climate-data.p.rapidapi.com"
54
+ }
55
+
56
+
57
+ response = requests.get(url, headers=headers, params=querystring)
58
+ try:
59
+ observation = response.json()
60
+ except:
61
+ observation = response.text
62
+ return observation
63
+
64
+ def list_of_all_countries(lang: str='en', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
65
+ """
66
+ "List of all Countries"
67
+ lang: Language [en,fr,de,nl,es,pt,pl,tr,gr,tr,cn]
68
+
69
+ """
70
+ url = f"https://climate-data.p.rapidapi.com/api/countrycitylist"
71
+ querystring = {}
72
+ if lang:
73
+ querystring['LANG'] = lang
74
+
75
+ headers = {
76
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
77
+ "X-RapidAPI-Host": "climate-data.p.rapidapi.com"
78
+ }
79
+
80
+
81
+ response = requests.get(url, headers=headers, params=querystring)
82
+ try:
83
+ observation = response.json()
84
+ except:
85
+ observation = response.text
86
+ return observation
87
+
88
+ def get_climate_data_by_lat_lon_or_key(lat: int=45, lon: int=-70, key: str=None, lang: str='en', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
89
+ """
90
+ "get climate for the location Lat/Lon"
91
+ lat: latitude
92
+ lon: longitude
93
+ key: key of city from List of cities
94
+ lang: Language [en,de,nl,fr,pl,gr,it,cn,ru,cz,pt,es]
95
+
96
+ """
97
+ url = f"https://climate-data.p.rapidapi.com/api/getclimatedata"
98
+ querystring = {}
99
+ if lat:
100
+ querystring['LAT'] = lat
101
+ if lon:
102
+ querystring['LON'] = lon
103
+ if key:
104
+ querystring['KEY'] = key
105
+ if lang:
106
+ querystring['LANG'] = lang
107
+
108
+ headers = {
109
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
110
+ "X-RapidAPI-Host": "climate-data.p.rapidapi.com"
111
+ }
112
+
113
+
114
+ response = requests.get(url, headers=headers, params=querystring)
115
+ try:
116
+ observation = response.json()
117
+ except:
118
+ observation = response.text
119
+ return observation
120
+
toolbench/toolenv/tools/Weather/climate_news.json ADDED
@@ -0,0 +1,157 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Climate News",
3
+ "tool_description":"Climate News API :\nreal-time temperature data from around the world and staying up-to-date with climate change news ",
4
+ "title":"Climate News",
5
+ "pricing":"FREEMIUM",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":1262,
9
+ "avgSuccessRate":100,
10
+ "popularityScore":8.7,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/mahmoudahmed8081/api/climate-news27/",
14
+ "host":"climate-news27.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"allNews",
18
+ "url":"https://climate-news27.p.rapidapi.com/news",
19
+ "description":" ",
20
+ "method":"GET",
21
+ "required_parameters":[],
22
+ "optional_parameters":[],
23
+ "code":"import requests\n\nurl = \"https://climate-news27.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-news27.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
24
+ "statuscode":200,
25
+ "body":{},
26
+ "headers":{},
27
+ "schema":{
28
+ "type":"object",
29
+ "properties":{
30
+ "get":{
31
+ "type":"string"
32
+ },
33
+ "parameters":{
34
+ "type":"array"
35
+ },
36
+ "errors":{
37
+ "type":"array"
38
+ },
39
+ "results":{
40
+ "type":"integer"
41
+ },
42
+ "response":{
43
+ "type":"array",
44
+ "items":{
45
+ "type":"object"
46
+ }
47
+ }
48
+ }
49
+ }
50
+ },
51
+ {
52
+ "name":"welcome",
53
+ "url":"https://climate-news27.p.rapidapi.com/",
54
+ "description":" ",
55
+ "method":"GET",
56
+ "required_parameters":[],
57
+ "optional_parameters":[],
58
+ "code":"import requests\n\nurl = \"https://climate-news27.p.rapidapi.com/\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-news27.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
59
+ "statuscode":200,
60
+ "body":{},
61
+ "headers":{},
62
+ "schema":{
63
+ "type":"object",
64
+ "properties":{
65
+ "get":{
66
+ "type":"string"
67
+ },
68
+ "parameters":{
69
+ "type":"array"
70
+ },
71
+ "errors":{
72
+ "type":"array"
73
+ },
74
+ "results":{
75
+ "type":"integer"
76
+ },
77
+ "response":{
78
+ "type":"array",
79
+ "items":{
80
+ "type":"object"
81
+ }
82
+ }
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name":"customNews",
88
+ "url":"https://climate-news27.p.rapidapi.com/news/thetimes",
89
+ "description":" ",
90
+ "method":"GET",
91
+ "required_parameters":[],
92
+ "optional_parameters":[],
93
+ "code":"import requests\n\nurl = \"https://climate-news27.p.rapidapi.com/news/thetimes\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-news27.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
94
+ "statuscode":200,
95
+ "body":{},
96
+ "headers":{},
97
+ "schema":{
98
+ "type":"object",
99
+ "properties":{
100
+ "get":{
101
+ "type":"string"
102
+ },
103
+ "parameters":{
104
+ "type":"array"
105
+ },
106
+ "errors":{
107
+ "type":"array"
108
+ },
109
+ "results":{
110
+ "type":"integer"
111
+ },
112
+ "response":{
113
+ "type":"array",
114
+ "items":{
115
+ "type":"object"
116
+ }
117
+ }
118
+ }
119
+ }
120
+ },
121
+ {
122
+ "name":"weatherTemp",
123
+ "url":"https://climate-news27.p.rapidapi.com/weather/saudiarabia",
124
+ "description":" ",
125
+ "method":"GET",
126
+ "required_parameters":[],
127
+ "optional_parameters":[],
128
+ "code":"import requests\n\nurl = \"https://climate-news27.p.rapidapi.com/weather/saudiarabia\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climate-news27.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
129
+ "statuscode":200,
130
+ "body":{},
131
+ "headers":{},
132
+ "schema":{
133
+ "type":"object",
134
+ "properties":{
135
+ "get":{
136
+ "type":"string"
137
+ },
138
+ "parameters":{
139
+ "type":"array"
140
+ },
141
+ "errors":{
142
+ "type":"array"
143
+ },
144
+ "results":{
145
+ "type":"integer"
146
+ },
147
+ "response":{
148
+ "type":"array",
149
+ "items":{
150
+ "type":"object"
151
+ }
152
+ }
153
+ }
154
+ }
155
+ }
156
+ ]
157
+ }
toolbench/toolenv/tools/Weather/climate_news/api.py ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def allnews(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ " "
12
+
13
+ """
14
+ url = f"https://climate-news27.p.rapidapi.com/news"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climate-news27.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def welcome(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ " "
33
+
34
+ """
35
+ url = f"https://climate-news27.p.rapidapi.com/"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climate-news27.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
51
+ def customnews(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
52
+ """
53
+ " "
54
+
55
+ """
56
+ url = f"https://climate-news27.p.rapidapi.com/news/thetimes"
57
+ querystring = {}
58
+
59
+ headers = {
60
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
61
+ "X-RapidAPI-Host": "climate-news27.p.rapidapi.com"
62
+ }
63
+
64
+
65
+ response = requests.get(url, headers=headers, params=querystring)
66
+ try:
67
+ observation = response.json()
68
+ except:
69
+ observation = response.text
70
+ return observation
71
+
72
+ def weathertemp(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
73
+ """
74
+ " "
75
+
76
+ """
77
+ url = f"https://climate-news27.p.rapidapi.com/weather/saudiarabia"
78
+ querystring = {}
79
+
80
+ headers = {
81
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
82
+ "X-RapidAPI-Host": "climate-news27.p.rapidapi.com"
83
+ }
84
+
85
+
86
+ response = requests.get(url, headers=headers, params=querystring)
87
+ try:
88
+ observation = response.json()
89
+ except:
90
+ observation = response.text
91
+ return observation
92
+
toolbench/toolenv/tools/Weather/climates.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"climates",
3
+ "tool_description":"Shows climate related reports from different newspaper",
4
+ "title":"climates",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/abhijeetkujur000-Us0ChufhPHK/api/climates/",
8
+ "host":"climates.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"Get climate news from different news website",
12
+ "url":"https://climates.p.rapidapi.com/news/{newspaperid}",
13
+ "description":"Getting news from a particular website",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"newspaperId",
18
+ "type":"string",
19
+ "description":"",
20
+ "default":"guardian"
21
+ }
22
+ ],
23
+ "optional_parameters":[],
24
+ "code":"import requests\n\nurl = \"https://climates.p.rapidapi.com/news/{newspaperid}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climates.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
25
+ "statuscode":111,
26
+ "body":"",
27
+ "headers":"",
28
+ "schema":""
29
+ },
30
+ {
31
+ "name":"Get all climate news",
32
+ "url":"https://climates.p.rapidapi.com/news",
33
+ "description":"This endpoint will return all climate change report.",
34
+ "method":"GET",
35
+ "required_parameters":[],
36
+ "optional_parameters":[],
37
+ "code":"import requests\n\nurl = \"https://climates.p.rapidapi.com/news\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"climates.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
38
+ "statuscode":111,
39
+ "body":"",
40
+ "headers":"",
41
+ "schema":""
42
+ }
43
+ ]
44
+ }
toolbench/toolenv/tools/Weather/climates/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_climate_news_from_different_news_website(newspaperid: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Getting news from a particular website"
12
+
13
+ """
14
+ url = f"https://climates.p.rapidapi.com/news/{newspaperid}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "climates.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_all_climate_news(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "This endpoint will return all climate change report."
33
+
34
+ """
35
+ url = f"https://climates.p.rapidapi.com/news"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "climates.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/cloud_cast.json ADDED
@@ -0,0 +1,137 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Cloud Cast",
3
+ "tool_description":"Cloudcast is a simple and efficient API built with Node.js and Express, designed to provide real-time weather information for any city in the world. It is able to fetch and deliver current weather conditions including temperature, humidity, wind speed, and other vital meteorological data.",
4
+ "title":"Cloud Cast",
5
+ "pricing":"FREEMIUM",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":3531,
9
+ "avgSuccessRate":100,
10
+ "popularityScore":8.9,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/anthonys1760/api/cloud-cast/",
14
+ "host":"cloud-cast.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Get the forecast",
18
+ "url":"https://cloud-cast.p.rapidapi.com/forecast/{city}",
19
+ "description":"Get the forecast for the current city",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"city",
24
+ "type":"string",
25
+ "description":"",
26
+ "default":"New York"
27
+ }
28
+ ],
29
+ "optional_parameters":[],
30
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/forecast/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
31
+ "statuscode":111,
32
+ "body":"",
33
+ "headers":"",
34
+ "schema":""
35
+ },
36
+ {
37
+ "name":"Get hourly forecast",
38
+ "url":"https://cloud-cast.p.rapidapi.com/hourly/{city}",
39
+ "description":"Get the hourly forecast",
40
+ "method":"GET",
41
+ "required_parameters":[
42
+ {
43
+ "name":"city",
44
+ "type":"string",
45
+ "description":"",
46
+ "default":"New York"
47
+ }
48
+ ],
49
+ "optional_parameters":[],
50
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/hourly/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
51
+ "statuscode":111,
52
+ "body":"",
53
+ "headers":"",
54
+ "schema":""
55
+ },
56
+ {
57
+ "name":"Get wind speed",
58
+ "url":"https://cloud-cast.p.rapidapi.com/wind/{city}",
59
+ "description":"Get the current wind speed",
60
+ "method":"GET",
61
+ "required_parameters":[
62
+ {
63
+ "name":"city",
64
+ "type":"string",
65
+ "description":"",
66
+ "default":"New York"
67
+ }
68
+ ],
69
+ "optional_parameters":[],
70
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/wind/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
71
+ "statuscode":111,
72
+ "body":"",
73
+ "headers":"",
74
+ "schema":""
75
+ },
76
+ {
77
+ "name":"Get current weather",
78
+ "url":"https://cloud-cast.p.rapidapi.com/weather/{city}",
79
+ "description":"Gets the current weather for the inputted city name",
80
+ "method":"GET",
81
+ "required_parameters":[
82
+ {
83
+ "name":"city",
84
+ "type":"string",
85
+ "description":"",
86
+ "default":"New York"
87
+ }
88
+ ],
89
+ "optional_parameters":[],
90
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/weather/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
91
+ "statuscode":111,
92
+ "body":"",
93
+ "headers":"",
94
+ "schema":""
95
+ },
96
+ {
97
+ "name":"Get humidty",
98
+ "url":"https://cloud-cast.p.rapidapi.com/humidity/{city}",
99
+ "description":"Get the humidity for the current city",
100
+ "method":"GET",
101
+ "required_parameters":[
102
+ {
103
+ "name":"city",
104
+ "type":"string",
105
+ "description":"",
106
+ "default":"New York"
107
+ }
108
+ ],
109
+ "optional_parameters":[],
110
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/humidity/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
111
+ "statuscode":111,
112
+ "body":"",
113
+ "headers":"",
114
+ "schema":""
115
+ },
116
+ {
117
+ "name":"Get City Info",
118
+ "url":"https://cloud-cast.p.rapidapi.com/find-cities/{city}",
119
+ "description":"These endpoints allow you to retrieve weather and forecast data for specific cities without providing latitude and longitude.",
120
+ "method":"GET",
121
+ "required_parameters":[
122
+ {
123
+ "name":"city",
124
+ "type":"string",
125
+ "description":"",
126
+ "default":"New York"
127
+ }
128
+ ],
129
+ "optional_parameters":[],
130
+ "code":"import requests\n\nurl = \"https://cloud-cast.p.rapidapi.com/find-cities/{city}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"cloud-cast.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
131
+ "statuscode":111,
132
+ "body":"",
133
+ "headers":"",
134
+ "schema":""
135
+ }
136
+ ]
137
+ }
toolbench/toolenv/tools/Weather/cloud_cast/api.py ADDED
@@ -0,0 +1,134 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_the_forecast(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get the forecast for the current city"
12
+
13
+ """
14
+ url = f"https://cloud-cast.p.rapidapi.com/forecast/{city}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def get_hourly_forecast(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Get the hourly forecast"
33
+
34
+ """
35
+ url = f"https://cloud-cast.p.rapidapi.com/hourly/{city}"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
51
+ def get_wind_speed(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
52
+ """
53
+ "Get the current wind speed"
54
+
55
+ """
56
+ url = f"https://cloud-cast.p.rapidapi.com/wind/{city}"
57
+ querystring = {}
58
+
59
+ headers = {
60
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
61
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
62
+ }
63
+
64
+
65
+ response = requests.get(url, headers=headers, params=querystring)
66
+ try:
67
+ observation = response.json()
68
+ except:
69
+ observation = response.text
70
+ return observation
71
+
72
+ def get_current_weather(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
73
+ """
74
+ "Gets the current weather for the inputted city name"
75
+
76
+ """
77
+ url = f"https://cloud-cast.p.rapidapi.com/weather/{city}"
78
+ querystring = {}
79
+
80
+ headers = {
81
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
82
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
83
+ }
84
+
85
+
86
+ response = requests.get(url, headers=headers, params=querystring)
87
+ try:
88
+ observation = response.json()
89
+ except:
90
+ observation = response.text
91
+ return observation
92
+
93
+ def get_humidty(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
94
+ """
95
+ "Get the humidity for the current city"
96
+
97
+ """
98
+ url = f"https://cloud-cast.p.rapidapi.com/humidity/{city}"
99
+ querystring = {}
100
+
101
+ headers = {
102
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
103
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
104
+ }
105
+
106
+
107
+ response = requests.get(url, headers=headers, params=querystring)
108
+ try:
109
+ observation = response.json()
110
+ except:
111
+ observation = response.text
112
+ return observation
113
+
114
+ def get_city_info(city: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
115
+ """
116
+ "These endpoints allow you to retrieve weather and forecast data for specific cities without providing latitude and longitude."
117
+
118
+ """
119
+ url = f"https://cloud-cast.p.rapidapi.com/find-cities/{city}"
120
+ querystring = {}
121
+
122
+ headers = {
123
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
124
+ "X-RapidAPI-Host": "cloud-cast.p.rapidapi.com"
125
+ }
126
+
127
+
128
+ response = requests.get(url, headers=headers, params=querystring)
129
+ try:
130
+ observation = response.json()
131
+ except:
132
+ observation = response.text
133
+ return observation
134
+
toolbench/toolenv/tools/Weather/currencyconverter.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"CurrencyConverter",
3
+ "tool_description":"Test api",
4
+ "title":"CurrencyConverter",
5
+ "pricing":"FREE",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/tempmailfortesttt/api/currencyconverter4/",
8
+ "host":"currencyconverter4.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"weather",
12
+ "url":"https://currencyconverter4.p.rapidapi.comvk.com",
13
+ "description":"aaaaaaaa",
14
+ "method":"GET",
15
+ "required_parameters":[],
16
+ "optional_parameters":[],
17
+ "code":"import requests\n\nurl = \"https://currencyconverter4.p.rapidapi.comvk.com\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"currencyconverter4.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
18
+ "statuscode":111,
19
+ "body":"",
20
+ "headers":"",
21
+ "schema":""
22
+ }
23
+ ]
24
+ }
toolbench/toolenv/tools/Weather/currencyconverter/api.py ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def weather(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "aaaaaaaa"
12
+
13
+ """
14
+ url = f"https://currencyconverter4.p.rapidapi.comvk.com"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "currencyconverter4.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
toolbench/toolenv/tools/Weather/daily_limit_check.json ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"daily limit check",
3
+ "tool_description":"daily limit check",
4
+ "title":"daily limit check",
5
+ "pricing":"FREE",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/xeall-org-xeall-org-default/api/daily-limit-check/",
8
+ "host":"daily-limit-check.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"daily check",
12
+ "url":"https://daily-limit-check.p.rapidapi.com/daily",
13
+ "description":"daily limit check",
14
+ "method":"GET",
15
+ "required_parameters":[],
16
+ "optional_parameters":[
17
+ {
18
+ "name":"daily",
19
+ "type":"STRING",
20
+ "description":"",
21
+ "default":"daily"
22
+ }
23
+ ],
24
+ "code":"import requests\n\nurl = \"https://daily-limit-check.p.rapidapi.com/daily\"\nquerystring = {\"daily\": daily}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"daily-limit-check.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers, params=querystring)\n\nprint(response.json())\n",
25
+ "statuscode":111,
26
+ "body":"",
27
+ "headers":"",
28
+ "schema":""
29
+ }
30
+ ]
31
+ }
toolbench/toolenv/tools/Weather/daily_limit_check/api.py ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def daily_check(daily: str='daily', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "daily limit check"
12
+
13
+ """
14
+ url = f"https://daily-limit-check.p.rapidapi.com/daily"
15
+ querystring = {}
16
+ if daily:
17
+ querystring['daily'] = daily
18
+
19
+ headers = {
20
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
21
+ "X-RapidAPI-Host": "daily-limit-check.p.rapidapi.com"
22
+ }
23
+
24
+
25
+ response = requests.get(url, headers=headers, params=querystring)
26
+ try:
27
+ observation = response.json()
28
+ except:
29
+ observation = response.text
30
+ return observation
31
+
toolbench/toolenv/tools/Weather/dark_sky/api.py ADDED
@@ -0,0 +1,76 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def forecast(latitude: str, longitude: str, exclude: str=None, units: str='auto', extend: str=None, lang: str='en', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "A Forecast Request returns the current weather conditions, a minute-by-minute forecast for the next hour (where available), an hour-by-hour forecast for the next 48 hours, and a day-by-day forecast for the next week."
12
+ latitude: The latitude of a location (in decimal degrees). Positive is north, negative is south.
13
+ longitude: The longitude of a location (in decimal degrees). Positive is east, negative is west.
14
+ exclude: Exclude some number of data blocks from the API response. This is useful for reducing latency and saving cache space. The value blocks should be a comma-delimeted list (without spaces) of any of the following: currently, minutely, hourly, daily, alerts, flags
15
+ units: Return weather conditions in the requested units. [units] should be one of the following: auto: automatically select units based on geographic location ca: same as si, except that windSpeed and windGust are in kilometers per hour uk2: same as si, except that nearestStormDistance and visibility are in miles, and windSpeed and windGust in miles per hour us: Imperial units (the default) si: SI units
16
+ extend: When extend=hourly, return hour-by-hour data for the next 168 hours, instead of the next 48. When using this option, we strongly recommend enabling HTTP compression.
17
+ lang: Return summary properties in the desired language. (Note that units in the summary will be set according to the units parameter, so be sure to set both parameters appropriately.) language should be 2-letter language code. English is default
18
+
19
+ """
20
+ url = f"https://dark-sky.p.rapidapi.com/{latitude},{longitude}"
21
+ querystring = {}
22
+ if exclude:
23
+ querystring['exclude'] = exclude
24
+ if units:
25
+ querystring['units'] = units
26
+ if extend:
27
+ querystring['extend'] = extend
28
+ if lang:
29
+ querystring['lang'] = lang
30
+
31
+ headers = {
32
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
33
+ "X-RapidAPI-Host": "dark-sky.p.rapidapi.com"
34
+ }
35
+
36
+
37
+ response = requests.get(url, headers=headers, params=querystring)
38
+ try:
39
+ observation = response.json()
40
+ except:
41
+ observation = response.text
42
+ return observation
43
+
44
+ def time_machine(time: str, longitude: str, latitude: str, lang: str=None, exclude: str=None, units: str=None, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
45
+ """
46
+ "A Time Machine Request returns the observed (in the past) or forecasted (in the future) hour-by-hour weather and daily weather conditions for a particular date."
47
+ time: Either be a UNIX time (that is, seconds since midnight GMT on 1 Jan 1970) or a string formatted as follows: [YYYY]-[MM]-[DD]T[HH]:[MM]:[SS][timezone]. timezone should either be omitted (to refer to local time for the location being requested), Z (referring to GMT time), or +[HH][MM] or -[HH][MM] for an offset from GMT in hours and minutes. The timezone is only used for determining the time of the request; the response will always be relative to the local time zone.
48
+ longitude: The longitude of a location (in decimal degrees). Positive is east, negative is west.
49
+ latitude: The latitude of a location (in decimal degrees). Positive is north, negative is south.
50
+ lang: Return summary properties in the desired language. (Note that units in the summary will be set according to the units parameter, so be sure to set both parameters appropriately.) Use 2-letter language code (full list in API Details). en is default.
51
+ exclude: Exclude some number of data blocks from the API response. This is useful for reducing latency and saving cache space. The value blocks should be a comma-delimeted list (without spaces) of any of the following: currently, minutely, hourly, daily, alerts, flags
52
+ units: Return weather conditions in the requested units. [units] should be one of the following: auto: automatically select units based on geographic location ca: same as si, except that windSpeed is in kilometers per hour uk2: same as si, except that nearestStormDistance and visibility are in miles and windSpeed is in miles per hour us: Imperial units (the default) si: SI units
53
+
54
+ """
55
+ url = f"https://dark-sky.p.rapidapi.com/{latitude},{longitude},{time}"
56
+ querystring = {}
57
+ if lang:
58
+ querystring['lang'] = lang
59
+ if exclude:
60
+ querystring['exclude'] = exclude
61
+ if units:
62
+ querystring['units'] = units
63
+
64
+ headers = {
65
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
66
+ "X-RapidAPI-Host": "dark-sky.p.rapidapi.com"
67
+ }
68
+
69
+
70
+ response = requests.get(url, headers=headers, params=querystring)
71
+ try:
72
+ observation = response.json()
73
+ except:
74
+ observation = response.text
75
+ return observation
76
+
toolbench/toolenv/tools/Weather/darksky.json ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "product_id": "580",
3
+ "tool_description": "Weather forecasting and visualization.",
4
+ "home_url": "https://rapidapi.com/zakutynsky/api/Darksky/",
5
+ "name": "Darksky",
6
+ "title": "Darksky",
7
+ "pricing": "FREE",
8
+ "tool_name": "Darksky",
9
+ "score": null,
10
+ "host": "DarkskyzakutynskyV1.p.rapidapi.com",
11
+ "api_list": [
12
+ {
13
+ "name": "getForecastRequest",
14
+ "url": "https://DarkskyzakutynskyV1.p.rapidapi.com/getForecastRequest",
15
+ "description": "A Forecast Request returns the current weather conditions, a minute-by-minute forecast for the next hour (where available), an hour-by-hour forecast for the next 48 hours, and a day-by-day forecast for the next week.",
16
+ "method": "POST",
17
+ "required_parameters": [
18
+ {
19
+ "name": "apiKey",
20
+ "type": "CREDENTIALS",
21
+ "description": "Your Dark Sky secret key. (Your secret key must be kept secret; in particular, do not embed it in JavaScript source code that you transmit to clients.)",
22
+ "default": ""
23
+ },
24
+ {
25
+ "name": "coordinates",
26
+ "type": "MAP",
27
+ "description": "Location",
28
+ "default": ""
29
+ }
30
+ ],
31
+ "optional_parameters": [
32
+ {
33
+ "name": "units",
34
+ "type": "SELECT",
35
+ "description": "Return weather conditions in the requested units. [units] should be one of the following: auto, ca, uk2, us, si",
36
+ "default": ""
37
+ },
38
+ {
39
+ "name": "hourly",
40
+ "type": "BOOLEAN",
41
+ "description": "When present, return hour-by-hour data for the next 168 hours, instead of the next 48.",
42
+ "default": ""
43
+ },
44
+ {
45
+ "name": "lang",
46
+ "type": "STRING",
47
+ "description": "Return summary properties in the desired language. (Note that units in the summary will be set according to the units parameter, so be sure to set both parameters appropriately.). See at https://darksky.net/dev/docs/forecast for details",
48
+ "default": ""
49
+ },
50
+ {
51
+ "name": "exclude",
52
+ "type": "LIST",
53
+ "description": "Exclude some number of data blocks from the API response. This is useful for reducing latency and saving cache space. The value blocks should be a comma-delimeted list (without spaces) of any of the following: currently, minutely, hourly, daily, alerts, flags",
54
+ "default": ""
55
+ }
56
+ ],
57
+ "code": "import requests\n\nurl = \"https://DarkskyzakutynskyV1.p.rapidapi.com/getForecastRequest\"\nquerystring = {\"apiKey\": \"\", \"coordinates\": \"\", \"units\": \"\", \"hourly\": \"\", \"lang\": \"\", \"exclude\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"DarkskyzakutynskyV1.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
58
+ "convert_code": "import requests\n\nurl = \"https://DarkskyzakutynskyV1.p.rapidapi.com/getForecastRequest\"\nquerystring = {\"apiKey\": \"\", \"coordinates\": \"\", \"units\": \"\", \"hourly\": \"\", \"lang\": \"\", \"exclude\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"DarkskyzakutynskyV1.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
59
+ "test_endpoint": ""
60
+ },
61
+ {
62
+ "name": "getTimeMachineRequest",
63
+ "url": "https://DarkskyzakutynskyV1.p.rapidapi.com/getTimeMachineRequest",
64
+ "description": "A Time Machine Request returns the observed (in the past) or forecasted (in the future) hour-by-hour weather and daily weather conditions for a particular date.",
65
+ "method": "POST",
66
+ "required_parameters": [
67
+ {
68
+ "name": "apiKey",
69
+ "type": "CREDENTIALS",
70
+ "description": "Your Dark Sky secret key. (Your secret key must be kept secret; in particular, do not embed it in JavaScript source code that you transmit to clients.)",
71
+ "default": ""
72
+ },
73
+ {
74
+ "name": "time",
75
+ "type": "DATEPICKER",
76
+ "description": "A Time Machine Request returns the observed (in the past) or forecasted (in the future) hour-by-hour weather and daily weather conditions for a particular date",
77
+ "default": ""
78
+ },
79
+ {
80
+ "name": "coordinates",
81
+ "type": "MAP",
82
+ "description": "Location",
83
+ "default": ""
84
+ }
85
+ ],
86
+ "optional_parameters": [
87
+ {
88
+ "name": "units",
89
+ "type": "SELECT",
90
+ "description": "Return weather conditions in the requested units. [units] should be one of the following: auto, ca, uk2, us, si",
91
+ "default": ""
92
+ },
93
+ {
94
+ "name": "hourly",
95
+ "type": "BOOLEAN",
96
+ "description": "When present, return hour-by-hour data for the next 168 hours, instead of the next 48.",
97
+ "default": ""
98
+ },
99
+ {
100
+ "name": "lang",
101
+ "type": "STRING",
102
+ "description": "Return summary properties in the desired language. (Note that units in the summary will be set according to the units parameter, so be sure to set both parameters appropriately.). See at https://darksky.net/dev/docs/forecast for details",
103
+ "default": ""
104
+ },
105
+ {
106
+ "name": "exclude",
107
+ "type": "LIST",
108
+ "description": "Exclude some number of data blocks from the API response. This is useful for reducing latency and saving cache space. Any of the following: currently, minutely, hourly, daily, alerts, flags",
109
+ "default": ""
110
+ }
111
+ ],
112
+ "code": "import requests\n\nurl = \"https://DarkskyzakutynskyV1.p.rapidapi.com/getTimeMachineRequest\"\nquerystring = {\"apiKey\": \"\", \"time\": \"\", \"coordinates\": \"\", \"units\": \"\", \"hourly\": \"\", \"lang\": \"\", \"exclude\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"DarkskyzakutynskyV1.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
113
+ "convert_code": "import requests\n\nurl = \"https://DarkskyzakutynskyV1.p.rapidapi.com/getTimeMachineRequest\"\nquerystring = {\"apiKey\": \"\", \"time\": \"\", \"coordinates\": \"\", \"units\": \"\", \"hourly\": \"\", \"lang\": \"\", \"exclude\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"DarkskyzakutynskyV1.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
114
+ "test_endpoint": ""
115
+ }
116
+ ]
117
+ }
toolbench/toolenv/tools/Weather/demo_project.json ADDED
@@ -0,0 +1,105 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "product_id": "api_469a13bf-6acd-4c07-a76c-1c61841fc380",
3
+ "tool_description": "This Project is created by the onboarding process",
4
+ "home_url": "https://rapidapi.com/arunmechanic03/api/demo-project50057/",
5
+ "name": "\ud83d\udc4b Demo Project",
6
+ "title": "\ud83d\udc4b Demo Project",
7
+ "pricing": "FREE",
8
+ "tool_name": "\ud83d\udc4b Demo Project",
9
+ "score": null,
10
+ "host": "demo-project50057.p.rapidapi.com",
11
+ "api_list": [
12
+ {
13
+ "name": "Login",
14
+ "url": "https://demo-project50057.p.rapidapi.com/auth/login",
15
+ "description": " ",
16
+ "method": "POST",
17
+ "required_parameters": [],
18
+ "optional_parameters": [],
19
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/auth/login\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
20
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/auth/login\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
21
+ "test_endpoint": "",
22
+ "statuscode": 1,
23
+ "schema": ""
24
+ },
25
+ {
26
+ "name": "Create User (Sign Up)",
27
+ "url": "https://demo-project50057.p.rapidapi.com/auth/user",
28
+ "description": " ",
29
+ "method": "POST",
30
+ "required_parameters": [],
31
+ "optional_parameters": [],
32
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/auth/user\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
33
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/auth/user\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
34
+ "test_endpoint": "",
35
+ "statuscode": 1,
36
+ "schema": ""
37
+ },
38
+ {
39
+ "name": "Place Order",
40
+ "url": "https://demo-project50057.p.rapidapi.com/order/{id}/place",
41
+ "description": " ",
42
+ "method": "POST",
43
+ "required_parameters": [
44
+ {
45
+ "name": "id",
46
+ "type": "STRING",
47
+ "description": "",
48
+ "default": ""
49
+ }
50
+ ],
51
+ "optional_parameters": [],
52
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/{id}/place\"\nquerystring = {\"id\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
53
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/{id}/place\"\nquerystring = {\"id\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
54
+ "test_endpoint": "",
55
+ "statuscode": 1,
56
+ "schema": ""
57
+ },
58
+ {
59
+ "name": "Create Order",
60
+ "url": "https://demo-project50057.p.rapidapi.com/order/new",
61
+ "description": " ",
62
+ "method": "POST",
63
+ "required_parameters": [],
64
+ "optional_parameters": [],
65
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/new\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
66
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/new\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
67
+ "test_endpoint": "",
68
+ "statuscode": 1,
69
+ "schema": ""
70
+ },
71
+ {
72
+ "name": "Add to Order",
73
+ "url": "https://demo-project50057.p.rapidapi.com/order/{id}/product",
74
+ "description": " ",
75
+ "method": "POST",
76
+ "required_parameters": [
77
+ {
78
+ "name": "id",
79
+ "type": "STRING",
80
+ "description": "",
81
+ "default": ""
82
+ }
83
+ ],
84
+ "optional_parameters": [],
85
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/{id}/product\"\nquerystring = {\"id\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
86
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/order/{id}/product\"\nquerystring = {\"id\": \"\"}\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers, params=querystring)\nprint(response.json())\n",
87
+ "test_endpoint": "",
88
+ "statuscode": 1,
89
+ "schema": ""
90
+ },
91
+ {
92
+ "name": "Create Product",
93
+ "url": "https://demo-project50057.p.rapidapi.com/catalog/product",
94
+ "description": " ",
95
+ "method": "POST",
96
+ "required_parameters": [],
97
+ "optional_parameters": [],
98
+ "code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/catalog/product\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
99
+ "convert_code": "import requests\n\nurl = \"https://demo-project50057.p.rapidapi.com/catalog/product\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"demo-project50057.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
100
+ "test_endpoint": "",
101
+ "statuscode": 1,
102
+ "schema": ""
103
+ }
104
+ ]
105
+ }
toolbench/toolenv/tools/Weather/dz_meteo_live.json ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Dz Meteo Live",
3
+ "tool_description":"API showing weather in all wilayas of Algeria Live and for free",
4
+ "title":"Dz Meteo Live",
5
+ "pricing":"FREE",
6
+ "score":{
7
+ "avgServiceLevel":0,
8
+ "avgLatency":118,
9
+ "avgSuccessRate":0,
10
+ "popularityScore":0,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/07aking-s8yn0fdi2-w/api/dz-meteo-live/",
14
+ "host":"dz-meteo-live.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Index Wilaya",
18
+ "url":"https://dz-meteo-live.p.rapidapi.com/wilaya/{id}",
19
+ "description":"Get Weather in specific wilaya with index wilaya\nfor ex /wilaya/16 \nthis end point is for Wilaya Alger\nfor ex /wilaya/38\nthis endpoint is for Wilaya Tissemsilt",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"id",
24
+ "type":"string",
25
+ "description":"",
26
+ "default":"1"
27
+ }
28
+ ],
29
+ "optional_parameters":[],
30
+ "code":"import requests\n\nurl = \"https://dz-meteo-live.p.rapidapi.com/wilaya/{id}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"dz-meteo-live.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
31
+ "statuscode":111,
32
+ "body":"",
33
+ "headers":"",
34
+ "schema":""
35
+ },
36
+ {
37
+ "name":"All wilayas",
38
+ "url":"https://dz-meteo-live.p.rapidapi.com/allwilayas",
39
+ "description":"This endpoint will return back all wilayas weather,\nwith: \nindex_wilaya\nname\ntemp\nstatue\nimg",
40
+ "method":"GET",
41
+ "required_parameters":[],
42
+ "optional_parameters":[],
43
+ "code":"import requests\n\nurl = \"https://dz-meteo-live.p.rapidapi.com/allwilayas\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"dz-meteo-live.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
44
+ "statuscode":111,
45
+ "body":"",
46
+ "headers":"",
47
+ "schema":""
48
+ }
49
+ ]
50
+ }
toolbench/toolenv/tools/Weather/dz_meteo_live/api.py ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def index_wilaya(is_id: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get Weather in specific wilaya with index wilaya
12
+ for ex /wilaya/16
13
+ this end point is for Wilaya Alger
14
+ for ex /wilaya/38
15
+ this endpoint is for Wilaya Tissemsilt"
16
+
17
+ """
18
+ url = f"https://dz-meteo-live.p.rapidapi.com/wilaya/{is_id}"
19
+ querystring = {}
20
+
21
+ headers = {
22
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
23
+ "X-RapidAPI-Host": "dz-meteo-live.p.rapidapi.com"
24
+ }
25
+
26
+
27
+ response = requests.get(url, headers=headers, params=querystring)
28
+ try:
29
+ observation = response.json()
30
+ except:
31
+ observation = response.text
32
+ return observation
33
+
34
+ def all_wilayas(toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
35
+ """
36
+ "This endpoint will return back all wilayas weather,
37
+ with:
38
+ index_wilaya
39
+ name
40
+ temp
41
+ statue
42
+ img"
43
+
44
+ """
45
+ url = f"https://dz-meteo-live.p.rapidapi.com/allwilayas"
46
+ querystring = {}
47
+
48
+ headers = {
49
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
50
+ "X-RapidAPI-Host": "dz-meteo-live.p.rapidapi.com"
51
+ }
52
+
53
+
54
+ response = requests.get(url, headers=headers, params=querystring)
55
+ try:
56
+ observation = response.json()
57
+ except:
58
+ observation = response.text
59
+ return observation
60
+
toolbench/toolenv/tools/Weather/easy_air_quality.json ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Easy Air Quality",
3
+ "tool_description":"Easy Air Quality",
4
+ "title":"Easy Air Quality",
5
+ "pricing":"FREEMIUM",
6
+ "score":{
7
+ "avgServiceLevel":100,
8
+ "avgLatency":434,
9
+ "avgSuccessRate":99,
10
+ "popularityScore":9.1,
11
+ "__typename":"Score"
12
+ },
13
+ "home_url":"https://rapidapi.com/21zoo/api/easy-air-quality/",
14
+ "host":"easy-air-quality.p.rapidapi.com",
15
+ "api_list":[
16
+ {
17
+ "name":"Get Current Air Quality",
18
+ "url":"https://easy-air-quality.p.rapidapi.com/api/v1/air-quality/{zip}/current",
19
+ "description":"Get Current Air Quality for a given zip code (e.g. 10011)",
20
+ "method":"GET",
21
+ "required_parameters":[
22
+ {
23
+ "name":"zip",
24
+ "type":"string",
25
+ "description":"",
26
+ "default":"10011"
27
+ }
28
+ ],
29
+ "optional_parameters":[],
30
+ "code":"import requests\n\nurl = \"https://easy-air-quality.p.rapidapi.com/api/v1/air-quality/{zip}/current\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"easy-air-quality.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
31
+ "statuscode":111,
32
+ "body":"",
33
+ "headers":"",
34
+ "schema":""
35
+ }
36
+ ]
37
+ }
toolbench/toolenv/tools/Weather/easy_air_quality/api.py ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def get_current_air_quality(zip: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get Current Air Quality for a given zip code (e.g. 10011)"
12
+
13
+ """
14
+ url = f"https://easy-air-quality.p.rapidapi.com/api/v1/air-quality/{zip}/current"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "easy-air-quality.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
toolbench/toolenv/tools/Weather/easy_weather.json ADDED
The diff for this file is too large to render. See raw diff
 
toolbench/toolenv/tools/Weather/easy_weather/api.py ADDED
@@ -0,0 +1,220 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def daily_forecast_5_days(longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Get a 5-day daily forecast for the given latitude and longitude."
12
+
13
+ """
14
+ url = f"https://easy-weather1.p.rapidapi.com/daily/5"
15
+ querystring = {'longitude': longitude, 'latitude': latitude, }
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def hourly_forecast_240_hours(longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Get a 240-hour forecast for the given latitude and longitude."
33
+
34
+ """
35
+ url = f"https://easy-weather1.p.rapidapi.com/hourly/full"
36
+ querystring = {'longitude': longitude, 'latitude': latitude, }
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
51
+ def hourly_forecast_48_hours(latitude: str, longitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
52
+ """
53
+ "Get a 48-hour forecast for the given latitude and longitude."
54
+
55
+ """
56
+ url = f"https://easy-weather1.p.rapidapi.com/hourly/48"
57
+ querystring = {'latitude': latitude, 'longitude': longitude, }
58
+
59
+ headers = {
60
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
61
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
62
+ }
63
+
64
+
65
+ response = requests.get(url, headers=headers, params=querystring)
66
+ try:
67
+ observation = response.json()
68
+ except:
69
+ observation = response.text
70
+ return observation
71
+
72
+ def historical_daily(longitude: str, date: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
73
+ """
74
+ "Get a historical daily forecast for the given latitude, longitude, and start date/time."
75
+
76
+ """
77
+ url = f"https://easy-weather1.p.rapidapi.com/historical/daily"
78
+ querystring = {'longitude': longitude, 'date': date, 'latitude': latitude, }
79
+
80
+ headers = {
81
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
82
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
83
+ }
84
+
85
+
86
+ response = requests.get(url, headers=headers, params=querystring)
87
+ try:
88
+ observation = response.json()
89
+ except:
90
+ observation = response.text
91
+ return observation
92
+
93
+ def historical_hourly(longitude: str, date: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
94
+ """
95
+ "Get a historical hourly forecast for the given latitude, longitude, and start date/time."
96
+
97
+ """
98
+ url = f"https://easy-weather1.p.rapidapi.com/historical/hourly"
99
+ querystring = {'longitude': longitude, 'date': date, 'latitude': latitude, }
100
+
101
+ headers = {
102
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
103
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
104
+ }
105
+
106
+
107
+ response = requests.get(url, headers=headers, params=querystring)
108
+ try:
109
+ observation = response.json()
110
+ except:
111
+ observation = response.text
112
+ return observation
113
+
114
+ def daily_forecast_10_days(longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
115
+ """
116
+ "Get a 10-day daily forecast for the given latitude and longitude."
117
+
118
+ """
119
+ url = f"https://easy-weather1.p.rapidapi.com/daily/full"
120
+ querystring = {'longitude': longitude, 'latitude': latitude, }
121
+
122
+ headers = {
123
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
124
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
125
+ }
126
+
127
+
128
+ response = requests.get(url, headers=headers, params=querystring)
129
+ try:
130
+ observation = response.json()
131
+ except:
132
+ observation = response.text
133
+ return observation
134
+
135
+ def current_conditions_basic(longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
136
+ """
137
+ "Get (basic) current conditions for the given latitude and longitude."
138
+
139
+ """
140
+ url = f"https://easy-weather1.p.rapidapi.com/current/basic"
141
+ querystring = {'longitude': longitude, 'latitude': latitude, }
142
+
143
+ headers = {
144
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
145
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
146
+ }
147
+
148
+
149
+ response = requests.get(url, headers=headers, params=querystring)
150
+ try:
151
+ observation = response.json()
152
+ except:
153
+ observation = response.text
154
+ return observation
155
+
156
+ def complete_weather_single_call(longitude: str, latitude: str, country: str='US', toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
157
+ """
158
+ "Get current conditions, hourly forecast, daily forecast, and alerts in a single response for the given latitude and longitude (you must supply ISO country code to receive weather alerts)."
159
+
160
+ """
161
+ url = f"https://easy-weather1.p.rapidapi.com/all/full"
162
+ querystring = {'longitude': longitude, 'latitude': latitude, }
163
+ if country:
164
+ querystring['country'] = country
165
+
166
+ headers = {
167
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
168
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
169
+ }
170
+
171
+
172
+ response = requests.get(url, headers=headers, params=querystring)
173
+ try:
174
+ observation = response.json()
175
+ except:
176
+ observation = response.text
177
+ return observation
178
+
179
+ def current_conditions_detailed(longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
180
+ """
181
+ "Get (detailed) current conditions for the given latitude and longitude."
182
+
183
+ """
184
+ url = f"https://easy-weather1.p.rapidapi.com/current/detail"
185
+ querystring = {'longitude': longitude, 'latitude': latitude, }
186
+
187
+ headers = {
188
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
189
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
190
+ }
191
+
192
+
193
+ response = requests.get(url, headers=headers, params=querystring)
194
+ try:
195
+ observation = response.json()
196
+ except:
197
+ observation = response.text
198
+ return observation
199
+
200
+ def weather_alerts(country: str, longitude: str, latitude: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
201
+ """
202
+ "Get weather alerts posted by the local meteorological agency for the given latitude and longitude."
203
+
204
+ """
205
+ url = f"https://easy-weather1.p.rapidapi.com/alerts/full"
206
+ querystring = {'country': country, 'longitude': longitude, 'latitude': latitude, }
207
+
208
+ headers = {
209
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
210
+ "X-RapidAPI-Host": "easy-weather1.p.rapidapi.com"
211
+ }
212
+
213
+
214
+ response = requests.get(url, headers=headers, params=querystring)
215
+ try:
216
+ observation = response.json()
217
+ except:
218
+ observation = response.text
219
+ return observation
220
+
toolbench/toolenv/tools/Weather/evilbudz_net.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "product_id": "api_e3dac344-203f-4e15-a3ab-165492bc389e",
3
+ "tool_description": "evilbudz.net weather info updates",
4
+ "home_url": "https://rapidapi.com/timjames201/api/evilbudz-net/",
5
+ "name": "evilbudz-net",
6
+ "title": "evilbudz-net",
7
+ "pricing": "FREE",
8
+ "tool_name": "evilbudz-net",
9
+ "score": null,
10
+ "host": "evilbudz-net.p.rapidapi.com",
11
+ "api_list": [
12
+ {
13
+ "name": "evilbudz.net",
14
+ "url": "https://evilbudz-net.p.rapidapi.com/",
15
+ "description": "weather info updates",
16
+ "method": "POST",
17
+ "required_parameters": [],
18
+ "optional_parameters": [],
19
+ "code": "import requests\n\nurl = \"https://evilbudz-net.p.rapidapi.com/\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"evilbudz-net.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
20
+ "convert_code": "import requests\n\nurl = \"https://evilbudz-net.p.rapidapi.com/\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"evilbudz-net.p.rapidapi.com\"\n }\n\nresponse = requests.post(url, headers=headers)\nprint(response.json())\n",
21
+ "test_endpoint": ""
22
+ }
23
+ ]
24
+ }
toolbench/toolenv/tools/Weather/excarta_apis.json ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Excarta APIs",
3
+ "tool_description":"Hyper-Accurate AI-Driven Weather Forecasts",
4
+ "title":"Excarta APIs",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/excarta-apis/api/excarta-apis/",
8
+ "host":"excarta-apis.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"Forecast Server - All parameters",
12
+ "url":"https://excarta-apis.p.rapidapi.com/{latitude}/{longitude}",
13
+ "description":"Fetch forecasts for a desired location for all parameters by specifying latitude, longitude, and desired timestamps.",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"longitude",
18
+ "type":"NUMBER",
19
+ "description":"",
20
+ "default":"-122.2913"
21
+ },
22
+ {
23
+ "name":"latitude",
24
+ "type":"NUMBER",
25
+ "description":"",
26
+ "default":"37.8272"
27
+ }
28
+ ],
29
+ "optional_parameters":[],
30
+ "code":"import requests\n\nurl = \"https://excarta-apis.p.rapidapi.com/{latitude}/{longitude}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"excarta-apis.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
31
+ "statuscode":111,
32
+ "body":"",
33
+ "headers":"",
34
+ "schema":""
35
+ },
36
+ {
37
+ "name":"Forecast Server",
38
+ "url":"https://excarta-apis.p.rapidapi.com/{param}/{latitude}/{longitude}",
39
+ "description":"Fetch forecasts for a desired location by specifying latitude, longitude, parameter, and desired timestamps.",
40
+ "method":"GET",
41
+ "required_parameters":[
42
+ {
43
+ "name":"longitude",
44
+ "type":"NUMBER",
45
+ "description":"",
46
+ "default":"-122.2913"
47
+ },
48
+ {
49
+ "name":"latitude",
50
+ "type":"NUMBER",
51
+ "description":"",
52
+ "default":"37.8272"
53
+ },
54
+ {
55
+ "name":"param",
56
+ "type":"string",
57
+ "description":"",
58
+ "default":"t2m"
59
+ }
60
+ ],
61
+ "optional_parameters":[],
62
+ "code":"import requests\n\nurl = \"https://excarta-apis.p.rapidapi.com/{param}/{latitude}/{longitude}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"excarta-apis.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
63
+ "statuscode":111,
64
+ "body":"",
65
+ "headers":"",
66
+ "schema":""
67
+ }
68
+ ]
69
+ }
toolbench/toolenv/tools/Weather/excarta_apis/api.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def forecast_server_all_parameters(longitude: int, latitude: int, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Fetch forecasts for a desired location for all parameters by specifying latitude, longitude, and desired timestamps."
12
+
13
+ """
14
+ url = f"https://excarta-apis.p.rapidapi.com/{latitude}/{longitude}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "excarta-apis.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def forecast_server(longitude: int, latitude: int, param: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Fetch forecasts for a desired location by specifying latitude, longitude, parameter, and desired timestamps."
33
+
34
+ """
35
+ url = f"https://excarta-apis.p.rapidapi.com/{param}/{latitude}/{longitude}"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "excarta-apis.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
toolbench/toolenv/tools/Weather/fliteintel.json ADDED
@@ -0,0 +1,211 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"fliteINTEL",
3
+ "tool_description":"Providing latest weather information - METAR, TAF, DATIS and RVR and Airport Configuration Information - Arrival Airport Configuration (AAC), Airport Acceptance Rate (AAR), Tracon Acceptance Rate (TAR), Runway Acceptance Rate (RAR) for the aviation industry!",
4
+ "title":"fliteINTEL",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/flitex-flitex-default/api/fliteintel1/",
8
+ "host":"fliteintel1.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"Latest TRACON Acceptance Rate (TAR) for major US TRACONs",
12
+ "url":"https://fliteintel1.p.rapidapi.com/v1/metering/tar/tracon/{tra}",
13
+ "description":"Provides the latest TRACON Acceptance Rate (TAR) available for major US Terminal Radar Approach Controls (TRACON). Please Enter the 3 letter TRACON code for your airport.",
14
+ "method":"GET",
15
+ "required_parameters":[
16
+ {
17
+ "name":"tra",
18
+ "type":"string",
19
+ "description":"",
20
+ "default":"C90"
21
+ }
22
+ ],
23
+ "optional_parameters":[],
24
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/metering/tar/tracon/{tra}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
25
+ "statuscode":111,
26
+ "body":"",
27
+ "headers":"",
28
+ "schema":""
29
+ },
30
+ {
31
+ "name":"Latest Runway Acceptance Rate (RAR) for major US airports",
32
+ "url":"https://fliteintel1.p.rapidapi.com/v1/metering/rar/airport/{location}",
33
+ "description":"Provides the latest Runway Acceptance Rate (RAR) available for major US airports. Please Enter the 3 letter domestic location code for your airport.",
34
+ "method":"GET",
35
+ "required_parameters":[
36
+ {
37
+ "name":"location",
38
+ "type":"string",
39
+ "description":"",
40
+ "default":"LAX"
41
+ }
42
+ ],
43
+ "optional_parameters":[],
44
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/metering/rar/airport/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
45
+ "statuscode":111,
46
+ "body":"",
47
+ "headers":"",
48
+ "schema":""
49
+ },
50
+ {
51
+ "name":"Latest Airport Acceptance Rate (AAR) for major US airports",
52
+ "url":"https://fliteintel1.p.rapidapi.com/v1/metering/aar/airport/{location}",
53
+ "description":"Provides the latest Airport Acceptance Rate (AAR) available for major US airports. Please Enter the 3 letter domestic location code for your airport.",
54
+ "method":"GET",
55
+ "required_parameters":[
56
+ {
57
+ "name":"location",
58
+ "type":"string",
59
+ "description":"",
60
+ "default":"JFK"
61
+ }
62
+ ],
63
+ "optional_parameters":[],
64
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/metering/aar/airport/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
65
+ "statuscode":111,
66
+ "body":"",
67
+ "headers":"",
68
+ "schema":""
69
+ },
70
+ {
71
+ "name":"Latest Arrival Airport Configuration (AAC) for major US airports",
72
+ "url":"https://fliteintel1.p.rapidapi.com/v1/metering/aac/airport/{location}",
73
+ "description":"Provides the latest Arrival Airport Configuration (AAC) available for major US airports. Please Enter the 3 letter domestic location code for your airport.",
74
+ "method":"GET",
75
+ "required_parameters":[
76
+ {
77
+ "name":"location",
78
+ "type":"string",
79
+ "description":"",
80
+ "default":"FLL"
81
+ }
82
+ ],
83
+ "optional_parameters":[],
84
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/metering/aac/airport/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
85
+ "statuscode":111,
86
+ "body":"",
87
+ "headers":"",
88
+ "schema":""
89
+ },
90
+ {
91
+ "name":"Latest TAF for all US Airports",
92
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/taf/us/iwxxm/items/{location}",
93
+ "description":"Provides latest TAF for the US airport of your choice in iWXXM format - please enter your airport's ICAO code as parameter.",
94
+ "method":"GET",
95
+ "required_parameters":[
96
+ {
97
+ "name":"location",
98
+ "type":"string",
99
+ "description":"",
100
+ "default":"KJFK"
101
+ }
102
+ ],
103
+ "optional_parameters":[],
104
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/taf/us/iwxxm/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
105
+ "statuscode":111,
106
+ "body":"",
107
+ "headers":"",
108
+ "schema":""
109
+ },
110
+ {
111
+ "name":"Latest Metar for all US Airports",
112
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/metar/us/iwxxm/items/{location}",
113
+ "description":"Provides the latest available METAR information for your chosen airport in iWXXM format - pass the ICAO code of the US airport as the parameter to receive the information",
114
+ "method":"GET",
115
+ "required_parameters":[
116
+ {
117
+ "name":"location",
118
+ "type":"string",
119
+ "description":"",
120
+ "default":"KJFK"
121
+ }
122
+ ],
123
+ "optional_parameters":[],
124
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/metar/us/iwxxm/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
125
+ "statuscode":111,
126
+ "body":"",
127
+ "headers":"",
128
+ "schema":""
129
+ },
130
+ {
131
+ "name":"Latest RVR for your Airport",
132
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/rvr/us/items/{location}",
133
+ "description":"Get the latest RVR information available for all runways of your airport - please input your chosen airport's ICAO code as parameter",
134
+ "method":"GET",
135
+ "required_parameters":[
136
+ {
137
+ "name":"location",
138
+ "type":"string",
139
+ "description":"",
140
+ "default":"KJFK"
141
+ }
142
+ ],
143
+ "optional_parameters":[],
144
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/rvr/us/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
145
+ "statuscode":111,
146
+ "body":"",
147
+ "headers":"",
148
+ "schema":""
149
+ },
150
+ {
151
+ "name":"Latest Datis for your Airport",
152
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/datis/us/items/{location}",
153
+ "description":"Get the latest Datis information available for your airport - please input your chosen airport's ICAO code as parameter",
154
+ "method":"GET",
155
+ "required_parameters":[
156
+ {
157
+ "name":"location",
158
+ "type":"string",
159
+ "description":"",
160
+ "default":"KJFK"
161
+ }
162
+ ],
163
+ "optional_parameters":[],
164
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/datis/us/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
165
+ "statuscode":111,
166
+ "body":"",
167
+ "headers":"",
168
+ "schema":""
169
+ },
170
+ {
171
+ "name":"Latest METAR in TAC format for your Airport all over the world",
172
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/metar/global/tac/items/{location}",
173
+ "description":"Provides latest METAR for the airports all over the world in TAC format - please enter your airport's ICAO code as parameter.",
174
+ "method":"GET",
175
+ "required_parameters":[
176
+ {
177
+ "name":"location",
178
+ "type":"string",
179
+ "description":"",
180
+ "default":"CYYZ"
181
+ }
182
+ ],
183
+ "optional_parameters":[],
184
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/metar/global/tac/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
185
+ "statuscode":111,
186
+ "body":"",
187
+ "headers":"",
188
+ "schema":""
189
+ },
190
+ {
191
+ "name":"Latest TAF in TAC format for your Airport all over the world",
192
+ "url":"https://fliteintel1.p.rapidapi.com/v1/weather/taf/global/tac/items/{location}",
193
+ "description":"Provides latest TAF for the airports all over the world in TAC format - please enter your airport's ICAO code as parameter.",
194
+ "method":"GET",
195
+ "required_parameters":[
196
+ {
197
+ "name":"location",
198
+ "type":"string",
199
+ "description":"",
200
+ "default":"CYYZ"
201
+ }
202
+ ],
203
+ "optional_parameters":[],
204
+ "code":"import requests\n\nurl = \"https://fliteintel1.p.rapidapi.com/v1/weather/taf/global/tac/items/{location}\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"fliteintel1.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
205
+ "statuscode":111,
206
+ "body":"",
207
+ "headers":"",
208
+ "schema":""
209
+ }
210
+ ]
211
+ }
toolbench/toolenv/tools/Weather/fliteintel/api.py ADDED
@@ -0,0 +1,218 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import requests
2
+ import json
3
+ from datetime import date, datetime, timedelta
4
+ import os
5
+
6
+ from typing import Optional, Dict, Union, List
7
+
8
+
9
+ def latest_tracon_acceptance_rate_tar_for_major_us_tracons(tra: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
10
+ """
11
+ "Provides the latest TRACON Acceptance Rate (TAR) available for major US Terminal Radar Approach Controls (TRACON). Please Enter the 3 letter TRACON code for your airport."
12
+
13
+ """
14
+ url = f"https://fliteintel1.p.rapidapi.com/v1/metering/tar/tracon/{tra}"
15
+ querystring = {}
16
+
17
+ headers = {
18
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
19
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
20
+ }
21
+
22
+
23
+ response = requests.get(url, headers=headers, params=querystring)
24
+ try:
25
+ observation = response.json()
26
+ except:
27
+ observation = response.text
28
+ return observation
29
+
30
+ def latest_runway_acceptance_rate_rar_for_major_us_airports(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
31
+ """
32
+ "Provides the latest Runway Acceptance Rate (RAR) available for major US airports. Please Enter the 3 letter domestic location code for your airport."
33
+
34
+ """
35
+ url = f"https://fliteintel1.p.rapidapi.com/v1/metering/rar/airport/{location}"
36
+ querystring = {}
37
+
38
+ headers = {
39
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
40
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
41
+ }
42
+
43
+
44
+ response = requests.get(url, headers=headers, params=querystring)
45
+ try:
46
+ observation = response.json()
47
+ except:
48
+ observation = response.text
49
+ return observation
50
+
51
+ def latest_airport_acceptance_rate_aar_for_major_us_airports(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
52
+ """
53
+ "Provides the latest Airport Acceptance Rate (AAR) available for major US airports. Please Enter the 3 letter domestic location code for your airport."
54
+
55
+ """
56
+ url = f"https://fliteintel1.p.rapidapi.com/v1/metering/aar/airport/{location}"
57
+ querystring = {}
58
+
59
+ headers = {
60
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
61
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
62
+ }
63
+
64
+
65
+ response = requests.get(url, headers=headers, params=querystring)
66
+ try:
67
+ observation = response.json()
68
+ except:
69
+ observation = response.text
70
+ return observation
71
+
72
+ def latest_arrival_airport_configuration_aac_for_major_us_airports(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
73
+ """
74
+ "Provides the latest Arrival Airport Configuration (AAC) available for major US airports. Please Enter the 3 letter domestic location code for your airport."
75
+
76
+ """
77
+ url = f"https://fliteintel1.p.rapidapi.com/v1/metering/aac/airport/{location}"
78
+ querystring = {}
79
+
80
+ headers = {
81
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
82
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
83
+ }
84
+
85
+
86
+ response = requests.get(url, headers=headers, params=querystring)
87
+ try:
88
+ observation = response.json()
89
+ except:
90
+ observation = response.text
91
+ return observation
92
+
93
+ def latest_taf_for_all_us_airports(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
94
+ """
95
+ "Provides latest TAF for the US airport of your choice in iWXXM format - please enter your airport's ICAO code as parameter."
96
+
97
+ """
98
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/taf/us/iwxxm/items/{location}"
99
+ querystring = {}
100
+
101
+ headers = {
102
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
103
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
104
+ }
105
+
106
+
107
+ response = requests.get(url, headers=headers, params=querystring)
108
+ try:
109
+ observation = response.json()
110
+ except:
111
+ observation = response.text
112
+ return observation
113
+
114
+ def latest_metar_for_all_us_airports(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
115
+ """
116
+ "Provides the latest available METAR information for your chosen airport in iWXXM format - pass the ICAO code of the US airport as the parameter to receive the information"
117
+
118
+ """
119
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/metar/us/iwxxm/items/{location}"
120
+ querystring = {}
121
+
122
+ headers = {
123
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
124
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
125
+ }
126
+
127
+
128
+ response = requests.get(url, headers=headers, params=querystring)
129
+ try:
130
+ observation = response.json()
131
+ except:
132
+ observation = response.text
133
+ return observation
134
+
135
+ def latest_rvr_for_your_airport(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
136
+ """
137
+ "Get the latest RVR information available for all runways of your airport - please input your chosen airport's ICAO code as parameter"
138
+
139
+ """
140
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/rvr/us/items/{location}"
141
+ querystring = {}
142
+
143
+ headers = {
144
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
145
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
146
+ }
147
+
148
+
149
+ response = requests.get(url, headers=headers, params=querystring)
150
+ try:
151
+ observation = response.json()
152
+ except:
153
+ observation = response.text
154
+ return observation
155
+
156
+ def latest_datis_for_your_airport(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
157
+ """
158
+ "Get the latest Datis information available for your airport - please input your chosen airport's ICAO code as parameter"
159
+
160
+ """
161
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/datis/us/items/{location}"
162
+ querystring = {}
163
+
164
+ headers = {
165
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
166
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
167
+ }
168
+
169
+
170
+ response = requests.get(url, headers=headers, params=querystring)
171
+ try:
172
+ observation = response.json()
173
+ except:
174
+ observation = response.text
175
+ return observation
176
+
177
+ def latest_metar_in_tac_format_for_your_airport_all_over_the_world(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
178
+ """
179
+ "Provides latest METAR for the airports all over the world in TAC format - please enter your airport's ICAO code as parameter."
180
+
181
+ """
182
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/metar/global/tac/items/{location}"
183
+ querystring = {}
184
+
185
+ headers = {
186
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
187
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
188
+ }
189
+
190
+
191
+ response = requests.get(url, headers=headers, params=querystring)
192
+ try:
193
+ observation = response.json()
194
+ except:
195
+ observation = response.text
196
+ return observation
197
+
198
+ def latest_taf_in_tac_format_for_your_airport_all_over_the_world(location: str, toolbench_rapidapi_key: str='088440d910mshef857391f2fc461p17ae9ejsnaebc918926ff'):
199
+ """
200
+ "Provides latest TAF for the airports all over the world in TAC format - please enter your airport's ICAO code as parameter."
201
+
202
+ """
203
+ url = f"https://fliteintel1.p.rapidapi.com/v1/weather/taf/global/tac/items/{location}"
204
+ querystring = {}
205
+
206
+ headers = {
207
+ "X-RapidAPI-Key": toolbench_rapidapi_key,
208
+ "X-RapidAPI-Host": "fliteintel1.p.rapidapi.com"
209
+ }
210
+
211
+
212
+ response = requests.get(url, headers=headers, params=querystring)
213
+ try:
214
+ observation = response.json()
215
+ except:
216
+ observation = response.text
217
+ return observation
218
+
toolbench/toolenv/tools/Weather/forcast_base.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tool_name":"Forcast Base",
3
+ "tool_description":"API to get weather forcast base on date and location",
4
+ "title":"Forcast Base",
5
+ "pricing":"FREEMIUM",
6
+ "score":null,
7
+ "home_url":"https://rapidapi.com/douglasanthonydiramio1811/api/forcast-base/",
8
+ "host":"forcast-base.p.rapidapi.com",
9
+ "api_list":[
10
+ {
11
+ "name":"default",
12
+ "url":"https://forcast-base.p.rapidapi.com/",
13
+ "description":"default endpoint",
14
+ "method":"GET",
15
+ "required_parameters":[],
16
+ "optional_parameters":[],
17
+ "code":"import requests\n\nurl = \"https://forcast-base.p.rapidapi.com/\"\n\nheaders = {\n \"X-RapidAPI-Key\": \"SIGN-UP-FOR-KEY\",\n \"X-RapidAPI-Host\": \"forcast-base.p.rapidapi.com\"\n}\n\nresponse = requests.get(url, headers=headers)\n\nprint(response.json())\n",
18
+ "statuscode":111,
19
+ "body":"",
20
+ "headers":"",
21
+ "schema":""
22
+ }
23
+ ]
24
+ }