Giter VIP home page Giter VIP logo

node-express-api's Introduction

Node Fastify API

This is a demo application for building a Node API. In this demo, we will do CRUD operations on Tweets.

Node APIs and MongoDB go hand-in-hand. This demo app uses:

Routes

The routes for this app are:

  • GET /tweets: Get all tweets
  • POST /tweets: Create a tweet
  • GET /tweets/<tweet_id>: Get a single tweet
  • PUT /tweets/<tweet_id>: Update a tweet
  • DELETE /tweets/<tweet_id>: Delete a tweet

Deploying to DigitalOcean

Deploy to DO

How to Deploy

This demo can be deployed using the 1-click button above. If you want to deploy this to your DigitalOcean App Platform, follow these steps:

  1. Fork this repo so you have this on your GitHub account
  2. Create a MongoDB Database
  3. Login to your DigitalOcean App Platform Dashboard
  4. Click Create App
  5. Search for your GitHub repo
  6. Remove the npm run build command from the build setup
  7. Link the MongoDB database you just created
  8. Follow the steps to deploy
  9. Add your MongoDB DATABASE_URL to your environment variables
  10. Add your MongoDB CA_CERT to your environment variables

Adding a MongoDB Database

  1. Login to your DigitalOcean account
  2. Go to Create -> Database
  3. Create a MongoDB Database
  4. Grab the connection URL
  5. Add an environment variable in App Platform called DATABASE_URL

node-express-api's People

Contributors

chris-sev avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 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.