Auth: Able to use API tokens for authentication (#1662)

* Auth: Able to use API tokens for authentication

* Update change log
This commit is contained in:
Alexander Zobnin
2023-07-26 18:23:44 +03:00
committed by GitHub
parent 8205f7aaf8
commit ac976945a5
9 changed files with 174 additions and 55 deletions

View File

@@ -2,8 +2,14 @@ package settings
import "time"
const (
AuthTypeUserLogin = "userLogin"
AuthTypeToken = "token"
)
// ZabbixDatasourceSettingsDTO model
type ZabbixDatasourceSettingsDTO struct {
AuthType string `json:"authType"`
Trends bool `json:"trends"`
TrendsFrom string `json:"trendsFrom"`
TrendsRange string `json:"trendsRange"`
@@ -16,6 +22,7 @@ type ZabbixDatasourceSettingsDTO struct {
// ZabbixDatasourceSettings model
type ZabbixDatasourceSettings struct {
AuthType string
Trends bool
TrendsFrom time.Duration
TrendsRange time.Duration