Giter Club home page Giter Club logo

f1-results-api's Introduction

F1 Results API

CC0 Public Domain Coverage Branch Test Test

This is a simple API Code Example for consume F1 historical results

Features:

  • Spring Boot
  • Swagger
  • PostgreSQL
  • Mockito
  • Pagination
  • JWT
  • JaCoCo
  • mvn Profiles
  • GitHub Actions
  • GitHub Secrets
  • GitHub Badges
  • Unit testing with embedded DB (h2 engine)
  • Docker build and push to Docker Hub
  • Docker compose files for API and DB Only
  • Updated until Saudi Arabian Grand Prix *

Steps to install

1.- Install all dependences

  • Java 8
  • Maven
  • Docker
  • (Optional) PostgreSQL Server
    • This is only necesary only if you want to create your DB from scratch

2.- Clone this repo

git clone https://github.com/afv9988/F1-Results-API.git
mvn clean install

3.- Execute DB instance

  • Init docker compose for only db (This can take a long)
docker-compose -f docker/run_only_db.yml up
  • Or use my public db on your properties file
jdbc:postgresql://afdev.ddns.net:5432/f1_db
username=f1_user
passw=a912072

4.- Init Spring Boot

.\mvnw.cmd spring-boot:run

Run all in docker

docker-compose -f docker/run_API_and_postgres.yml up

Demo Swagger

For access the Demo you need to generate a token here or

curl -X GET "http://afdev.ddns.net/token?password=NEW_USER&username=NEW_PASSWORD" -H "accept: */*"

Then authenticate in Swager on JWT apiKey For external use of token add -H "Authorization: YOUR-TOKEN-GENERATED"

Resources

Resources

f1-results-api's People

Contributors

angelfloreso avatar github-actions[bot] avatar

Stargazers

 avatar

Watchers

 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.