🪐Nasa Apod Viewer [Python - Flask]

🪐Nasa Apod Viewer [Python - Flask]

A Python web application for fetching NASA’s Astronomy Picture of the Day, shareable as APOD cards.


About this project:

This project is a Python web application built with Flask. It fetches NASA’s Astronomy Picture of the Day (APOD) from the NASA API and provides functionalities to view and share the images as APOD cards.

Features:

  • Fetches the Astronomy Picture of the Day from the NASA API.
  • Enables users to explore APOD images via a calendar navigation or by searching for specific dates.
  • Includes a ‘Shuffle’ option that randomize picks for users who are uncertain which date to explore.
  • Showcases a curated selection of the finest APOD images from 1995 (the inception year of APOD) to the present via the ‘Featured NASA APOD per year’ Recommendations section.
  • Generates shareable APOD cards comprising the retrieved image, title, and description.
  • YouTube Integration (New Feature): Users can now watch APOD videos directly within the application interface. They can also share these YouTube videos as APOD cards, expanding the application’s sharing functionality. With this enhancement, users can easily spread the word about their favorite astronomical discoveries.

Topics:

Installation:

To run this project locally, follow these steps:

  1. Clone the repository to your local machine:

    git clone https://github.com/imprvhub/nasa-apod-viewer.git
  2. Install the required dependencies:

    pip install -r requirements.txt
  3. Set up environment variables. Ensure you have a .env file with the following variables:

    NASA_API_KEY: Your NASA API key.
    DATABASE_HOST: Hostname of your database.
    DATABASE_USERNAME: Username for database access.
    DATABASE_PASSWORD: Password for database access.
    DATABASE: Name of the database.
  4. Run the Flask application:

    cd api
    python3 index.py

Feedback:

Your feedback is valuable! If you encounter any issues or have suggestions for improvements, please create a new GitHub issue in this repository.

License:

This project is licensed under the MIT License. See the LICENSE file for details.

Conclusion:

Achievements
  • Efficient Management of Complex Workflow and Scripts: Efficient Management of Complex Workflow and Scripts: Effectively handling the intricate workflow involving multiple script executions to facilitate user interaction and offer various options, such as randomization, date selection, and APOD card generation, was the primary challenge addressed in this project. Ensuring the desired outcomes following each script execution and interaction was particularly rewarding. This required orchestrating a sequence of API calls to dynamically update the APOD based on user interactions, each serving distinct purposes. Attention to detail and comprehensive testing were essential to ensure seamless functionality throughout the process.
Learnings
  • Enhanced Frontend-Backend Interaction: I gained insights into achieving improved interaction between frontend scripts and Python backend processes. Previously, my approach was limited to transmitting specific data and processing it. However, this project necessitated establishing a continuous exchange of data between the frontend and backend due to the numerous scripts and interactions within the web application. It was a valuable learning experience.


Related Projects



✨ AnalyzeMyDream [Astro.js - FastAPI]

✨ AnalyzeMyDream [Astro.js - FastAPI]

AnalyzeMyDream is an innovative platform built using Astro.js, offering AI-powered dream interpretation to help users gain deeper insights into their dreams. The platform integrates seamlessly with FastAPI, Flask, and advanced AI models, providing quick and detailed analyses. Subscription-based pla

read more



🎬 Cinemathe [Vue.js - Django Rest Framework]

🎬 Cinemathe [Vue.js - Django Rest Framework]

A full-stack web app developed with Vue.js and Django Rest Framework, that simplifies entertainment choices. It provides seamless authentication for saving favorites, detailed technical info for movies and TV series with reviews included, and social media content sharing.

read more



⚡️BoltURL [Python - Flask]

⚡️BoltURL [Python - Flask]

This Link Shortener web app showcases how Python can do anything. Using Python (Flask Framework) with PostgreSQL (Supabase).

read more



📈 E-commerce Data Analysis [Next.js - Python]

📈 E-commerce Data Analysis [Next.js - Python]

This implementation showcases and provides a comprehensive analysis of e-commerce data from two different Next.js projects. Using Python (Flask Framework) with GUnicorn and Azure Deployment.

read more