xmr-remote-nodes/handler/routes.go
ditatompel 59f1dd9421
List Probers CLI command #2
Listing probers is now only available from server CLI.

The `ProbersQueryParams` struct also changed. I don't think that I will
use more than 20 probers in this project, so paging is not required.

The search param also simplified in one field struct `Search" which
search both in `name` and `api_key` column.
2024-05-18 00:56:13 +07:00

24 lines
531 B
Go

package handler
import (
"github.com/gofiber/fiber/v2"
)
func AppRoute(app *fiber.App) {
app.Post("/auth/login", Login)
app.Post("/auth/logout", Logout)
}
func V1Api(app *fiber.App) {
v1 := app.Group("/api/v1")
v1.Get("/crons", CookieProtected, Crons)
v1.Get("/nodes", MoneroNodes)
v1.Post("/nodes", AddNode)
v1.Get("/nodes/id/:id", MoneroNode)
v1.Get("/nodes/logs", ProbeLogs)
v1.Get("/fees", NetFee)
v1.Get("/countries", Countries)
v1.Get("/job", CheckProber, GiveJob)
v1.Post("/job", CheckProber, ProcessJob)
}