Git Product home page Git Product logo

ciobiano / autorefuel Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sattu2806/animated-landing-page

0.0 0.0 0.0 8.91 MB

Auto Refuel is a web application designed to facilitate the online ordering and delivery of various fuel types directly to your location. It integrates a seamless payment system using Stripe and provides a user-friendly interface for selecting fuel types, specifying quantities, and confirming orders.

Home Page: https://auto-refuel.vercel.app

JavaScript 0.29% TypeScript 98.17% CSS 1.53%

autorefuel's Introduction

Auto Refuel Application

Overview

Auto Refuel is a web application designed to facilitate the online ordering and delivery of various fuel types directly to your location. It integrates a seamless payment system using Stripe and provides a user-friendly interface for selecting fuel types, specifying quantities, and confirming orders.

Features

  • Fuel Selection: Users can choose from various types of fuel and specify the quantity in liters.
  • Dynamic Pricing: The application calculates the total cost based on the selected fuel type and quantity, including delivery charges.
  • Secure Payment: Integrates with Stripe for secure payment processing.
  • Responsive Design: Compatible with various devices, ensuring a smooth user experience.

Technologies Used

  • React: For building the user interface.
  • Next.js: A React framework for server-side rendering and generating static websites.
  • Stripe: For handling payments.
  • Tailwind CSS: For styling and designing the frontend.
  • Prisma: As an ORM for handling database operations.
  • TypeScript: For adding static type definitions to JavaScript.
  • MongoDB: For Database

Installation

  1. Clone the repository

    git clone https://github.com/ciobiano/AutoRefuel.git
    cd auto-refuel
  2. Install dependencies

    pnpm install
  3. Set up environment variables

    • Rename .env.example to .env.
    • Fill in the necessary API keys and database credentials.
  4. Run the development server

    pnpm  dev

Usage

Navigate to http://localhost:3000 to access the application. From the homepage, users can:

  • Select the type of fuel and specify the quantity.
  • View the calculated costs including delivery fees.
  • Proceed to checkout and complete the payment.

API Reference

Create Payment Intent

POST /api/create-intent

  • Body:
    {
      "fuelType": "Gasoline",
      "liters": 10,
      "amount": 8200
    }
  • Response:
    {
      "client_secret": "secret_key_here"
    }

Contributing

Contributions are welcome! Please fork the repository and create a pull request with your features or fixes.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

autorefuel's People

Contributors

ciobiano avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.