-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathopenapi.yaml
More file actions
1964 lines (1870 loc) · 48.8 KB
/
openapi.yaml
File metadata and controls
1964 lines (1870 loc) · 48.8 KB
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
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.3
info:
title: NASA API Proxy Service
description: |
# NASA API Proxy Service 🚀
A high-performance Cloudflare Worker providing unified access to various NASA APIs with intelligent caching, rate limiting, and enhanced features.
## Features
- **Unified Access**: Single endpoint for multiple NASA data sources
- **Intelligent Caching**: Reduces API calls and improves response times
- **Rate Limiting**: Fair usage protection across all endpoints
- **CORS Support**: Browser-friendly API access
- **No API Key Required**: The proxy handles NASA API authentication
## Available Data Sources
- **APOD**: Astronomy Picture of the Day
- **NEO**: Near Earth Objects tracking
- **DONKI**: Space Weather Database
- **Earth**: Satellite imagery
- **EPIC**: Earth Polychromatic Imaging Camera
- **Mars Rovers**: Photos from Mars missions
- **Media Library**: NASA images and videos
- **Exoplanets**: Confirmed exoplanet data
- **SSD/CNEOS**: Solar System Dynamics
- **Tech Transfer**: NASA technology innovations
## Getting Started
All endpoints are available at `https://nasa-api-worker.guitaripod.workers.dev/api/*`
No authentication is required - the proxy handles NASA API keys internally.
## Rate Limits
- 100 requests per minute per IP address
- Cached responses don't count against rate limits
## Support
For issues or feature requests, please contact the API maintainer.
version: 1.0.0
contact:
name: API Support
url: https://github.com/yourusername/nasa-api-proxy
license:
name: MIT
url: https://opensource.org/licenses/MIT
servers:
- url: https://nasa-api-worker.guitaripod.workers.dev
description: Production server
tags:
- name: APOD
description: Astronomy Picture of the Day - Daily space imagery with scientific explanations
- name: NEO
description: Near Earth Objects - Track asteroids and comets near Earth
- name: DONKI
description: Space Weather Database - Real-time space weather events and notifications
- name: Earth
description: Earth Imagery - Landsat satellite imagery of Earth locations
- name: EPIC
description: Earth Polychromatic Imaging Camera - Full disc Earth imagery
- name: Mars
description: Mars Rover Photos - Images from Curiosity, Opportunity, and Spirit rovers
- name: Media
description: NASA Image and Video Library - Search NASA's media archives
- name: Exoplanets
description: Exoplanet Archive - Query confirmed exoplanet data
- name: SSD
description: Solar System Dynamics - Orbital data and impact risk assessment
- name: Tech Transfer
description: Technology Transfer - NASA patents, software, and spinoffs
paths:
/api/apod:
get:
tags:
- APOD
summary: Get Astronomy Picture of the Day
description: |
Retrieve the Astronomy Picture of the Day with explanation. Returns daily space imagery
ranging from photographs to artist concepts, each with a brief scientific explanation.
parameters:
- name: date
in: query
description: Date of the APOD image to retrieve
schema:
type: string
format: date
example: "2024-01-15"
- name: start_date
in: query
description: Start of date range (requires end_date)
schema:
type: string
format: date
- name: end_date
in: query
description: End of date range (requires start_date)
schema:
type: string
format: date
- name: count
in: query
description: Return random APODs (cannot be used with date parameters)
schema:
type: integer
minimum: 1
maximum: 100
- name: thumbs
in: query
description: Include thumbnail URL for video APODs
schema:
type: boolean
default: false
responses:
'200':
description: Successful response
content:
application/json:
schema:
oneOf:
- $ref: '#/components/schemas/ApodResponse'
- type: array
items:
$ref: '#/components/schemas/ApodResponse'
examples:
single:
summary: Single APOD
value:
copyright: "John Doe"
date: "2024-01-15"
explanation: "This stunning image shows..."
hdurl: "https://apod.nasa.gov/apod/image/2401/example_hd.jpg"
media_type: "image"
service_version: "v1"
title: "The Andromeda Galaxy"
url: "https://apod.nasa.gov/apod/image/2401/example.jpg"
'400':
$ref: '#/components/responses/BadRequest'
'429':
$ref: '#/components/responses/RateLimited'
'500':
$ref: '#/components/responses/InternalError'
/api/neo/feed:
get:
tags:
- NEO
summary: Get NEO feed by date range
description: Retrieve a list of Near Earth Objects within a date range, including close approach data
parameters:
- name: start_date
in: query
description: Start date for NEO search
schema:
type: string
format: date
example: "2024-01-15"
- name: end_date
in: query
description: End date for NEO search (max 7 days after start_date)
schema:
type: string
format: date
example: "2024-01-22"
responses:
'200':
description: Successful response
content:
application/json:
schema:
$ref: '#/components/schemas/NeoFeedResponse'
'400':
$ref: '#/components/responses/BadRequest'
'429':
$ref: '#/components/responses/RateLimited'
/api/neo/{asteroid_id}:
get:
tags:
- NEO
summary: Get specific NEO by ID
description: Retrieve detailed information about a specific Near Earth Object
parameters:
- name: asteroid_id
in: path
required: true
description: Asteroid SPK-ID
schema:
type: string
example: "3542519"
responses:
'200':
description: Successful response
content:
application/json:
schema:
$ref: '#/components/schemas/Neo'
'404':
description: Asteroid not found
'429':
$ref: '#/components/responses/RateLimited'
/api/neo/browse:
get:
tags:
- NEO
summary: Browse all NEOs with pagination
description: Browse the overall Near Earth Object dataset with pagination support
parameters:
- name: page
in: query
description: Page number (0-indexed)
schema:
type: integer
minimum: 0
default: 0
- name: size
in: query
description: Number of NEOs per page
schema:
type: integer
minimum: 1
maximum: 20
default: 20
responses:
'200':
description: Successful response
content:
application/json:
schema:
$ref: '#/components/schemas/NeoBrowseResponse'
'429':
$ref: '#/components/responses/RateLimited'
/api/donki/cme:
get:
tags:
- DONKI
summary: Get Coronal Mass Ejections
description: Retrieve Coronal Mass Ejection (CME) events from the Space Weather Database
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of CME events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/CmeEvent'
/api/donki/cme-analysis:
get:
tags:
- DONKI
summary: Get CME Analysis data
description: Retrieve detailed Coronal Mass Ejection analysis data
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of CME analysis events
content:
application/json:
schema:
type: array
items:
type: object
/api/donki/gst:
get:
tags:
- DONKI
summary: Get Geomagnetic Storms
description: Retrieve Geomagnetic Storm (GST) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of GST events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/GstEvent'
/api/donki/ips:
get:
tags:
- DONKI
summary: Get Interplanetary Shocks
description: Retrieve Interplanetary Shock (IPS) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of IPS events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/IpsEvent'
/api/donki/flr:
get:
tags:
- DONKI
summary: Get Solar Flares
description: Retrieve Solar Flare (FLR) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of FLR events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/FlrEvent'
/api/donki/sep:
get:
tags:
- DONKI
summary: Get Solar Energetic Particles
description: Retrieve Solar Energetic Particle (SEP) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of SEP events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/SepEvent'
/api/donki/mpc:
get:
tags:
- DONKI
summary: Get Magnetopause Crossings
description: Retrieve Magnetopause Crossing (MPC) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of MPC events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/MpcEvent'
/api/donki/rbe:
get:
tags:
- DONKI
summary: Get Radiation Belt Enhancements
description: Retrieve Radiation Belt Enhancement (RBE) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of RBE events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/RbeEvent'
/api/donki/hss:
get:
tags:
- DONKI
summary: Get High Speed Streams
description: Retrieve High Speed Stream (HSS) events
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of HSS events
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/HssEvent'
/api/donki/wsa-enlil:
get:
tags:
- DONKI
summary: Get WSA+Enlil Simulations
description: Retrieve WSA+Enlil solar wind prediction simulations
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of WSA+Enlil simulations
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/WsaEnlilSimulation'
/api/donki/notifications:
get:
tags:
- DONKI
summary: Get Space Weather Notifications
description: Retrieve space weather notifications and alerts
parameters:
- $ref: '#/components/parameters/startDate'
- $ref: '#/components/parameters/endDate'
responses:
'200':
description: Array of notifications
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Notification'
/api/earth/imagery:
get:
tags:
- Earth
summary: Get Earth imagery for location
description: Retrieve Landsat 8 satellite imagery for a specific Earth location
parameters:
- name: lat
in: query
required: true
description: Latitude
schema:
type: number
minimum: -90
maximum: 90
example: 29.78
- name: lon
in: query
required: true
description: Longitude
schema:
type: number
minimum: -180
maximum: 180
example: -95.33
- name: date
in: query
description: Date of imagery
schema:
type: string
format: date
example: "2023-06-15"
- name: dim
in: query
description: Image width and height in degrees
schema:
type: number
minimum: 0.01
maximum: 0.3
default: 0.15
responses:
'200':
description: Satellite image
content:
image/png:
schema:
type: string
format: binary
'400':
$ref: '#/components/responses/BadRequest'
/api/earth/assets:
get:
tags:
- Earth
summary: Get available imagery dates
description: Retrieve dates for available Landsat 8 imagery at a location
parameters:
- name: lat
in: query
required: true
description: Latitude
schema:
type: number
minimum: -90
maximum: 90
- name: lon
in: query
required: true
description: Longitude
schema:
type: number
minimum: -180
maximum: 180
- name: date
in: query
required: true
description: Reference date
schema:
type: string
format: date
responses:
'200':
description: Available imagery assets
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/EarthAsset'
/api/epic/natural/all:
get:
tags:
- EPIC
summary: Get all natural color images
description: Retrieve the most recent natural color images of Earth
responses:
'200':
description: Array of EPIC images
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/EpicImage'
/api/epic/natural/date/{date}:
get:
tags:
- EPIC
summary: Get natural color images by date
description: Retrieve natural color Earth images for a specific date
parameters:
- name: date
in: path
required: true
description: Date to retrieve images
schema:
type: string
format: date
example: "2024-01-15"
responses:
'200':
description: Array of EPIC images
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/EpicImage'
/api/epic/enhanced/all:
get:
tags:
- EPIC
summary: Get all enhanced color images
description: Retrieve the most recent enhanced color images of Earth
responses:
'200':
description: Array of EPIC images
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/EpicImage'
/api/epic/enhanced/date/{date}:
get:
tags:
- EPIC
summary: Get enhanced color images by date
description: Retrieve enhanced color Earth images for a specific date
parameters:
- name: date
in: path
required: true
description: Date to retrieve images
schema:
type: string
format: date
responses:
'200':
description: Array of EPIC images
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/EpicImage'
/api/mars-photos/{rover}/photos:
get:
tags:
- Mars
summary: Get Mars rover photos
description: Retrieve photos taken by a specific Mars rover
parameters:
- name: rover
in: path
required: true
description: Rover name
schema:
type: string
enum: [curiosity, opportunity, spirit]
- name: sol
in: query
description: Martian sol (day) of photos
schema:
type: integer
minimum: 0
example: 1000
- name: earth_date
in: query
description: Earth date of photos (use either sol or earth_date)
schema:
type: string
format: date
- name: camera
in: query
description: Filter by camera
schema:
type: string
enum: [FHAZ, RHAZ, MAST, CHEMCAM, MAHLI, MARDI, NAVCAM, PANCAM, MINITES]
- name: page
in: query
description: Page number for pagination
schema:
type: integer
minimum: 1
default: 1
responses:
'200':
description: Mars rover photos
content:
application/json:
schema:
$ref: '#/components/schemas/MarsPhotosResponse'
/api/mars-photos/{rover}/latest:
get:
tags:
- Mars
summary: Get latest Mars rover photos
description: Retrieve the most recent photos from a Mars rover
parameters:
- name: rover
in: path
required: true
description: Rover name
schema:
type: string
enum: [curiosity, opportunity, spirit]
responses:
'200':
description: Latest Mars rover photos
content:
application/json:
schema:
$ref: '#/components/schemas/MarsPhotosResponse'
/api/mars-photos/manifests/{rover}:
get:
tags:
- Mars
summary: Get Mars rover manifest
description: Retrieve mission manifest for a Mars rover
parameters:
- name: rover
in: path
required: true
description: Rover name
schema:
type: string
enum: [curiosity, opportunity, spirit]
responses:
'200':
description: Rover mission manifest
content:
application/json:
schema:
$ref: '#/components/schemas/MarsManifest'
/api/media/search:
get:
tags:
- Media
summary: Search NASA media library
description: Search NASA's image and video library
parameters:
- name: q
in: query
description: Free text search terms
schema:
type: string
example: "apollo 11"
- name: center
in: query
description: NASA center
schema:
type: string
example: "JSC"
- name: description
in: query
description: Search in descriptions
schema:
type: string
- name: keywords
in: query
description: Comma-separated keywords
schema:
type: string
- name: location
in: query
description: Geographic location
schema:
type: string
- name: media_type
in: query
description: Filter by media type
schema:
type: string
enum: [image, video, audio]
- name: nasa_id
in: query
description: NASA asset ID
schema:
type: string
- name: page
in: query
description: Page number
schema:
type: integer
minimum: 1
default: 1
- name: photographer
in: query
description: Photographer name
schema:
type: string
- name: title
in: query
description: Search in titles
schema:
type: string
- name: year_start
in: query
description: Start year
schema:
type: string
- name: year_end
in: query
description: End year
schema:
type: string
responses:
'200':
description: Search results
content:
application/json:
schema:
$ref: '#/components/schemas/MediaSearchResponse'
/api/media/asset/{nasa_id}:
get:
tags:
- Media
summary: Get media asset files
description: Retrieve file URLs for a specific NASA media asset
parameters:
- name: nasa_id
in: path
required: true
description: NASA asset ID
schema:
type: string
responses:
'200':
description: Asset file URLs
content:
application/json:
schema:
$ref: '#/components/schemas/MediaAssetResponse'
/api/media/metadata/{nasa_id}:
get:
tags:
- Media
summary: Get media metadata
description: Retrieve metadata for a specific NASA media asset
parameters:
- name: nasa_id
in: path
required: true
description: NASA asset ID
schema:
type: string
responses:
'200':
description: Asset metadata
content:
application/json:
schema:
type: object
/api/media/captions/{nasa_id}:
get:
tags:
- Media
summary: Get media captions
description: Retrieve captions/subtitles for a NASA video asset
parameters:
- name: nasa_id
in: path
required: true
description: NASA asset ID
schema:
type: string
responses:
'200':
description: Video captions
content:
text/vtt:
schema:
type: string
/api/exoplanets/query:
get:
tags:
- Exoplanets
summary: Query exoplanet archive
description: Query the NASA Exoplanet Archive using TAP (Table Access Protocol)
parameters:
- name: query
in: query
required: true
description: TAP query string
schema:
type: string
example: "select * from ps where pl_name like 'Kepler%' limit 10"
- name: format
in: query
description: Output format
schema:
type: string
enum: [json, csv, xml]
default: json
responses:
'200':
description: Query results
content:
application/json:
schema:
$ref: '#/components/schemas/ExoplanetResponse'
/api/ssd/cad:
get:
tags:
- SSD
summary: Get close approach data
description: Query close approach data for asteroids and comets
parameters:
- name: date-min
in: query
description: Start date for close approaches
schema:
type: string
format: date
- name: date-max
in: query
description: End date for close approaches
schema:
type: string
format: date
- name: dist-max
in: query
description: Maximum approach distance (au)
schema:
type: number
- name: h-max
in: query
description: Maximum absolute magnitude
schema:
type: number
- name: pha
in: query
description: Limit to potentially hazardous asteroids
schema:
type: boolean
- name: nea-comet
in: query
description: Include near-Earth comets
schema:
type: boolean
responses:
'200':
description: Close approach data
content:
application/json:
schema:
$ref: '#/components/schemas/CadResponse'
/api/ssd/sbdb:
get:
tags:
- SSD
summary: Small Body Database lookup
description: Look up a specific asteroid or comet
parameters:
- name: sstr
in: query
required: true
description: Search string (name, designation, or SPK-ID)
schema:
type: string
example: "433"
- name: cad
in: query
description: Include close-approach data
schema:
type: boolean
- name: phys-par
in: query
description: Include physical parameters
schema:
type: boolean
responses:
'200':
description: Small body data
content:
application/json:
schema:
$ref: '#/components/schemas/SbdbResponse'
/api/ssd/sentry:
get:
tags:
- SSD
summary: Get Sentry impact risk data
description: Query potential future Earth impact risks
parameters:
- name: all
in: query
description: Return all objects
schema:
type: boolean
- name: removed
in: query
description: Include removed objects
schema:
type: boolean
- name: ip-min
in: query
description: Minimum impact probability
schema:
type: number
- name: ps-min
in: query
description: Minimum Palermo scale
schema:
type: number
responses:
'200':
description: Sentry impact risk data
content:
application/json:
schema:
$ref: '#/components/schemas/SentryResponse'
/api/ssd/scout:
get:
tags:
- SSD
summary: Get Scout trajectory analysis
description: Get trajectory analysis for recently discovered objects