Passport/pkg/server/well_known_api.go

15 lines
325 B
Go
Raw Normal View History

2024-01-28 16:32:39 +00:00
package server
import (
"github.com/gofiber/fiber/v2"
"github.com/spf13/viper"
)
func getMetadata(c *fiber.Ctx) error {
return c.JSON(fiber.Map{
2024-01-29 08:11:59 +00:00
"name": viper.GetString("name"),
"domain": viper.GetString("domain"),
"open_registration": !viper.GetBool("use_registration_magic_token"),
2024-01-28 16:32:39 +00:00
})
}