-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.htm
538 lines (461 loc) · 17.9 KB
/
index.htm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-type" content="text/html;charset=UTF-8">
<meta name="keywords" content="HAPI Heliophysics Data UI">
<meta name="description"
content="HAPI Server UI; https://github.com/hapi-server/server-ui">
<meta name="keywords"
content="AMDA, CDAWeb, Cluster Active Archive, INTERMAGNET, LISIRD, SSCWeb, SWARM, Space Weather, ViRES">
<title>HAPI Server Browser</title>
<link rel="apple-touch-icon" sizes="180x180"
href="//hapi-server.org/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32"
href="//hapi-server.org/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16"
href="//hapi-server.org/favicon-16x16.png">
<link rel="manifest"
href="//hapi-server.org/site.webmanifest">
<link rel="stylesheet"
type="text/css" href="css/jquery-ui-1.9.2.custom.css"/>
<link rel="stylesheet"
type="text/css" href="css/highlight-10.0.0-github.css"/>
<link rel="stylesheet" href="css/index.css">
<script type="text/javascript"
src="js/deps/jquery-1.8.3.min.js"></script>
<script type="text/javascript"
src="js/deps/jquery-ui-1.9.2.custom.js"></script>
<script type="text/javascript"
src="js/deps/jquery.ba-hashchange-1.3.js"></script>
<script type="text/javascript"
src="js/deps/highlight-10.0.0.min.js"></script>
<script type="text/javascript" charset="UTF-8"
src="js/deps/highlight-10.0.0-python.min.js"></script>
<script type="text/javascript" charset="UTF-8"
src="js/deps/highlight-10.0.0-matlab.min.js"></script>
<script>
hljs.initHighlightingOnLoad();
hljs.getLanguage('python').keywords +=
' hapiplot hapiclient hapi server dataset parameters start stop';
hljs.getLanguage('matlab').keywords +=
' hapiplot hapiclient hapi server dataset parameters start stop';
hljs.getLanguage('javascript').keywords +=
' hapi server dataset parameters start stop';
</script>
<script src="js/deps/dayjs-1.8.29/dayjs.min.js"></script>
<script src="js/deps/dayjs-1.8.29/duration.js"></script>
<script>
dayjs.extend(window.dayjs_plugin_duration);
dayjs().format();
</script>
<script type="text/javascript" src="js/deps/clipboard.min.js"></script>
<script type="text/javascript" src="js/shared/parseAllTxt.js"></script>
<script type="text/javascript" src="js/shared/createScript.js"></script>
<script type="text/javascript" src="js/shared/defaultDate.js"></script>
<script type="text/javascript" src="js/ui/checkboxes.js"></script>
<script type="text/javascript" src="js/ui/dropdowns.js"></script>
<script type="text/javascript" src="js/ui/examples.js"></script>
<script type="text/javascript" src="js/ui/html.js"></script>
<script type="text/javascript" src="js/ui/tests.js"></script>
<script type="text/javascript" src="js/output/script.js"></script>
<script type="text/javascript" src="js/output/plot.js"></script>
<script type="text/javascript" src="js/output/data.js"></script>
<script type="text/javascript" src="scripts/_scriptList.js"></script>
<script type="text/javascript" src="js/util.js"></script>
<script type="text/javascript" src="js/hash.js"></script>
<script type="text/javascript" src="js/query.js"></script>
<script type="text/javascript" src="js/timer.js"></script>
<script type="text/javascript" src="js/get.js"></script>
<script type="text/javascript" src="js/index.js"></script>
<script>
let SERVER_LIST = '__SERVER_LIST__';
let VERIFIER = '__VERIFIER__';
let PLOTSERVER = '__PLOTSERVER__';
let PROXYSERVER = '__PROXYSERVER__';
function serverList(url) {
return url.startsWith('__') ? "all.txt" : url;
}
function proxyServerURL(url) {
if (url.startsWith('__')) {
return "https://hapi-server.org/servers/proxy?url=";
}
return url;
}
function verifierURL(url) {
if (url.startsWith('__')) {
url = "https://hapi-server.org/verify";
if (location.href.match("//localhost")) {
url = "http://localhost:9999";
}
}
return url;
}
function plotServerURL(url) {
if (url.startsWith('__')) {
url = "https://hapi-server.org/plot";
if (location.href.match("//localhost")) {
url = "http://localhost:5000";
}
}
}
window["HAPIUI"] =
{
"options": {
"serverList": serverList(SERVER_LIST),
"serverListFallback": "https://hapi-server.org/all_.txt",
"plotserver": plotServerURL(PLOTSERVER),
"verifier": verifierURL(VERIFIER),
"proxy": proxyServerURL(PROXYSERVER), // false => no proxy
"metadataTimeout": 10000,
"allTimeout": 5000,
"dataTimeout": 20000,
"timingUpdateInterval": 500,
"devNote": location.href.match("hapi-server.org/servers-dev") ? "Development server.<br>." : "",
"hapiplot": "https://hapi-server.org/plot/",
"autoplot": "https://jfaden.net/AutoplotServlet/SimpleServlet",
"cdawebplot": "https://cdaweb.gsfc.nasa.gov/WS/cdasr/1/dataviews/sp_phys/datasets",
"urlwatcher": "https://hapi-server.org/urlwatcher/",
"allowAllParameters": true
}
}
$(function() {
main(); // DOM is loaded. Call main() in js/index.js.
})
</script>
</head>
<body>
<div id="selections">
<!-- Left column -->
<div id="dropdowns">
</div>
<button id="clear" class="simple" type="button" title="Clear all selections">
Clear
</button>
<br>
<br>
<details id="options-details">
<summary>
<span>Options</span>
</summary>
<div id="optionscheckboxes">
<div title="When requesting data, show data in browser instead of only providing a download link.">
<div style="margin-top: 0.5em; font-weight: bold;">Show</div>
<label>
<input id="showdata" type="checkbox" value="">
data
</label>
</div>
<div title="Generate and show example queries">
<label>
<input id="showexamplequeries" type="checkbox" value="">
example queries
</label>
</div>
<div title="Keep requested URLs in view after request has succeeded.">
<label>
<input id="showrequests" type="checkbox" value="">
requested URLs
</label>
</div>
<div title="Show link to server status monitoring results (for debugging server responses)">
<label>
<input id="showstatuslink" type="checkbox" value="">
server status link
</label>
</div>
<div title="Show verifier links (for debugging server responses)">
<label>
<input id="showverifierlink" type="checkbox" value="">
verifier links
</label>
</div>
<div title="Show TestData servers (for testing clients)">
<label>
<input id="showtestdatalink" type="checkbox" value="">
test servers
</label>
</div>
<div title="Show debug statements in console.">
<label>
<input id="showconsolemessages" type="checkbox" value="">
logging in console
</label>
</div>
<div title="Show UI test links.">
<label>
<input id="showuitests" type="checkbox" value="">
UI test links
</label>
</div>
<br>
<div title="Use cached images from plot server if available.">
<label>
<input id="useimagecache" type="checkbox" value="">
Use cached images
</label>
</div>
<div title="Use cached data from plot server if available.">
<label>
<input id="usedatacache" type="checkbox" value="">
Use cached data for images
</label>
</div>
</div>
<button id="reset-options" class="simple" type="button" title="Select defaults">
Reset options
</button>
</details>
<div id="logo">
<a href="https://hapi-server.org">
<img src="https://hapi-server.github.io/logos/HAPI-bw.svg" alt="HAPI Logo"/></a>
</div>
<div id="footer">
<a href="https://github.com/hapi-server/server-ui" style="text-decoration:none">
<img src="css/images/github-mark.svg" alt="GitHub logo" height="24px"/>
</a>
<details id="developer-details" closed>
<summary>API</summary>
<p>
The <code>parameters</code> argument may be omitted in the hash fragment
(<a href="#server=TestData2.0&dataset=dataset1¶meters=&start=1970-01-01Z&stop=1970-01-01T00:00:11Z&return=data&format=csv&style=noheader">example</a>).
</p>
<p>
A server URL may be used instead of a server id
(<a href="#server=https://hapi-server.org/servers/TestData3.1/hapi">example</a>)
provided the server supports
<a href="https://github.com/hapi-server/data-specification/blob/master/hapi-dev/HAPI-data-access-spec-dev.md#5-cross-origin-resource-sharing">
CORS.
</a>
</p>
<p>
Auto-generated scripts are available from an <a href="/api">API</a>.
</p>
<br>
</details>
</div>
</div>
<!-- Main column -->
<div id="infodiv">
<div id="appError">
</div>
<div id="appWarning">
</div>
<div id="getStatus">
<div id="allRequestError" class="requestError"></div>
<div id="allRequestWarning" class="requestWarning"></div>
<div id="datasetsRequestError" class="requestError"></div>
<div id="dataRequestError" class="requestError"></div>
</div>
<div id="uitests">
<details id="uitests-details" open>
<summary>
<b>UI Test Queries</b>
</summary>
<div id="uitests-details-body"></div>
<!--button id="tests-run" class="simple" type="button" title="run tests">
Execute all tests
</button-->
</details>
<pre id="uitests-output"></pre>
</div>
<div id="overviewinfo">
<b>Overview</b>
<p>
The Heliophysics Data Application Programmer's Interface
(<a href="https://hapi-server.org/">HAPI</a>)
specification is a time series download and streaming format specification.
</p>
<p>
When data are available from a HAPI server, there is no need to download data files and write custom file reader programs. Using a HAPI client library, data can be loaded into an array using a single command in IDL, Javascript, MATLAB, and Python.
</p>
<p>
Space Weather-related data are available through this interface and HAPI software from
<a href="http://amda.irap.omp.eu/"
title="CDPP's Automated Multi-Dataset Analysis">
AMDA
</a>,
<a href="https://sci.esa.int/web/cluster/"
title="ESA's Cluster Active Archive">
CAA
</a>,
<a href="https://ccmc.gsfc.nasa.gov/"
title="NASA's Community Coordinated Modeling Center">
CCMC
</a>,
<a href="https://cdaweb.gsfc.nasa.gov/"
title="NASA's Coordinated Data Analysis Web Services">
CDAWeb</a>,
<a href="https://das2.org/"
title="University of Iowa's Data Access System, v2">
DAS2</a>,
<a href="https://intermagnet.org/"
title="International Real-time Magnetic Observatory Network">
INTERMAGNET</a>,
KNMI,
<a href="https://intermagnet.org/"
title="UC Boulder's LASP Interactive Solar Irradiance Data Center">
LISIRD</a>,
<a href="https://sscweb.gsfc.nasa.gov/"
title="NASA's Satellite Situation Center Web Services">
SSCWeb</a>, and
<a href="https://vires.services/"
title="Virtual Research Service for ESA's Swarm mission">
ViRES</a>.
</p>
<p>
<span>
<span id="nServers"></span>
<span id="nServersText">HAPI servers are available from this interface.</span>
</span>
<span id="allRequestInfo" class="requestInfo">
<span id="allRequestURL" class="requestURL"></span>
<span id="allRequestTiming" class="requestTime"></span>
</span>
</p>
<ul id="overviewul">
<li>
Use this interface to
<ul>
<li>
generate a
<a title="Heliphysics Data Application Interface: https://hapi-server.org/"
href="https://hapi-server.org/">HAPI
</a>
URL to download data,
</li>
<li>
plot data from a HAPI server, and
</li>
<li>generate scripts (with install instructions) that read and plot the selected parameter using HAPI clients for
<code>cURL</code> /
<a title="https://github.com/hapi-server/client-idl"
href="https://github.com/hapi-server/client-idl">IDL</a> /
<a title="https://github.com/hapi-server/client-idl"
href="https://github.com/hapi-server/client-idl">IDL SPEDAS</a> /
<a title="https://github.com/hapi-server/client-javascript"
href="https://github.com/hapi-server/client-javascript">Javascript</a> /
<a title="https://github.com/hapi-server/client-matlab"
href="https://github.com/hapi-server/client-matlab">MATLAB</a> /
<a title="https://github.com/hapi-server/client-python"
href="https://github.com/hapi-server/client-python">Python</a> /
<a title="https://github.com/spedas/pyspedas"
href="https://github.com/spedas/pyspedas">Python SPEDAS</a> /
<a title="https://nasa.github.io/Kamodo"
href="https://nasa.github.io/Kamodo/">Python Kamodo</a> /
<code>Wget</code>.
Example scripts can be created using links in "Example Queries".
</li>
</ul>
</li>
<li>
Begin by selecting a HAPI-enabled data server on the left or selecting an example query below.
</li>
</ul>
</div>
<details id="all-example-details">
<summary>
<b><span id="selected-server"></span>Example Queries</b>
</summary>
<br>
<div id="all-example-details-body"></div>
</details>
<div id="output">
<details id="plot-details" open>
<summary>
<span id="plot-summary">Plot</span>
|
<span id="imageRequestTiming" class="requestTime"></span>
</summary>
<div>
<span id="plot-downloadlink" style="display:none;"></span>
</div>
<div id="plotRequestWarning" class="requestWarning"></div>
<div id="plotRequestError" class="requestError"></div>
<div id="image">
</div>
</details>
<details id="data-details" open>
<summary>
Data
<span class="requestInfo">
<span id="dataRequestURL" class="requestURL"></span>
<span id="dataRequestTiming" class="requestTime"></span>
</span>
</summary>
<div>
<span id="data-downloadlink" style="display:none;"></span>
<code id="data-records-and-size"> </code>
</div>
<textarea id="data" class="data" readonly></textarea>
</details>
<details id="json-details" open>
<summary>
JSON
</summary>
<div>
<span id="json-downloadlink" style="display:none;"></span>
</div>
<div id="jsontext" class="json" readonly>
<code id="json"></code>
</div>
</details>
<details id="script-details" open>
<summary>Script</summary>
<div>
<span id="script-downloadlink" style="display:none;"></span>
</div>
<div id="scriptcopy" title="Copy to clipboard">
<button type="button" class="btn" style="padding:0px;" data-clipboard-text="">
<img class="clippy" width="20" src="css/clippy.png" alt="Copy to clipboard">
</button>
<span id="copied" title="Copied!"></span>
</div>
<div id="scripttext" class="data" readonly>
<code id="script"></code>
</div>
</details>
</div>
<div id="serverinfo">
<b>Server information</b>
<p>
<span>
<span id="nDatasets"></span>
</span>
<div class="requestInfo">
<div>
<span id="catalogRequestURL" class="requestURL"></span>
<span id="catalogRequestTiming" class="requestTime"></span>
</div>
<div>
<div id="aboutRequestWarning" class="requestWarning"></div>
<span id="aboutRequestURL" class="requestURL"></span>
<span id="aboutRequestTiming" class="requestTime"></span>
</div>
</div>
</p>
<ul></ul>
</div>
<div id="datasetinfo">
<b>Dataset information</b>
<p>
<span id="nParameters"></span>
<div class="requestInfo">
<span id="parametersRequestURL" class="requestURL"></span>
<span id="parametersRequestTiming" class="requestTime"></span>
<div id="parametersRequestError" class="requestError"></div>
</div>
<div class="requestInfo">
<span id="urlwatcherRequestURL" class="requestURL"></span>
<span id="urlwatcherRequestTiming" class="requestTime"></span>
<span id="urlwatcherRequestError" class="requestTime"></span>
</div>
</p>
<ul></ul>
</div>
<div id="parameterinfo">
<b>Parameter information</b>
<ul></ul>
</div>
</div>
</body>
</html>