Skip to main content

nasa.py

An easy to use, async ready wrapper for the NASA Open API's.

Key Features

  • Intuitive Syntax deriving from API Names
  • Proper Exception Handling
  • 100% coverage of each supported API

Installing

There are a few ways which you can install the Library. To install the stable version, simply run the following commands:

# Linux/macOS
python3 -m pip install -U nasa.py

# Windows
py -3 -m pip install -U nasa.py

To install the Library with its http speedups, simply run the same commands but with the following alterations:

# Linux/macOS
python3 -m pip install -U "nasa.py[speedups]"

# Windows
py -3 -m pip install -U nasa.py[speedups]

You can install the development version, you can do the following:

$ git clone https://github.com/quiktea/nasa.py
$ cd nasa.py
$ python3 -m pip install -U .[speedups]

Examples

All of the library's syntax is heavily inspired by the NASA Open API names. For example, to fetch the apod api, you can simply run the await .apod method.

Astronomy Picture of the Day (APOD)

from nasa import Client
client = Client("api_key") #providing an invalid api key or no api key will raise an Invalid API_KEY Error
apod_result = await client.apod()
video = apod_result.media.video
print(video)
print(video.url)

This will return:

>>> <Video url='https://www.youtube.com/embed/badXkJ6BnOs?rel=0'>
>>> https://www.youtube.com/embed/badXkJ6BnOs?rel=0

Getting an API Key

To get an API Key, simply visit the Nasa Open API website, fill out the form and get your api key!

API Key Generate Info

Currently Supported API's

  • APOD (Astronomy Picture of the Day)

Metadata

Release files for nasa.py 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nasa.py 0.2.0
File Size Uploaded Provenance Actions
nasa.py-0.2.0.tar.gz 4.7 kB Without provenance Details for nasa.py-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nasa.py 0.2.0
File Interpreter ABI Platform Actions
nasa.py-0.2.0-py3-none-any.whl Python 3 none any Details for nasa.py-0.2.0-py3-none-any.whl

Total release size: 10.6 kB

Release files / nasa.py-0.2.0.tar.gz

Download URL nasa.py-0.2.0.tar.gz
Size 4.7 kB
Tags Source
SHA-256 checksum
How to use checksums
4f746bb83b5788abc3e46f2b30629e21de6cb0dca0cd01a0cb11bde4a840fdb5
BLAKE2b-256 checksum
How to use checksums
0d15a48a590cda6246cbeed2617ff3652cc22cff4d91df0b2c6390a48c128c87
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.24.0 setuptools/54.2.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7

Release files / nasa.py-0.2.0-py3-none-any.whl

Download URL nasa.py-0.2.0-py3-none-any.whl
Size 6.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
81f30ec170ca6ac3daad2112c96d67ab9b7e4361aeea8312555ef5aa2e09c008
BLAKE2b-256 checksum
How to use checksums
688bd823731b7c6a03c7ac2e87972a9fd2448d469f37eac6e6a8dc0bd76f7776
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.24.0 setuptools/54.2.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7

Security for nasa.py 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page