Giter VIP home page Giter VIP logo

url-shortener's Introduction

URL Shortener

In this service, the user is able to generate a short URL based on a long URL e.g.

Long URL: https://www.google.com/search?q=some+long+url+to+search+on+google Short URL: http://localhost:3030/Aq13abq3

when the user access the short URL needs to be redirected to the original link

Aplication example

GraphQL: https://rgeorgel-url-shortener.herokuapp.com/api/graphql
Swagger: https://rgeorgel-url-shortener.herokuapp.com/swagger/

Setup

Local setup

pre-requirement: had yarn installed in the machine. recomend to install the YVM

  • Create the file .env (based on te file .env.example)
  • Run the command docker-compose up -d ** The first execution maybe can take some time. When the container is initialized, the dependencies will be downloaded

To check if the container is ready

docker-compose ps

To check the container logs

docker-compose logs -f --tail=50 url_shortener

To run tests

yarn test

End-points

In this project you will be able to:

GraphQL

http://localhost:3030/api/graphql

Rest

http://localhost:3030/swagger/

  • Create (Create a new shortURL)
  • Update (Update an existent shortURL)
  • Open URL (Redirect the user to the original URL)
  • Health (Get health check of the application)

url-shortener's People

Contributors

rgeorgel avatar

Watchers

James Cloos avatar  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.