ddstats-server/api/api.js

26 lines
541 B
JavaScript
Raw Normal View History

2021-10-30 20:26:37 +02:00
import { Router } from 'express'
import playerApi from './players.js'
import mapApi from './maps.js'
import finishesApi from './finishes.js'
import graphApi from './graph.js'
const api = Router()
api.get(
'/',
(req, res) => res.json({
success: true,
response: "You connected to DDStats API! :D"
})
)
api.use('/players', playerApi)
api.use('/maps', mapApi)
api.use('/finishes', finishesApi)
api.use('/graph', graphApi)
/**
* This module is the entrypoint for the API.
* @module api/api
*/
export default api