api

package
v0.0.0-testrgm4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 21, 2023 License: AGPL-3.0 Imports: 153 Imported by: 222

README

OpenAPI specifications

Since version 8.4, HTTP API details are specified using OpenAPI v2. Starting from version 9.1, there is also an OpenAPI v3 specification (generated by the v2 one using this script).

OpenAPI annotations

The OpenAPI v2 specification is generated automatically from the annotated Go code using go-swagger which scans the source code for annotation rules. Refer to this getting started guide for getting familiar with the toolkit.

Developers modifying the HTTP API endpoints need to make sure to add the necessary annotations so that their changes are reflected into the generated specifications.

Example of endpoint annotation

The following route defines a PATCH endpoint under the /serviceaccounts/{serviceAccountId} path with tag service_accounts (used for grouping together several routes) and operation ID updateServiceAccount (used for uniquely identifying routes and associate parameters and response with them).


// swagger:route PATCH /serviceaccounts/{serviceAccountId} service_accounts updateServiceAccount
//
// # Update service account
//
// Required permissions (See note in the [introduction](https://grafana.com/docs/grafana/latest/developers/http_api/serviceaccount/#service-account-api) for an explanation):
// action: `serviceaccounts:write` scope: `serviceaccounts:id:1` (single service account)
//
// Responses:
// 200: updateServiceAccountResponse
// 400: badRequestError
// 401: unauthorisedError
// 403: forbiddenError
// 404: notFoundError
// 500: internalServerError

The go-swagger can discover such annotations by scanning any code imported by pkg/server but by convention we place the endpoint annotations above the endpoint definition.

Example of endpoint parameters

The following struct defines the route parameters for the updateServiceAccount endpoint. The route expects:

  • a path parameter denoting the service account identifier and
  • a body parameter with the new values for the specific service account

// swagger:parameters updateServiceAccount
type UpdateServiceAccountParams struct {
	// in:path
	ServiceAccountId int64 `json:"serviceAccountId"`
	// in:body
	Body serviceaccounts.UpdateServiceAccountForm
}

Example of endpoint response

The following struct defines the response for the updateServiceAccount endpoint in case of a successful 200 response.


// swagger:response updateServiceAccountResponse
type UpdateServiceAccountResponse struct {
	// in:body
	Body struct {
		Message        string                                    `json:"message"`
		ID             int64                                     `json:"id"`
		Name           string                                    `json:"name"`
		ServiceAccount *serviceaccounts.ServiceAccountProfileDTO `json:"serviceaccount"`
	}
}

OpenAPI generation

Developers can re-create the OpenAPI v2 and v3 specifications using the following command:


make clean-api-spec && make openapi3-gen

They can observe its output into the public/api-merged.json and public/openapi3.json files.

Finally, they can browser and try out both the OpenAPI v2 and v3 via the Swagger UI editor (served by the grafana server) by navigating to /swagger-ui and /openapi3 respectivally.

Documentation

Overview

Package api Grafana HTTP API.

The Grafana backend exposes an HTTP API, the same API is used by the frontend to do everything from saving dashboards, creating users and updating data sources.

Schemes: http, https
BasePath: /api
Version: 0.0.1
Contact: Grafana Labs<hello@grafana.com> https://grafana.com

Consumes:
- application/json

Produces:
- application/json

Security:
- basic:
- api_key:

SecurityDefinitions:
basic:
 type: basic
api_key:
 type: apiKey
 name: Authorization
 in: header

swagger:meta

Index

Constants

View Source
const (
	OauthStateCookieName = "oauth_state"
	OauthPKCECookieName  = "oauth_code_verifier"
)
View Source
const (
	ActionProvisioningReload = "provisioning:reload"
)

API related actions

Variables

View Source
var (
	ScopeProvisionersAll           = ac.Scope("provisioners", "*")
	ScopeProvisionersDashboards    = ac.Scope("provisioners", "dashboards")
	ScopeProvisionersPlugins       = ac.Scope("provisioners", "plugins")
	ScopeProvisionersDatasources   = ac.Scope("provisioners", "datasources")
	ScopeProvisionersNotifications = ac.Scope("provisioners", "notifications")
	ScopeProvisionersAlertRules    = ac.Scope("provisioners", "alerting")
)

API related scopes

View Source
var ErrUnexpectedFileExtension = errors.New("unexpected file extension")

Functions

func AnnotationTypeScopeResolver

func AnnotationTypeScopeResolver(annotationsRepo annotations.Repository) (string, accesscontrol.ScopeAttributeResolver)

AnnotationTypeScopeResolver provides an ScopeAttributeResolver able to resolve annotation types. Scope "annotations:id:<id>" will be translated to "annotations:type:<type>, where <type> is the type of annotation with id <id>.

func BasicAuthenticatedRequest

func BasicAuthenticatedRequest(req *http.Request, expectedUser, expectedPass string) bool

BasicAuthenticatedRequest parses the provided HTTP request for basic authentication credentials and returns true if the provided credentials match the expected username and password. Returns false if the request is unauthenticated. Uses constant-time comparison in order to mitigate timing attacks.

func GenStateString

func GenStateString() (string, error)

func GrafanaJavascriptAgentLogMessageHandler

func GrafanaJavascriptAgentLogMessageHandler(store *frontendlogging.SourceMapStore) frontendLogMessageHandler

func NewFakePluginInstaller

func NewFakePluginInstaller() *fakePluginInstaller

func NewFrontendLogMessageHandler

func NewFrontendLogMessageHandler(store *frontendlogging.SourceMapStore) frontendLogMessageHandler

* @deprecated will be removed in the next major version

func ReverseProxyGnetReq

func ReverseProxyGnetReq(logger log.Logger, proxyPath string, version string, grafanaComAPIUrl string) *httputil.ReverseProxy

func ValidateAndNormalizeEmail

func ValidateAndNormalizeEmail(email string) (string, error)

Types

type AcceptedResponse

type AcceptedResponse GenericError

AcceptedResponse

swagger:response acceptedResponse

type AddAPIkeyParams

type AddAPIkeyParams struct {
	// in:body
	// required:true
	Body apikey.AddCommand
}

swagger:parameters addAPIkey

type AddDataSourceParams

type AddDataSourceParams struct {
	// in:body
	// required:true
	Body datasources.AddDataSourceCommand
}

swagger:parameters addDataSource

type AddInviteParams

type AddInviteParams struct {
	// in:body
	// required:true
	Body dtos.AddInviteForm `json:"body"`
}

swagger:parameters addOrgInvite

type AddOrgUserParams

type AddOrgUserParams struct {
	// in:body
	// required:true
	Body org.AddOrgUserCommand `json:"body"`
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters addOrgUser

type AddOrgUserToCurrentOrgParams

type AddOrgUserToCurrentOrgParams struct {
	// in:body
	// required:true
	Body org.AddOrgUserCommand `json:"body"`
}

swagger:parameters addOrgUserToCurrentOrg

type AddTeamMemberParams

type AddTeamMemberParams struct {
	// in:body
	// required:true
	Body team.AddTeamMemberCommand `json:"body"`
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters addTeamMember

type AdminCreateUserParams

type AdminCreateUserParams struct {
	// in:body
	// required:true
	Body dtos.AdminCreateUserForm `json:"body"`
}

swagger:parameters adminCreateUser

type AdminCreateUserResponseResponse

type AdminCreateUserResponseResponse struct {
	// in:body
	Body user.AdminCreateUserResponse `json:"body"`
}

swagger:response adminCreateUserResponse

type AdminDeleteUserParams

type AdminDeleteUserParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminDeleteUser

type AdminDisableUserParams

type AdminDisableUserParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminDisableUser

type AdminEnableUserParams

type AdminEnableUserParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminEnableUser

type AdminGetUserAuthTokensParams

type AdminGetUserAuthTokensParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminGetUserAuthTokens

type AdminGetUserAuthTokensResponse

type AdminGetUserAuthTokensResponse struct {
	// in:body
	Body []*auth.UserToken `json:"body"`
}

swagger:response adminGetUserAuthTokensResponse

type AdminLogoutUserParams

type AdminLogoutUserParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminLogoutUser

type AdminRevokeUserAuthTokenParams

type AdminRevokeUserAuthTokenParams struct {
	// in:body
	// required:true
	Body auth.RevokeAuthTokenCmd `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminRevokeUserAuthToken

type AdminUpdateUserPasswordParams

type AdminUpdateUserPasswordParams struct {
	// in:body
	// required:true
	Body dtos.AdminUpdateUserPasswordForm `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminUpdateUserPassword

type AdminUpdateUserPermissionsParams

type AdminUpdateUserPermissionsParams struct {
	// in:body
	// required:true
	Body dtos.AdminUpdateUserPermissionsForm `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters adminUpdateUserPermissions

type AnnotationError

type AnnotationError struct {
	// contains filtered or unexported fields
}

func (*AnnotationError) Error

func (e *AnnotationError) Error() string

type AvailablePlugins

type AvailablePlugins map[plugins.Type]map[string]*availablePluginDTO

AvailablePlugins represents a mapping from plugin types (panel, data source, etc.) to plugin IDs to plugins For example ["panel"] -> ["piechart"] -> {pie chart plugin DTO}

func (AvailablePlugins) Get

func (ap AvailablePlugins) Get(pluginType plugins.Type, pluginID string) (*availablePluginDTO, bool)

type BadRequestError

type BadRequestError GenericError

BadRequestError is returned when the request is invalid and it cannot be processed.

swagger:response badRequestError

type CalcDashboardDiffParams

type CalcDashboardDiffParams struct {
	// in:body
	// required:true
	Body struct {
		Base dtos.CalculateDiffTarget `json:"base" binding:"Required"`
		New  dtos.CalculateDiffTarget `json:"new" binding:"Required"`
		// The type of diff to return
		// Description:
		// * `basic`
		// * `json`
		// Enum: basic,json
		DiffType string `json:"diffType" binding:"Required"`
	}
}

swagger:parameters calculateDashboardDiff

type CalculateDashboardDiffResponse

type CalculateDashboardDiffResponse struct {
	// in: body
	Body []byte `json:"body"`
}

swagger:response calculateDashboardDiffResponse

type CallDatasourceResourceByIDParams

type CallDatasourceResourceByIDParams struct {
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters callDatasourceResourceByID

type CallDatasourceResourceWithUIDParams

type CallDatasourceResourceWithUIDParams struct {
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters callDatasourceResourceWithUID

type ChangeUserPasswordParams

type ChangeUserPasswordParams struct {
	// To change the email, name, login, theme, provide another one.
	// in:body
	// required:true
	Body user.ChangeUserPasswordCommand `json:"body"`
}

swagger:parameters changeUserPassword

type CheckDatasourceHealthByIDParams

type CheckDatasourceHealthByIDParams struct {
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters checkDatasourceHealthByID

type CheckDatasourceHealthWithUIDParams

type CheckDatasourceHealthWithUIDParams struct {
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters checkDatasourceHealthWithUID

type ConflictError

type ConflictError GenericError

ConflictError

swagger:response conflictError

type CreateAlertNotificationChannelParams

type CreateAlertNotificationChannelParams struct {
	// in:body
	// required:true
	Body alertmodels.CreateAlertNotificationCommand `json:"body"`
}

swagger:parameters createAlertNotificationChannel

type CreateExternalSnapshotResponse

type CreateExternalSnapshotResponse struct {
	Key       string `json:"key"`
	DeleteKey string `json:"deleteKey"`
	Url       string `json:"url"`
	DeleteUrl string `json:"deleteUrl"`
}

type CreateFolderParams

type CreateFolderParams struct {
	// in:body
	// required:true
	Body folder.CreateFolderCommand `json:"body"`
}

swagger:parameters createFolder

type CreateOrUpdateDatasourceResponse

type CreateOrUpdateDatasourceResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the new data source.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Name of the new data source.
		// required: true
		// example: My Data source
		Name string `json:"name"`

		// Message Message of the deleted dashboard.
		// required: true
		// example: Data source added
		Message string `json:"message"`

		// Datasource properties
		// required: true
		Datasource dtos.DataSource `json:"datasource"`
	} `json:"body"`
}

swagger:response createOrUpdateDatasourceResponse

type CreateOrgParams

type CreateOrgParams struct {
	// in:body
	// required:true
	Body org.CreateOrgCommand `json:"body"`
}

swagger:parameters createOrg

type CreateOrgResponse

type CreateOrgResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the created org.
		// required: true
		// example: 65
		OrgID int64 `json:"orgId"`

		// Message Message of the created org.
		// required: true
		// example: Data source added
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response createOrgResponse

type CreatePlaylistParams

type CreatePlaylistParams struct {
	// in:body
	// required:true
	Body playlist.CreatePlaylistCommand
}

swagger:parameters createPlaylist

type CreatePlaylistResponse

type CreatePlaylistResponse struct {
	// The response message
	// in: body
	Body *playlist.Playlist `json:"body"`
}

swagger:response createPlaylistResponse

type CreateSnapshotParams

type CreateSnapshotParams struct {
	// in:body
	// required:true
	Body dashboardsnapshots.CreateDashboardSnapshotCommand `json:"body"`
}

swagger:parameters createDashboardSnapshot

type CreateSnapshotResponse

type CreateSnapshotResponse struct {
	// in:body
	Body struct {
		// Unique key
		Key string `json:"key"`
		// Unique key used to delete the snapshot. It is different from the key so that only the creator can delete the snapshot.
		DeleteKey string `json:"deleteKey"`
		URL       string `json:"url"`
		DeleteUrl string `json:"deleteUrl"`
		// Snapshot id
		ID int64 `json:"id"`
	} `json:"body"`
}

swagger:response createDashboardSnapshotResponse

type CreateTeamParams

type CreateTeamParams struct {
	// in:body
	// required:true
	Body team.CreateTeamCommand `json:"body"`
}

swagger:parameters createTeam

type CreateTeamResponse

type CreateTeamResponse struct {
	// The response message
	// in: body
	Body struct {
		TeamId  int64  `json:"teamId"`
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response createTeamResponse

type DashboardResponse

type DashboardResponse struct {
	// The response message
	// in: body
	Body dtos.DashboardFullWithMeta `json:"body"`
}

swagger:response dashboardResponse

type DashboardVersionResponse

type DashboardVersionResponse struct {
	// in: body
	Body *dashver.DashboardVersionMeta `json:"body"`
}

swagger:response dashboardVersionResponse

type DashboardVersionsResponse

type DashboardVersionsResponse struct {
	// in: body
	Body []dashver.DashboardVersionMeta `json:"body"`
}

swagger:response dashboardVersionsResponse

type DashboardsTagsResponse

type DashboardsTagsResponse struct {
	// in: body
	Body []*dashboards.DashboardTagCloudItem `json:"body"`
}

swagger:response getDashboardsTagsResponse

type DatasourceProxyDELETEByUIDcallsParams

type DatasourceProxyDELETEByUIDcallsParams struct {
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters datasourceProxyDELETEByUIDcalls

type DatasourceProxyDELETEcallsParams

type DatasourceProxyDELETEcallsParams struct {
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters datasourceProxyDELETEcalls

type DatasourceProxyGETByUIDcallsParams

type DatasourceProxyGETByUIDcallsParams struct {
	// in:path
	// required:true
	DatasourceProxyRoute string `json:"datasource_proxy_route"`
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters datasourceProxyGETByUIDcalls

type DatasourceProxyGETcallsParams

type DatasourceProxyGETcallsParams struct {
	// in:path
	// required:true
	DatasourceProxyRoute string `json:"datasource_proxy_route"`
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters datasourceProxyGETcalls

type DatasourceProxyPOSTByUIDcallsParams

type DatasourceProxyPOSTByUIDcallsParams struct {
	// in:body
	// required:true
	DatasourceProxyParam interface{}
	// in:path
	// required:true
	DatasourceProxyRoute string `json:"datasource_proxy_route"`
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters datasourceProxyPOSTByUIDcalls

type DatasourceProxyPOSTcallsParams

type DatasourceProxyPOSTcallsParams struct {
	// in:body
	// required:true
	DatasourceProxyParam interface{}
	// in:path
	// required:true
	DatasourceProxyRoute string `json:"datasource_proxy_route"`
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters datasourceProxyPOSTcalls

type DatasourceProxyRouteParam

type DatasourceProxyRouteParam struct {
	// in:path
	// required:true
	DatasourceProxyRoute string `json:"datasource_proxy_route"`
}

swagger:parameters datasourceProxyDELETEcalls swagger:parameters datasourceProxyDELETEByUIDcalls swagger:parameters callDatasourceResourceWithUID callDatasourceResourceByID

type DeleteAPIkeyParams

type DeleteAPIkeyParams struct {
	// in:path
	// required:true
	ID int64 `json:"id"`
}

swagger:parameters deleteAPIkey

type DeleteAlertNotificationChannelByUIDParams

type DeleteAlertNotificationChannelByUIDParams struct {
	// in:path
	// required:true
	NotificationUID string `json:"notification_channel_uid"`
}

swagger:parameters deleteAlertNotificationChannelByUID

type DeleteAlertNotificationChannelParams

type DeleteAlertNotificationChannelParams struct {
	// in:path
	// required:true
	NotificationID int64 `json:"notification_channel_id"`
}

swagger:parameters deleteAlertNotificationChannel

type DeleteAlertNotificationChannelResponse

type DeleteAlertNotificationChannelResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the deleted notification channel.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Message Message of the deleted notificatiton channel.
		// required: true
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response deleteAlertNotificationChannelResponse

type DeleteAnnotationByIDParams

type DeleteAnnotationByIDParams struct {
	// in:path
	// required:true
	AnnotationID string `json:"annotation_id"`
}

swagger:parameters deleteAnnotationByID

type DeleteDashboardByUIDParams

type DeleteDashboardByUIDParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters deleteDashboardByUID

type DeleteDashboardResponse

type DeleteDashboardResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the deleted dashboard.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Title Title of the deleted dashboard.
		// required: true
		// example: My Dashboard
		Title string `json:"title"`

		// Message Message of the deleted dashboard.
		// required: true
		// example: Dashboard My Dashboard deleted
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response deleteDashboardResponse

type DeleteDashboardSnapshotParams

type DeleteDashboardSnapshotParams struct {
	// in:path
	Key string `json:"key"`
}

swagger:parameters deleteDashboardSnapshot

type DeleteDataSourceByIDParams

type DeleteDataSourceByIDParams struct {
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters deleteDataSourceByID

type DeleteDataSourceByNameParams

type DeleteDataSourceByNameParams struct {
	// in:path
	// required:true
	DatasourceName string `json:"name"`
}

swagger:parameters deleteDataSourceByName

type DeleteDataSourceByNameResponse

type DeleteDataSourceByNameResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the deleted data source.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Message Message of the deleted dashboard.
		// required: true
		// example: Dashboard My Dashboard deleted
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response deleteDataSourceByNameResponse

type DeleteDataSourceByUIDParams

type DeleteDataSourceByUIDParams struct {
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters deleteDataSourceByUID

type DeleteFolderParams

type DeleteFolderParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
	// If `true` any Grafana 8 Alerts under this folder will be deleted.
	// Set to `false` so that the request will fail if the folder contains any Grafana 8 Alerts.
	// in:query
	// required:false
	// default:false
	ForceDeleteRules bool `json:"forceDeleteRules"`
}

swagger:parameters deleteFolder

type DeleteFolderResponse

type DeleteFolderResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the deleted folder.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Title of the deleted folder.
		// required: true
		// example: My Folder
		Title string `json:"title"`

		// Message Message of the deleted folder.
		// required: true
		// example: Folder My Folder deleted
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response deleteFolderResponse

type DeleteOrgByIDParams

type DeleteOrgByIDParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters deleteOrgByID

type DeletePlaylistParams

type DeletePlaylistParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters deletePlaylist

type DeleteSnapshotByDeleteKeyParams

type DeleteSnapshotByDeleteKeyParams struct {
	// in:path
	DeleteKey string `json:"deleteKey"`
}

swagger:parameters deleteDashboardSnapshotByDeleteKey

type DeleteTeamByIDParams

type DeleteTeamByIDParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters deleteTeamByID

type ErrorResponseBody

type ErrorResponseBody struct {
	// a human readable version of the error
	// required: true
	Message string `json:"message"`

	// Error An optional detailed description of the actual error. Only included if running in developer mode.
	Error string `json:"error"`

	// Status An optional status to denote the cause of the error.
	//
	// For example, a 412 Precondition Failed error may include additional information of why that error happened.
	Status string `json:"status"`
}

type FolderResponse

type FolderResponse struct {
	// The response message
	// in: body
	Body dtos.Folder `json:"body"`
}

swagger:response folderResponse

type ForbiddenError

type ForbiddenError GenericError

ForbiddenError is returned if the user/token has insufficient permissions to access the requested resource.

swagger:response forbiddenError

type GenericError

type GenericError struct {
	// The response message
	// in: body
	Body ErrorResponseBody `json:"body"`
}

A GenericError is the default error message that is generated. For certain status codes there are more appropriate error structures.

swagger:response genericError

type GetAPIkeyResponse

type GetAPIkeyResponse struct {
	// The response message
	// in: body
	Body []*dtos.ApiKeyDTO `json:"body"`
}

swagger:response getAPIkeyResponse

type GetAPIkeysParams

type GetAPIkeysParams struct {
	// Show expired keys
	// in:query
	// required:false
	// default:false
	IncludeExpired bool `json:"includeExpired"`
}

swagger:parameters getAPIkeys

type GetAlertByIDParams

type GetAlertByIDParams struct {
	// in:path
	// required:true
	AlertID string `json:"alert_id"`
}

swagger:parameters getAlertByID

type GetAlertNotificationChannelByIDParams

type GetAlertNotificationChannelByIDParams struct {
	// in:path
	// required:true
	NotificationID int64 `json:"notification_channel_id"`
}

swagger:parameters getAlertNotificationChannelByID

type GetAlertNotificationChannelByUIDParams

type GetAlertNotificationChannelByUIDParams struct {
	// in:path
	// required:true
	NotificationUID string `json:"notification_channel_uid"`
}

swagger:parameters getAlertNotificationChannelByUID

type GetAlertNotificationChannelResponse

type GetAlertNotificationChannelResponse struct {
	// The response message
	// in: body
	Body *dtos.AlertNotification `json:"body"`
}

swagger:response getAlertNotificationChannelResponse

type GetAlertNotificationChannelsResponse

type GetAlertNotificationChannelsResponse struct {
	// The response message
	// in: body
	Body []*dtos.AlertNotification `json:"body"`
}

swagger:response getAlertNotificationChannelsResponse

type GetAlertResponse

type GetAlertResponse struct {
	// The response message
	// in: body
	Body *alertmodels.Alert `json:"body"`
}

swagger:response getAlertResponse

type GetAlertsParams

type GetAlertsParams struct {
	// Limit response to alerts in specified dashboard(s). You can specify multiple dashboards.
	// in:query
	// required:false
	DashboardID []string `json:"dashboardId"`
	//  Limit response to alert for a specified panel on a dashboard.
	// in:query
	// required:false
	PanelID int64 `json:"panelId"`
	// Limit response to alerts having a name like this value.
	// in:query
	// required: false
	Query string `json:"query"`
	// Return alerts with one or more of the following alert states
	// in:query
	// required:false
	// Description:
	// * `all`
	// * `no_data`
	// * `paused`
	// * `alerting`
	// * `ok`
	// * `pending`
	// * `unknown`
	// enum: all,no_data,paused,alerting,ok,pending,unknown
	State string `json:"state"`
	// Limit response to X number of alerts.
	// in:query
	// required:false
	Limit int64 `json:"limit"`
	// Limit response to alerts of dashboards in specified folder(s). You can specify multiple folders
	// in:query
	// required:false
	// type array
	// collectionFormat: multi
	FolderID []string `json:"folderId"`
	// Limit response to alerts having a dashboard name like this value./ Limit response to alerts having a dashboard name like this value.
	// in:query
	// required:false
	DashboardQuery string `json:"dashboardQuery"`
	// Limit response to alerts of dashboards with specified tags. To do an “AND” filtering with multiple tags, specify the tags parameter multiple times
	// in:query
	// required:false
	// type: array
	// collectionFormat: multi
	DashboardTag []string `json:"dashboardTag"`
}

swagger:parameters getAlerts

type GetAlertsResponse

type GetAlertsResponse struct {
	// The response message
	// in: body
	Body []*alertmodels.AlertListItemDTO `json:"body"`
}

swagger:response getAlertsResponse

type GetAnnotationByIDParams

type GetAnnotationByIDParams struct {
	// in:path
	// required:true
	AnnotationID string `json:"annotation_id"`
}

swagger:parameters getAnnotationByID

type GetAnnotationByIDResponse

type GetAnnotationByIDResponse struct {
	// The response message
	// in: body
	Body *annotations.ItemDTO `json:"body"`
}

swagger:response getAnnotationByIDResponse

type GetAnnotationTagsParams

type GetAnnotationTagsParams struct {
	// Tag is a string that you can use to filter tags.
	// in:query
	// required:false
	Tag string `json:"tag"`
	// Max limit for results returned.
	// in:query
	// required:false
	// default: 100
	Limit string `json:"limit"`
}

swagger:parameters getAnnotationTags

type GetAnnotationTagsResponse

type GetAnnotationTagsResponse struct {
	// The response message
	// in: body
	Body annotations.GetAnnotationTagsResponse `json:"body"`
}

swagger:response getAnnotationTagsResponse

type GetAnnotationsParams

type GetAnnotationsParams struct {
	// Find annotations created after specific epoch datetime in milliseconds.
	// in:query
	// required:false
	From int64 `json:"from"`
	// Find annotations created before specific epoch datetime in milliseconds.
	// in:query
	// required:false
	To int64 `json:"to"`
	// Limit response to annotations created by specific user.
	// in:query
	// required:false
	UserID int64 `json:"userId"`
	// Find annotations for a specified alert.
	// in:query
	// required:false
	AlertID int64 `json:"alertId"`
	// Find annotations that are scoped to a specific dashboard
	// in:query
	// required:false
	DashboardID int64 `json:"dashboardId"`
	// Find annotations that are scoped to a specific dashboard
	// in:query
	// required:false
	DashboardUID string `json:"dashboardUID"`
	// Find annotations that are scoped to a specific panel
	// in:query
	// required:false
	PanelID int64 `json:"panelId"`
	// Max limit for results returned.
	// in:query
	// required:false
	Limit int64 `json:"limit"`
	// Use this to filter organization annotations. Organization annotations are annotations from an annotation data source that are not connected specifically to a dashboard or panel. You can filter by multiple tags.
	// in:query
	// required:false
	// type: array
	// collectionFormat: multi
	Tags []string `json:"tags"`
	// Return alerts or user created annotations
	// in:query
	// required:false
	// Description:
	// * `alert`
	// * `annotation`
	// enum: alert,annotation
	Type string `json:"type"`
	// Match any or all tags
	// in:query
	// required:false
	MatchAny bool `json:"matchAny"`
}

swagger:parameters getAnnotations

type GetAnnotationsResponse

type GetAnnotationsResponse struct {
	// The response message
	// in: body
	Body []*annotations.ItemDTO `json:"body"`
}

swagger:response getAnnotationsResponse

type GetCurrentOrgResponse

type GetCurrentOrgResponse struct {
	// The response message
	// in: body
	Body org.OrgDetailsDTO `json:"body"`
}

swagger:response getCurrentOrgResponse

type GetDashboardByUIDParams

type GetDashboardByUIDParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getDashboardByUID

type GetDashboardPermissionsListByIDParams

type GetDashboardPermissionsListByIDParams struct {
	// in:path
	DashboardID int64
}

swagger:parameters getDashboardPermissionsListByID

type GetDashboardPermissionsListByUIDParams

type GetDashboardPermissionsListByUIDParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getDashboardPermissionsListByUID

type GetDashboardPermissionsResponse

type GetDashboardPermissionsResponse struct {
	// in: body
	Body []*dashboards.DashboardACLInfoDTO `json:"body"`
}

swagger:response getDashboardPermissionsListResponse

type GetDashboardSnapshotParams

type GetDashboardSnapshotParams struct {
	// in:path
	Key string `json:"key"`
}

swagger:parameters getDashboardSnapshot

type GetDashboardSnapshotResponse

type GetDashboardSnapshotResponse DashboardResponse

swagger:response getDashboardSnapshotResponse

type GetDashboardStatesParams

type GetDashboardStatesParams struct {
	// in:query
	// required: true
	DashboardID int64 `json:"dashboardId"`
}

swagger:parameters getDashboardStates

type GetDashboardStatesResponse

type GetDashboardStatesResponse struct {
	// The response message
	// in: body
	Body []*alertmodels.AlertStateInfoDTO `json:"body"`
}

swagger:response getDashboardStatesResponse

type GetDashboardVersionByIDParams

type GetDashboardVersionByIDParams struct {
	// in:path
	DashboardID int64
	// in:path
	DashboardVersionID int64
}

swagger:parameters getDashboardVersionByID

type GetDashboardVersionByUIDParams

type GetDashboardVersionByUIDParams struct {
	// in:path
	DashboardVersionID int64
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getDashboardVersionByUID

type GetDashboardVersionsByIDParams

type GetDashboardVersionsByIDParams struct {
	// in:path
	DashboardID int64
}

swagger:parameters getDashboardVersionsByID

type GetDashboardVersionsByUIDParams

type GetDashboardVersionsByUIDParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getDashboardVersionsByUID

type GetDashboardVersionsParams

type GetDashboardVersionsParams struct {
	// Maximum number of results to return
	// in:query
	// required:false
	// default:0
	Limit int `json:"limit"`

	// Version to start from when returning queries
	// in:query
	// required:false
	// default:0
	Start int `json:"start"`
}

swagger:parameters getDashboardVersions getDashboardVersionsByUID

type GetDataSourceByIDParams

type GetDataSourceByIDParams struct {
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters getDataSourceByID

type GetDataSourceByNameParams

type GetDataSourceByNameParams struct {
	// in:path
	// required:true
	DatasourceName string `json:"name"`
}

swagger:parameters getDataSourceByName

type GetDataSourceByUIDParams

type GetDataSourceByUIDParams struct {
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters getDataSourceByUID

type GetDataSourceIDresponse

type GetDataSourceIDresponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the data source.
		// required: true
		// example: 65
		ID int64 `json:"id"`
	} `json:"body"`
}

swagger:response getDataSourceIDResponse

type GetDataSourceIdByNameParams

type GetDataSourceIdByNameParams struct {
	// in:path
	// required:true
	DatasourceName string `json:"name"`
}

swagger:parameters getDataSourceIdByName

type GetDataSourceResponse

type GetDataSourceResponse struct {
	// The response message
	// in: body
	Body dtos.DataSource `json:"body"`
}

swagger:response getDataSourceResponse

type GetDataSourcesResponse

type GetDataSourcesResponse struct {
	// The response message
	// in: body
	Body dtos.DataSourceList `json:"body"`
}

swagger:response getDataSourcesResponse

type GetFolderByIDParams

type GetFolderByIDParams struct {
	// in:path
	// required:true
	FolderID int64 `json:"folder_id"`
}

swagger:parameters getFolderByID

type GetFolderByUIDParams

type GetFolderByUIDParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
}

swagger:parameters getFolderByUID

type GetFolderPermissionListParams

type GetFolderPermissionListParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
}

swagger:parameters getFolderPermissionList

type GetFolderPermissionsResponse

type GetFolderPermissionsResponse struct {
	// in: body
	Body []*dashboards.DashboardACLInfoDTO `json:"body"`
}

swagger:response getFolderPermissionListResponse

type GetFoldersParams

type GetFoldersParams struct {
	// Limit the maximum number of folders to return
	// in:query
	// required:false
	// default:1000
	Limit int64 `json:"limit"`
	// Page index for starting fetching folders
	// in:query
	// required:false
	// default:1
	Page int64 `json:"page"`
	// The parent folder UID
	// in:query
	// required:false
	ParentUID string `json:"parentUid"`
}

swagger:parameters getFolders

type GetFoldersResponse

type GetFoldersResponse struct {
	// The response message
	// in: body
	Body []dtos.FolderSearchHit `json:"body"`
}

swagger:response getFoldersResponse

type GetHomeDashboardResponse

type GetHomeDashboardResponse struct {
	// in: body
	Body GetHomeDashboardResponseBody `json:"body"`
}

swagger:response getHomeDashboardResponse

type GetHomeDashboardResponseBody

type GetHomeDashboardResponseBody struct {
	// swagger:allOf
	// required: false
	dtos.DashboardFullWithMeta

	// swagger:allOf
	// required: false
	dtos.DashboardRedirect
}

Get home dashboard response. swagger:model GetHomeDashboardResponse

type GetOrgByIDParams

type GetOrgByIDParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters getOrgByID

type GetOrgByIDResponse

type GetOrgByIDResponse struct {
	// The response message
	// in: body
	Body org.OrgDetailsDTO `json:"body"`
}

swagger:response getOrgByIDResponse

type GetOrgByNameParams

type GetOrgByNameParams struct {
	// in:path
	// required:true
	OrgName string `json:"org_name"`
}

swagger:parameters getOrgByName

type GetOrgByNameResponse

type GetOrgByNameResponse struct {
	// The response message
	// in: body
	Body org.OrgDetailsDTO `json:"body"`
}

swagger:response getOrgByNameResponse

type GetOrgQuotaParams

type GetOrgQuotaParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters getOrgQuota

type GetOrgUsersForCurrentOrgLookupResponse

type GetOrgUsersForCurrentOrgLookupResponse struct {
	// The response message
	// in: body
	Body []*dtos.UserLookupDTO `json:"body"`
}

swagger:response getOrgUsersForCurrentOrgLookupResponse

type GetOrgUsersForCurrentOrgResponse

type GetOrgUsersForCurrentOrgResponse struct {
	// The response message
	// in: body
	Body []*org.OrgUserDTO `json:"body"`
}

swagger:response getOrgUsersForCurrentOrgResponse

type GetOrgUsersParams

type GetOrgUsersParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters getOrgUsers

type GetOrgUsersResponse

type GetOrgUsersResponse struct {
	// The response message/
	// in: body
	Body []*org.OrgUserDTO `json:"body"`
}

swagger:response getOrgUsersResponse

type GetPendingOrgInvitesResponse

type GetPendingOrgInvitesResponse struct {
	// The response message
	// in: body
	Body []*tempuser.TempUserDTO `json:"body"`
}

swagger:response getPendingOrgInvitesResponse

type GetPlaylistDashboardsParams

type GetPlaylistDashboardsParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getPlaylistDashboards

type GetPlaylistDashboardsResponse

type GetPlaylistDashboardsResponse struct {
	// The response message
	// in: body
	Body dtos.PlaylistDashboardsSlice `json:"body"`
}

swagger:response getPlaylistDashboardsResponse

type GetPlaylistItemsParams

type GetPlaylistItemsParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getPlaylistItems

type GetPlaylistItemsResponse

type GetPlaylistItemsResponse struct {
	// The response message
	// in: body
	Body []playlist.PlaylistItemDTO `json:"body"`
}

swagger:response getPlaylistItemsResponse

type GetPlaylistParams

type GetPlaylistParams struct {
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters getPlaylist

type GetPlaylistResponse

type GetPlaylistResponse struct {
	// The response message
	// in: body
	Body *playlist.PlaylistDTO `json:"body"`
}

swagger:response getPlaylistResponse

type GetPreferencesResponse

type GetPreferencesResponse struct {
	// in:body
	Body preferences.Preferences `json:"body"`
}

swagger:response getPreferencesResponse

type GetQuotaResponseResponse

type GetQuotaResponseResponse struct {
	// in:body
	Body []*quota.QuotaDTO `json:"body"`
}

swagger:response getQuotaResponse

type GetSettingsResponse

type GetSettingsResponse struct {
	// in:body
	Body setting.SettingsBag `json:"body"`
}

swagger:response adminGetSettingsResponse

type GetSharingOptionsResponse

type GetSharingOptionsResponse struct {
	// in:body
	Body struct {
		ExternalSnapshotURL  string `json:"externalSnapshotURL"`
		ExternalSnapshotName string `json:"externalSnapshotName"`
		ExternalEnabled      bool   `json:"externalEnabled"`
	} `json:"body"`
}

swagger:response getSharingOptionsResponse

type GetSignedInUserOrgListResponse

type GetSignedInUserOrgListResponse struct {
	// The response message
	// in: body
	Body []*org.UserOrgDTO `json:"body"`
}

swagger:response getSignedInUserOrgListResponse

type GetSignedInUserTeamListResponse

type GetSignedInUserTeamListResponse struct {
	// The response message
	// in: body
	Body []*team.TeamDTO `json:"body"`
}

swagger:response getSignedInUserTeamListResponse

type GetSnapshotsParams

type GetSnapshotsParams struct {
	// Search Query
	// in:query
	Query string `json:"query"`
	// Limit the number of returned results
	// in:query
	// default:1000
	Limit int64 `json:"limit"`
}

swagger:parameters searchDashboardSnapshots

type GetStatsResponse

type GetStatsResponse struct {
	// in:body
	Body stats.AdminStats `json:"body"`
}

swagger:response adminGetStatsResponse

type GetTeamByIDParams

type GetTeamByIDParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters getTeamByID

type GetTeamByIDResponse

type GetTeamByIDResponse struct {
	// The response message
	// in: body
	Body *team.TeamDTO `json:"body"`
}

swagger:response getTeamByIDResponse

type GetTeamMembersParams

type GetTeamMembersParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters getTeamMembers

type GetTeamMembersResponse

type GetTeamMembersResponse struct {
	// The response message
	// in: body
	Body []*team.TeamMemberDTO `json:"body"`
}

swagger:response getTeamMembersResponse

type GetTeamPreferencesParams

type GetTeamPreferencesParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters getTeamPreferences

type GetUserAuthTokensResponse

type GetUserAuthTokensResponse struct {
	// in:body
	Body []*auth.UserToken `json:"body"`
}

swagger:response getUserAuthTokensResponse

type GetUserByIDParams

type GetUserByIDParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters getUserByID

type GetUserByLoginOrEmailParams

type GetUserByLoginOrEmailParams struct {
	// loginOrEmail of the user
	// in:query
	// required:true
	LoginOrEmail string `json:"loginOrEmail"`
}

swagger:parameters getUserByLoginOrEmail

type GetUserOrgListParams

type GetUserOrgListParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters getUserOrgList

type GetUserOrgListResponse

type GetUserOrgListResponse struct {
	// The response message
	// in: body
	Body []*org.UserOrgDTO `json:"body"`
}

swagger:response getUserOrgListResponse

type GetUserQuotaParams

type GetUserQuotaParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters getUserQuota

type GetUserTeamsParams

type GetUserTeamsParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters getUserTeams

type GetUserTeamsResponse

type GetUserTeamsResponse struct {
	// The response message
	// in: body
	Body []*team.TeamDTO `json:"body"`
}

swagger:response getUserTeamsResponse

type HTTPServer

type HTTPServer struct {
	PluginContextProvider *plugincontext.Provider
	RouteRegister         routing.RouteRegister
	RenderService         rendering.Service
	Cfg                   *setting.Cfg
	Features              *featuremgmt.FeatureManager
	SettingsProvider      setting.Provider
	HooksService          *hooks.HooksService

	CacheService           *localcache.CacheService
	DataSourceCache        datasources.CacheService
	AuthTokenService       auth.UserTokenService
	QuotaService           quota.Service
	RemoteCacheService     *remotecache.RemoteCache
	ProvisioningService    provisioning.ProvisioningService
	Login                  login.Service
	License                licensing.Licensing
	AccessControl          accesscontrol.AccessControl
	DataProxy              *datasourceproxy.DataSourceProxyService
	PluginRequestValidator validations.PluginRequestValidator

	SearchService       search.Service
	ShortURLService     shorturls.Service
	QueryHistoryService queryhistory.Service
	CorrelationsService correlations.Service
	Live                *live.GrafanaLive
	LivePushGateway     *pushhttp.Gateway
	ThumbService        thumbs.Service
	StorageService      store.StorageService

	SearchV2HTTPService   searchV2.SearchHTTPService
	ContextHandler        *contexthandler.ContextHandler
	LoggerMiddleware      loggermw.Logger
	SQLStore              db.DB
	AlertEngine           *alerting.AlertEngine
	AlertNG               *ngalert.AlertNG
	LibraryPanelService   librarypanels.Service
	LibraryElementService libraryelements.Service
	SocialService         social.Service
	Listener              net.Listener
	EncryptionService     encryption.Internal
	SecretsService        secrets.Service

	DataSourcesService datasources.DataSourceService

	NotificationService *notifications.NotificationService
	DashboardService    dashboards.DashboardService

	DatasourcePermissionsService permissions.DatasourcePermissionsService
	AlertNotificationService     *alerting.AlertNotificationService

	PluginSettings    pluginSettings.Service
	AvatarCacheServer *avatar.AvatarCacheServer

	Csrf csrf.Service

	PublicDashboardsApi *publicdashboardsApi.Api

	Kinds *corekind.Base
	// contains filtered or unexported fields
}

func ProvideHTTPServer

func ProvideHTTPServer(opts ServerOptions, cfg *setting.Cfg, routeRegister routing.RouteRegister, bus bus.Bus,
	renderService rendering.Service, licensing licensing.Licensing, hooksService *hooks.HooksService,
	cacheService *localcache.CacheService, sqlStore *sqlstore.SQLStore, alertEngine *alerting.AlertEngine,
	pluginRequestValidator validations.PluginRequestValidator, pluginStaticRouteResolver plugins.StaticRouteResolver,
	pluginDashboardService plugindashboards.Service, pluginStore plugins.Store, pluginClient plugins.Client,
	pluginErrorResolver plugins.ErrorResolver, pluginInstaller plugins.Installer, settingsProvider setting.Provider,
	dataSourceCache datasources.CacheService, userTokenService auth.UserTokenService,
	cleanUpService *cleanup.CleanUpService, shortURLService shorturls.Service, queryHistoryService queryhistory.Service, correlationsService correlations.Service,
	thumbService thumbs.Service, remoteCache *remotecache.RemoteCache, provisioningService provisioning.ProvisioningService,
	loginService login.Service, authenticator loginpkg.Authenticator, accessControl accesscontrol.AccessControl,
	dataSourceProxy *datasourceproxy.DataSourceProxyService, searchService *search.SearchService,
	live *live.GrafanaLive, livePushGateway *pushhttp.Gateway, plugCtxProvider *plugincontext.Provider,
	contextHandler *contexthandler.ContextHandler, loggerMiddleware loggermw.Logger, features *featuremgmt.FeatureManager,
	alertNG *ngalert.AlertNG, libraryPanelService librarypanels.Service, libraryElementService libraryelements.Service,
	quotaService quota.Service, socialService social.Service, tracer tracing.Tracer,
	encryptionService encryption.Internal, grafanaUpdateChecker *updatechecker.GrafanaService,
	pluginsUpdateChecker *updatechecker.PluginsService, searchUsersService searchusers.Service,
	dataSourcesService datasources.DataSourceService, queryDataService query.Service, pluginFileStore plugins.FileStore,
	teamGuardian teamguardian.TeamGuardian, serviceaccountsService serviceaccounts.Service,
	authInfoService login.AuthInfoService, storageService store.StorageService, httpEntityStore httpentitystore.HTTPEntityStore,
	notificationService *notifications.NotificationService, dashboardService dashboards.DashboardService,
	dashboardProvisioningService dashboards.DashboardProvisioningService, folderService folder.Service,
	datasourcePermissionsService permissions.DatasourcePermissionsService, alertNotificationService *alerting.AlertNotificationService,
	dashboardsnapshotsService dashboardsnapshots.Service, pluginSettings pluginSettings.Service,
	avatarCacheServer *avatar.AvatarCacheServer, preferenceService pref.Service,
	teamsPermissionsService accesscontrol.TeamPermissionsService, folderPermissionsService accesscontrol.FolderPermissionsService,
	dashboardPermissionsService accesscontrol.DashboardPermissionsService, dashboardVersionService dashver.Service,
	starService star.Service, csrfService csrf.Service, basekinds *corekind.Base,
	playlistService playlist.Service, apiKeyService apikey.Service, kvStore kvstore.KVStore,
	secretsMigrator secrets.Migrator, secretsPluginManager plugins.SecretsPluginManager, secretsService secrets.Service,
	secretsPluginMigrator spm.SecretMigrationProvider, secretsStore secretsKV.SecretsKVStore,
	publicDashboardsApi *publicdashboardsApi.Api, userService user.Service, tempUserService tempUser.Service,
	loginAttemptService loginAttempt.Service, orgService org.Service, teamService team.Service,
	accesscontrolService accesscontrol.Service, dashboardThumbsService thumbs.DashboardThumbService, navTreeService navtree.Service,
	annotationRepo annotations.Repository, tagService tag.Service, searchv2HTTPService searchV2.SearchHTTPService, oauthTokenService oauthtoken.OAuthTokenService,
	statsService stats.Service, authnService authn.Service, pluginsCDNService *pluginscdn.Service,
	starApi *starApi.API,
) (*HTTPServer, error)

func (*HTTPServer) AddAPIKey

swagger:route POST /auth/keys api_keys addAPIkey

Creates an API key.

Will return details of the created API key.

Responses: 200: postAPIkeyResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) AddDataSource

func (hs *HTTPServer) AddDataSource(c *contextmodel.ReqContext) response.Response

swagger:route POST /datasources datasources addDataSource

Create a data source.

By defining `password` and `basicAuthPassword` under secureJsonData property Grafana encrypts them securely as an encrypted blob in the database. The response then lists the encrypted fields under secureJsonFields.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:create`

Responses: 200: createOrUpdateDatasourceResponse 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) AddMiddleware

func (hs *HTTPServer) AddMiddleware(middleware web.Handler)

func (*HTTPServer) AddNamedMiddleware

func (hs *HTTPServer) AddNamedMiddleware(middleware routing.RegisterNamedMiddleware)

func (*HTTPServer) AddOrgInvite

func (hs *HTTPServer) AddOrgInvite(c *contextmodel.ReqContext) response.Response

swagger:route POST /org/invites org_invites addOrgInvite

Add invite.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 412: SMTPNotEnabledError 500: internalServerError

func (*HTTPServer) AddOrgUser

func (hs *HTTPServer) AddOrgUser(c *contextmodel.ReqContext) response.Response

swagger:route POST /orgs/{org_id}/users orgs addOrgUser

Add a new user to the current organization.

Adds a global user to the current organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:add` with scope `users:*`.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AddOrgUserToCurrentOrg

func (hs *HTTPServer) AddOrgUserToCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route POST /org/users org addOrgUserToCurrentOrg

Add a new user to the current organization.

Adds a global user to the current organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:add` with scope `users:*`.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AddTeamMember

func (hs *HTTPServer) AddTeamMember(c *contextmodel.ReqContext) response.Response

swagger:route POST /teams/{team_id}/members teams addTeamMember

Add Team Member.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminCreateUser

func (hs *HTTPServer) AdminCreateUser(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/users admin_users adminCreateUser

Create new user.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users:create`. Note that OrgId is an optional parameter that can be used to assign a new user to a different organization when `auto_assign_org` is set to `true`.

Security: - basic:

Responses: 200: adminCreateUserResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 412: preconditionFailedError 500: internalServerError

func (*HTTPServer) AdminDeleteAllSecretsManagerPluginSecrets

func (hs *HTTPServer) AdminDeleteAllSecretsManagerPluginSecrets(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminDeleteUser

func (hs *HTTPServer) AdminDeleteUser(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /admin/users/{user_id} admin_users adminDeleteUser

Delete global User.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users:delete` and scope `global.users:*`.

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminDisableUser

func (hs *HTTPServer) AdminDisableUser(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/users/{user_id}/disable admin_users adminDisableUser

Disable user.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users:disable` and scope `global.users:1` (userIDScope).

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminEnableUser

func (hs *HTTPServer) AdminEnableUser(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/users/{user_id}/enable admin_users adminEnableUser

Enable user.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users:enable` and scope `global.users:1` (userIDScope).

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminGetSettings

func (hs *HTTPServer) AdminGetSettings(c *contextmodel.ReqContext) response.Response

swagger:route GET /admin/settings admin adminGetSettings

Fetch settings.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `settings:read` and scopes: `settings:*`, `settings:auth.saml:` and `settings:auth.saml:enabled` (property level).

Security: - basic:

Responses: 200: adminGetSettingsResponse 401: unauthorisedError 403: forbiddenError

func (*HTTPServer) AdminGetStats

func (hs *HTTPServer) AdminGetStats(c *contextmodel.ReqContext) response.Response

swagger:route GET /admin/stats admin adminGetStats

Fetch Grafana Stats.

Only works with Basic Authentication (username and password). See introduction for an explanation. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `server:stats:read`.

Responses: 200: adminGetStatsResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminGetUserAuthTokens

func (hs *HTTPServer) AdminGetUserAuthTokens(c *contextmodel.ReqContext) response.Response

swagger:route GET /admin/users/{user_id}/auth-tokens admin_users adminGetUserAuthTokens

Return a list of all auth tokens (devices) that the user currently have logged in from. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.authtoken:list` and scope `global.users:*`.

Security: - basic:

Responses: 200: adminGetUserAuthTokensResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminLogoutUser

func (hs *HTTPServer) AdminLogoutUser(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/users/{user_id}/logout admin_users adminLogoutUser

Logout user revokes all auth tokens (devices) for the user. User of issued auth tokens (devices) will no longer be logged in and will be required to authenticate again upon next activity. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.logout` and scope `global.users:*`.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminMigrateSecretsFromPlugin

func (hs *HTTPServer) AdminMigrateSecretsFromPlugin(c *contextmodel.ReqContext) response.Response

To migrate from the plugin, it must be installed only as it is possible the user disabled it and then wants to migrate

func (*HTTPServer) AdminMigrateSecretsToPlugin

func (hs *HTTPServer) AdminMigrateSecretsToPlugin(c *contextmodel.ReqContext) response.Response

To migrate to the plugin, it must be installed and configured so as not to lose access to migrated secrets

func (*HTTPServer) AdminProvisioningReloadAlerting

func (hs *HTTPServer) AdminProvisioningReloadAlerting(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminProvisioningReloadDashboards

func (hs *HTTPServer) AdminProvisioningReloadDashboards(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/provisioning/dashboards/reload admin_provisioning adminProvisioningReloadDashboards

Reload dashboard provisioning configurations.

Reloads the provisioning config files for dashboards again. It won’t return until the new provisioned entities are already stored in the database. In case of dashboards, it will stop polling for changes in dashboard files and then restart it with new configurations after returning. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `provisioning:reload` and scope `provisioners:dashboards`.

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminProvisioningReloadDatasources

func (hs *HTTPServer) AdminProvisioningReloadDatasources(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/provisioning/datasources/reload admin_provisioning adminProvisioningReloadDatasources

Reload datasource provisioning configurations.

Reloads the provisioning config files for datasources again. It won’t return until the new provisioned entities are already stored in the database. In case of dashboards, it will stop polling for changes in dashboard files and then restart it with new configurations after returning. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `provisioning:reload` and scope `provisioners:datasources`.

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminProvisioningReloadNotifications

func (hs *HTTPServer) AdminProvisioningReloadNotifications(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/provisioning/notifications/reload admin_provisioning adminProvisioningReloadNotifications

Reload legacy alert notifier provisioning configurations.

Reloads the provisioning config files for legacy alert notifiers again. It won’t return until the new provisioned entities are already stored in the database. In case of dashboards, it will stop polling for changes in dashboard files and then restart it with new configurations after returning. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `provisioning:reload` and scope `provisioners:notifications`.

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminProvisioningReloadPlugins

func (hs *HTTPServer) AdminProvisioningReloadPlugins(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/provisioning/plugins/reload admin_provisioning adminProvisioningReloadPlugins

Reload plugin provisioning configurations.

Reloads the provisioning config files for plugins again. It won’t return until the new provisioned entities are already stored in the database. In case of dashboards, it will stop polling for changes in dashboard files and then restart it with new configurations after returning. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `provisioning:reload` and scope `provisioners:plugin`.

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminReEncryptEncryptionKeys

func (hs *HTTPServer) AdminReEncryptEncryptionKeys(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminReEncryptSecrets

func (hs *HTTPServer) AdminReEncryptSecrets(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminRevokeUserAuthToken

func (hs *HTTPServer) AdminRevokeUserAuthToken(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/users/{user_id}/revoke-auth-token admin_users adminRevokeUserAuthToken

Revoke auth token for user.

Revokes the given auth token (device) for the user. User of issued auth token (device) will no longer be logged in and will be required to authenticate again upon next activity. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.authtoken:update` and scope `global.users:*`.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) AdminRollbackSecrets

func (hs *HTTPServer) AdminRollbackSecrets(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminRotateDataEncryptionKeys

func (hs *HTTPServer) AdminRotateDataEncryptionKeys(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) AdminUpdateUserPassword

func (hs *HTTPServer) AdminUpdateUserPassword(c *contextmodel.ReqContext) response.Response

swagger:route PUT /admin/users/{user_id}/password admin_users adminUpdateUserPassword

Set password for user.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.password:update` and scope `global.users:*`.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AdminUpdateUserPermissions

func (hs *HTTPServer) AdminUpdateUserPermissions(c *contextmodel.ReqContext) response.Response

swagger:route PUT /admin/users/{user_id}/permissions admin_users adminUpdateUserPermissions

Set permissions for user.

Only works with Basic Authentication (username and password). See introduction for an explanation. If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.permissions:update` and scope `global.users:*`.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) AlertTest

swagger:route POST /alerts/test legacy_alerts testAlert

Test alert.

Responses: 200: testAlertResponse 400: badRequestError 422: unprocessableEntityError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CalculateDashboardDiff

func (hs *HTTPServer) CalculateDashboardDiff(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/calculate-diff dashboards calculateDashboardDiff

Perform diff on two dashboards.

Produces: - application/json - text/html

Responses: 200: calculateDashboardDiffResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CallDatasourceResource deprecated

func (hs *HTTPServer) CallDatasourceResource(c *contextmodel.ReqContext)

swagger:route GET /datasources/{id}/resources/{datasource_proxy_route} datasources callDatasourceResourceByID

Fetch data source resources by Id.

Please refer to [updated API](#/datasources/callDatasourceResourceWithUID) instead

Deprecated: true

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) CallDatasourceResourceWithUID

func (hs *HTTPServer) CallDatasourceResourceWithUID(c *contextmodel.ReqContext)

swagger:route GET /datasources/uid/{uid}/resources/{datasource_proxy_route} datasources callDatasourceResourceWithUID

Fetch data source resources.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) CallResource

func (hs *HTTPServer) CallResource(c *contextmodel.ReqContext)

CallResource passes a resource call from a plugin to the backend plugin.

/api/plugins/:pluginId/resources/*

func (*HTTPServer) ChangeActiveOrgAndRedirectToHome

func (hs *HTTPServer) ChangeActiveOrgAndRedirectToHome(c *contextmodel.ReqContext)

GET /profile/switch-org/:id

func (*HTTPServer) ChangeUserPassword

func (hs *HTTPServer) ChangeUserPassword(c *contextmodel.ReqContext) response.Response

swagger:route PUT /user/password signed_in_user changeUserPassword

Change Password.

Changes the password for the user.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CheckDatasourceHealth deprecated

func (hs *HTTPServer) CheckDatasourceHealth(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/{id}/health datasources checkDatasourceHealthByID

Sends a health check request to the plugin datasource identified by the ID.

Please refer to [updated API](#/datasources/checkDatasourceHealthWithUID) instead

Deprecated: true

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CheckDatasourceHealthWithUID

func (hs *HTTPServer) CheckDatasourceHealthWithUID(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/uid/{uid}/health datasources checkDatasourceHealthWithUID

Sends a health check request to the plugin datasource identified by the UID.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CheckHealth

func (hs *HTTPServer) CheckHealth(c *contextmodel.ReqContext) response.Response

CheckHealth returns the health of a plugin. /api/plugins/:pluginId/health

func (*HTTPServer) ClearHelpFlags

func (hs *HTTPServer) ClearHelpFlags(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/helpflags/clear signed_in_user clearHelpFlags

Clear user help flag.

Responses: 200: helpFlagResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CollectPluginMetrics

func (hs *HTTPServer) CollectPluginMetrics(c *contextmodel.ReqContext) response.Response

CollectPluginMetrics collect metrics from a plugin.

/api/plugins/:pluginId/metrics

func (*HTTPServer) CompleteInvite

func (hs *HTTPServer) CompleteInvite(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) CookieOptionsFromCfg

func (hs *HTTPServer) CookieOptionsFromCfg() cookies.CookieOptions

func (*HTTPServer) CreateAlertNotification

func (hs *HTTPServer) CreateAlertNotification(c *contextmodel.ReqContext) response.Response

swagger:route POST /alert-notifications legacy_alerts_notification_channels createAlertNotificationChannel

Create notification channel.

You can find the full list of [supported notifiers](https://grafana.com/docs/grafana/latest/alerting/old-alerting/notifications/#list-of-supported-notifiers) on the alert notifiers page.

Responses: 200: getAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) CreateDashboardSnapshot

func (hs *HTTPServer) CreateDashboardSnapshot(c *contextmodel.ReqContext) response.Response

swagger:route POST /snapshots snapshots createDashboardSnapshot

When creating a snapshot using the API, you have to provide the full dashboard payload including the snapshot data. This endpoint is designed for the Grafana UI.

Snapshot public mode should be enabled or authentication is required.

Responses: 200: createDashboardSnapshotResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) CreateFolder

func (hs *HTTPServer) CreateFolder(c *contextmodel.ReqContext) response.Response

swagger:route POST /folders folders createFolder

Create folder.

If nested folders are enabled then it additionally expects the parent folder UID.

Responses: 200: folderResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) CreateOrg

swagger:route POST /orgs orgs createOrg

Create Organization.

Only works if [users.allow_org_create](https://grafana.com/docs/grafana/latest/administration/configuration/#allow_org_create) is set.

Responses: 200: createOrgResponse 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) CreatePlaylist

func (hs *HTTPServer) CreatePlaylist(c *contextmodel.ReqContext) response.Response

swagger:route POST /playlists playlists createPlaylist

Create playlist.

Responses: 200: createPlaylistResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) CreateTeam

func (hs *HTTPServer) CreateTeam(c *contextmodel.ReqContext) response.Response

swagger:route POST /teams teams createTeam

Add Team.

Responses: 200: createTeamResponse 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) DeleteAPIKey

func (hs *HTTPServer) DeleteAPIKey(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /auth/keys/{id} api_keys deleteAPIkey

Delete API key.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteAlertNotification

func (hs *HTTPServer) DeleteAlertNotification(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /alert-notifications/{notification_channel_id} legacy_alerts_notification_channels deleteAlertNotificationChannel

Delete alert notification by ID.

Deletes an existing notification channel identified by ID.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteAlertNotificationByUID

func (hs *HTTPServer) DeleteAlertNotificationByUID(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /alert-notifications/uid/{notification_channel_uid} legacy_alerts_notification_channels deleteAlertNotificationChannelByUID

Delete alert notification by UID.

Deletes an existing notification channel identified by UID.

Responses: 200: deleteAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteAnnotationByID

func (hs *HTTPServer) DeleteAnnotationByID(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /annotations/{annotation_id} annotations deleteAnnotationByID

Delete Annotation By ID.

Deletes the annotation that matches the specified ID.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) DeleteDashboardByUID

func (hs *HTTPServer) DeleteDashboardByUID(c *contextmodel.ReqContext) response.Response

DeleteDashboardByUID swagger:route DELETE /dashboards/uid/{uid} dashboards deleteDashboardByUID

Delete dashboard by uid.

Will delete the dashboard given the specified unique identifier (uid).

Responses: 200: deleteDashboardResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteDashboardSnapshot

func (hs *HTTPServer) DeleteDashboardSnapshot(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /snapshots/{key} snapshots deleteDashboardSnapshot

Delete Snapshot by Key.

Responses: 200: okResponse 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteDashboardSnapshotByDeleteKey

func (hs *HTTPServer) DeleteDashboardSnapshotByDeleteKey(c *contextmodel.ReqContext) response.Response

swagger:route GET /snapshots-delete/{deleteKey} snapshots deleteDashboardSnapshotByDeleteKey

Delete Snapshot by deleteKey.

Snapshot public mode should be enabled or authentication is required.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteDataSourceById deprecated

func (hs *HTTPServer) DeleteDataSourceById(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /datasources/{id} datasources deleteDataSourceByID

Delete an existing data source by id.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:delete` and scopes: `datasources:*`, `datasources:id:*` and `datasources:id:1` (single data source).

Please refer to [updated API](#/datasources/deleteDataSourceByUID) instead

Deprecated: true

Responses: 200: okResponse 401: unauthorisedError 404: notFoundError 403: forbiddenError 500: internalServerError

func (*HTTPServer) DeleteDataSourceByName

func (hs *HTTPServer) DeleteDataSourceByName(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /datasources/name/{name} datasources deleteDataSourceByName

Delete an existing data source by name.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:delete` and scopes: `datasources:*`, `datasources:name:*` and `datasources:name:test_datasource` (single data source).

Responses: 200: deleteDataSourceByNameResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteDataSourceByUID

func (hs *HTTPServer) DeleteDataSourceByUID(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /datasources/uid/{uid} datasources deleteDataSourceByUID

Delete an existing data source by UID.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:delete` and scopes: `datasources:*`, `datasources:uid:*` and `datasources:uid:kLtEtcRGk` (single data source).

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteFolder

func (hs *HTTPServer) DeleteFolder(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /folders/{folder_uid} folders deleteFolder

Delete folder.

Deletes an existing folder identified by UID along with all dashboards (and their alerts) stored in the folder. This operation cannot be reverted. If nested folders are enabled then it also deletes all the subfolders.

Responses: 200: deleteFolderResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteOrgByID

func (hs *HTTPServer) DeleteOrgByID(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /orgs/{org_id} orgs deleteOrgByID

Delete Organization.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeletePlaylist

func (hs *HTTPServer) DeletePlaylist(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /playlists/{uid} playlists deletePlaylist

Delete playlist.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) DeleteTeamByID

func (hs *HTTPServer) DeleteTeamByID(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /teams/{team_id} teams deleteTeamByID

Delete Team By ID.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetAPIKeys

func (hs *HTTPServer) GetAPIKeys(c *contextmodel.ReqContext) response.Response

swagger:route GET /auth/keys api_keys getAPIkeys

Get auth keys.

Will return auth keys.

Responses: 200: getAPIkeyResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetAlert

swagger:route GET /alerts/{alert_id} legacy_alerts getAlertByID

Get alert by ID.

“evalMatches” data in the response is cached in the db when and only when the state of the alert changes (e.g. transitioning from “ok” to “alerting” state). If data from one server triggers the alert first and, before that server is seen leaving alerting state, a second server also enters a state that would trigger the alert, the second server will not be visible in “evalMatches” data.

Responses: 200: getAlertResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetAlertNotificationByID

func (hs *HTTPServer) GetAlertNotificationByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /alert-notifications/{notification_channel_id} legacy_alerts_notification_channels getAlertNotificationChannelByID

Get notification channel by ID.

Returns the notification channel given the notification channel ID.

Responses: 200: getAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetAlertNotificationByUID

func (hs *HTTPServer) GetAlertNotificationByUID(c *contextmodel.ReqContext) response.Response

swagger:route GET /alert-notifications/uid/{notification_channel_uid} legacy_alerts_notification_channels getAlertNotificationChannelByUID

Get notification channel by UID.

Returns the notification channel given the notification channel UID.

Responses: 200: getAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetAlertNotificationLookup

func (hs *HTTPServer) GetAlertNotificationLookup(c *contextmodel.ReqContext) response.Response

swagger:route GET /alert-notifications/lookup legacy_alerts_notification_channels getAlertNotificationLookup

Get all notification channels (lookup).

Returns all notification channels, but with less detailed information. Accessible by any authenticated user and is mainly used by providing alert notification channels in Grafana UI when configuring alert rule.

Responses: 200: getAlertNotificationLookupResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetAlertNotifications

func (hs *HTTPServer) GetAlertNotifications(c *contextmodel.ReqContext) response.Response

swagger:route GET /alert-notifications legacy_alerts_notification_channels getAlertNotificationChannels

Get all notification channels.

Returns all notification channels that the authenticated user has permission to view.

Responses: 200: getAlertNotificationChannelsResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetAlertNotifiers

func (hs *HTTPServer) GetAlertNotifiers(ngalertEnabled bool) func(*contextmodel.ReqContext) response.Response

func (*HTTPServer) GetAlertStatesForDashboard

func (hs *HTTPServer) GetAlertStatesForDashboard(c *contextmodel.ReqContext) response.Response

swagger:route GET /alerts/states-for-dashboard legacy_alerts getDashboardStates

Get alert states for a dashboard.

Responses: Responses: 200: getDashboardStatesResponse 400: badRequestError 500: internalServerError

func (*HTTPServer) GetAlerts

swagger:route GET /alerts legacy_alerts getAlerts

Get legacy alerts.

Responses: 200: getAlertsResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetAnnotationByID

func (hs *HTTPServer) GetAnnotationByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /annotations/{annotation_id} annotations getAnnotationByID

Get Annotation by ID.

Responses: 200: getAnnotationByIDResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetAnnotationTags

func (hs *HTTPServer) GetAnnotationTags(c *contextmodel.ReqContext) response.Response

swagger:route GET /annotations/tags annotations getAnnotationTags

Find Annotations Tags.

Find all the event tags created in the annotations.

Responses: 200: getAnnotationTagsResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetAnnotations

func (hs *HTTPServer) GetAnnotations(c *contextmodel.ReqContext) response.Response

swagger:route GET /annotations annotations getAnnotations

Find Annotations.

Starting in Grafana v6.4 regions annotations are now returned in one entity that now includes the timeEnd property.

Responses: 200: getAnnotationsResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetCurrentOrg

func (hs *HTTPServer) GetCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route GET /org org getCurrentOrg

Get current Organization.

Responses: 200: getCurrentOrgResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetCurrentOrgQuotas

func (hs *HTTPServer) GetCurrentOrgQuotas(c *contextmodel.ReqContext) response.Response

swagger:route GET /org/quotas getCurrentOrg getCurrentOrgQuota

Fetch Organization quota.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `orgs.quotas:read` and scope `org:id:1` (orgIDScope).

Responses: 200: getQuotaResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDashboard

func (hs *HTTPServer) GetDashboard(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboards/uid/{uid} dashboards getDashboardByUID

Get dashboard by uid.

Will return the dashboard given the dashboard unique identifier (uid).

Responses: 200: dashboardResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDashboardPermissionList deprecated

func (hs *HTTPServer) GetDashboardPermissionList(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboards/id/{DashboardID}/permissions dashboard_permissions getDashboardPermissionsListByID

Gets all existing permissions for the given dashboard.

Please refer to [updated API](#/dashboard_permissions/getDashboardPermissionsListByUID) instead

Deprecated: true

Responses: 200: getDashboardPermissionsListResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDashboardSnapshot

func (hs *HTTPServer) GetDashboardSnapshot(c *contextmodel.ReqContext) response.Response

GET /api/snapshots/:key swagger:route GET /snapshots/{key} snapshots getDashboardSnapshot

Get Snapshot by Key.

Responses: 200: getDashboardSnapshotResponse 400: badRequestError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDashboardTags

func (hs *HTTPServer) GetDashboardTags(c *contextmodel.ReqContext)

swagger:route GET /dashboards/tags dashboards getDashboardTags

Get all dashboards tags of an organisation.

Responses: 200: getDashboardsTagsResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetDashboardUIDs

func (hs *HTTPServer) GetDashboardUIDs(c *contextmodel.ReqContext)

GetDashboardUIDs converts internal ids to UIDs

func (*HTTPServer) GetDashboardVersion

func (hs *HTTPServer) GetDashboardVersion(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboards/uid/{uid}/versions/{DashboardVersionID} dashboard_versions getDashboardVersionByUID

Get a specific dashboard version using UID.

Responses: 200: dashboardVersionResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDashboardVersions

func (hs *HTTPServer) GetDashboardVersions(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboards/uid/{uid}/versions dashboard_versions getDashboardVersionsByUID

Gets all existing versions for the dashboard using UID.

Responses: 200: dashboardVersionsResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDataSourceById deprecated

func (hs *HTTPServer) GetDataSourceById(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/{id} datasources getDataSourceByID

Get a single data source by Id.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:read` and scopes: `datasources:*`, `datasources:id:*` and `datasources:id:1` (single data source).

Please refer to [updated API](#/datasources/getDataSourceByUID) instead

Deprecated: true

Responses: 200: getDataSourceResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDataSourceByName

func (hs *HTTPServer) GetDataSourceByName(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/name/{name} datasources getDataSourceByName

Get a single data source by Name.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:read` and scopes: `datasources:*`, `datasources:name:*` and `datasources:name:test_datasource` (single data source).

Responses: 200: getDataSourceResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetDataSourceByUID

func (hs *HTTPServer) GetDataSourceByUID(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/uid/{uid} datasources getDataSourceByUID

Get a single data source by UID.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:read` and scopes: `datasources:*`, `datasources:uid:*` and `datasources:uid:kLtEtcRGk` (single data source).

Responses: 200: getDataSourceResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDataSourceIdByName

func (hs *HTTPServer) GetDataSourceIdByName(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources/id/{name} datasources getDataSourceIdByName

Get data source Id by Name.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:read` and scopes: `datasources:*`, `datasources:name:*` and `datasources:name:test_datasource` (single data source).

Responses: 200: getDataSourceIDResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetDataSources

func (hs *HTTPServer) GetDataSources(c *contextmodel.ReqContext) response.Response

swagger:route GET /datasources datasources getDataSources

Get all data sources.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:read` and scope: `datasources:*`.

Responses: 200: getDataSourcesResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetFolderByID

func (hs *HTTPServer) GetFolderByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /folders/id/{folder_id} folders getFolderByID

Get folder by id.

Returns the folder identified by id.

Responses: 200: folderResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetFolderByUID

func (hs *HTTPServer) GetFolderByUID(c *contextmodel.ReqContext) response.Response

swagger:route GET /folders/{folder_uid} folders getFolderByUID

Get folder by uid.

Responses: 200: folderResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetFolderPermissionList

func (hs *HTTPServer) GetFolderPermissionList(c *contextmodel.ReqContext) response.Response

swagger:route GET /folders/{folder_uid}/permissions folder_permissions getFolderPermissionList

Gets all existing permissions for the folder with the given `uid`.

Responses: 200: getFolderPermissionListResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetFolders

func (hs *HTTPServer) GetFolders(c *contextmodel.ReqContext) response.Response

swagger:route GET /folders folders getFolders

Get all folders.

Returns all folders that the authenticated user has permission to view. If nested folders are enabled, it expects an additional query parameter with the parent folder UID and returns the immediate subfolders.

Responses: 200: getFoldersResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetFrontendSettings

func (hs *HTTPServer) GetFrontendSettings(c *contextmodel.ReqContext)

func (*HTTPServer) GetHomeDashboard

func (hs *HTTPServer) GetHomeDashboard(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboards/home dashboards getHomeDashboard

Get home dashboard.

Responses: 200: getHomeDashboardResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetInviteInfoByCode

func (hs *HTTPServer) GetInviteInfoByCode(c *contextmodel.ReqContext) response.Response

GetInviteInfoByCode gets a pending user invite corresponding to a certain code. A response containing an InviteInfo object is returned if the invite is found. If a (pending) invite is not found, 404 is returned.

func (*HTTPServer) GetOrgByID

func (hs *HTTPServer) GetOrgByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs/{org_id} orgs getOrgByID

Get Organization by ID.

Security: - basic:

Responses: 200: getOrgByIDResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetOrgByName

func (hs *HTTPServer) GetOrgByName(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs/name/{org_name} orgs getOrgByName

Get Organization by ID.

Security: - basic:

Responses: 200: getOrgByNameResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetOrgPreferences

func (hs *HTTPServer) GetOrgPreferences(c *contextmodel.ReqContext) response.Response

swagger:route GET /org/preferences org_preferences getOrgPreferences

Get Current Org Prefs.

Responses: 200: getPreferencesResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetOrgQuotas

func (hs *HTTPServer) GetOrgQuotas(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs/{org_id}/quotas orgs getOrgQuota

Fetch Organization quota.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `orgs.quotas:read` and scope `org:id:1` (orgIDScope).

Responses: 200: getQuotaResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetOrgUsers

func (hs *HTTPServer) GetOrgUsers(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs/{org_id}/users orgs getOrgUsers

Get Users in Organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:read` with scope `users:*`.

Security: - basic:

Responses: 200: getOrgUsersResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetOrgUsersForCurrentOrg

func (hs *HTTPServer) GetOrgUsersForCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route GET /org/users org getOrgUsersForCurrentOrg

Get all users within the current organization.

Returns all org users within the current organization. Accessible to users with org admin role. If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:read` with scope `users:*`.

Responses: 200: getOrgUsersForCurrentOrgResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetOrgUsersForCurrentOrgLookup

func (hs *HTTPServer) GetOrgUsersForCurrentOrgLookup(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) GetPendingOrgInvites

func (hs *HTTPServer) GetPendingOrgInvites(c *contextmodel.ReqContext) response.Response

swagger:route GET /org/invites org_invites getPendingOrgInvites

Get pending invites.

Responses: 200: getPendingOrgInvitesResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetPlaylist

func (hs *HTTPServer) GetPlaylist(c *contextmodel.ReqContext) response.Response

swagger:route GET /playlists/{uid} playlists getPlaylist

Get playlist.

Responses: 200: getPlaylistResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetPlaylistDashboards

func (hs *HTTPServer) GetPlaylistDashboards(c *contextmodel.ReqContext) response.Response

swagger:route GET /playlists/{uid}/dashboards playlists getPlaylistDashboards

Get playlist dashboards.

Responses: 200: getPlaylistDashboardsResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetPlaylistItems

func (hs *HTTPServer) GetPlaylistItems(c *contextmodel.ReqContext) response.Response

swagger:route GET /playlists/{uid}/items playlists getPlaylistItems

Get playlist items.

Responses: 200: getPlaylistItemsResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetPluginDashboards

func (hs *HTTPServer) GetPluginDashboards(c *contextmodel.ReqContext) response.Response

GetPluginDashboards get plugin dashboards.

/api/plugins/:pluginId/dashboards

func (*HTTPServer) GetPluginErrorsList

func (hs *HTTPServer) GetPluginErrorsList(_ *contextmodel.ReqContext) response.Response

func (*HTTPServer) GetPluginList

func (hs *HTTPServer) GetPluginList(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) GetPluginMarkdown

func (hs *HTTPServer) GetPluginMarkdown(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) GetPluginSettingByID

func (hs *HTTPServer) GetPluginSettingByID(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) GetRedirectURL

func (hs *HTTPServer) GetRedirectURL(c *contextmodel.ReqContext) string

func (*HTTPServer) GetSharingOptions

func (hs *HTTPServer) GetSharingOptions(c *contextmodel.ReqContext)

swagger:route GET /snapshot/shared-options snapshots getSharingOptions

Get snapshot sharing settings.

Responses: 200: getSharingOptionsResponse 401: unauthorisedError

func (*HTTPServer) GetSignUpOptions

func (hs *HTTPServer) GetSignUpOptions(c *contextmodel.ReqContext) response.Response

GET /api/user/signup/options

func (*HTTPServer) GetSignedInUser

func (hs *HTTPServer) GetSignedInUser(c *contextmodel.ReqContext) response.Response

swagger:route GET /user signed_in_user getSignedInUser

Get (current authenticated user)

Responses: 200: userResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetSignedInUserOrgList

func (hs *HTTPServer) GetSignedInUserOrgList(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/orgs signed_in_user getSignedInUserOrgList

Organizations of the actual User.

Return a list of all organizations of the current user.

Security: - basic:

Responses: 200: getSignedInUserOrgListResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetSignedInUserTeamList

func (hs *HTTPServer) GetSignedInUserTeamList(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/teams signed_in_user getSignedInUserTeamList

Teams that the actual User is member of.

Return a list of all teams that the current user is member of.

Responses: 200: getSignedInUserTeamListResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetTeamByID

func (hs *HTTPServer) GetTeamByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /teams/{team_id} teams getTeamByID

Get Team By ID.

Responses: 200: getTeamByIDResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetTeamMembers

func (hs *HTTPServer) GetTeamMembers(c *contextmodel.ReqContext) response.Response

swagger:route GET /teams/{team_id}/members teams getTeamMembers

Get Team Members.

Responses: 200: getTeamMembersResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetTeamPreferences

func (hs *HTTPServer) GetTeamPreferences(c *contextmodel.ReqContext) response.Response

swagger:route GET /teams/{team_id}/preferences teams getTeamPreferences

Get Team Preferences.

Responses: 200: getPreferencesResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetUserAuthTokens

func (hs *HTTPServer) GetUserAuthTokens(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/auth-tokens signed_in_user getUserAuthTokens

Auth tokens of the actual User.

Return a list of all auth tokens (devices) that the actual user currently have logged in from.

Responses: 200: getUserAuthTokensResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) GetUserByID

func (hs *HTTPServer) GetUserByID(c *contextmodel.ReqContext) response.Response

swagger:route GET /users/{user_id} users getUserByID

Get user by id.

Responses: 200: userResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetUserByLoginOrEmail

func (hs *HTTPServer) GetUserByLoginOrEmail(c *contextmodel.ReqContext) response.Response

swagger:route GET /users/lookup users getUserByLoginOrEmail

Get user by login or email.

Responses: 200: userResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetUserOrgList

func (hs *HTTPServer) GetUserOrgList(c *contextmodel.ReqContext) response.Response

swagger:route GET /users/{user_id}/orgs users getUserOrgList

Get organizations for user.

Get organizations for user identified by id.

Responses: 200: getUserOrgListResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetUserPreferences

func (hs *HTTPServer) GetUserPreferences(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/preferences user_preferences getUserPreferences

Get user preferences.

Responses: 200: getPreferencesResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) GetUserQuotas

func (hs *HTTPServer) GetUserQuotas(c *contextmodel.ReqContext) response.Response

swagger:route GET /user/quotas signed_in_user getUserQuotas

Fetch user quota.

Responses: 200: getQuotaResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) GetUserTeams

func (hs *HTTPServer) GetUserTeams(c *contextmodel.ReqContext) response.Response

swagger:route GET /users/{user_id}/teams users getUserTeams

Get teams for user.

Get teams for user identified by id.

Responses: 200: getUserTeamsResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) Index

func (hs *HTTPServer) Index(c *contextmodel.ReqContext)

func (*HTTPServer) InstallPlugin

func (hs *HTTPServer) InstallPlugin(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) ListSortOptions

func (hs *HTTPServer) ListSortOptions(c *contextmodel.ReqContext) response.Response

swagger:route GET /search/sorting search listSortOptions

List search sorting options.

Responses: 200: listSortOptionsResponse 401: unauthorisedError

func (*HTTPServer) LoadPlaylistDashboards

func (hs *HTTPServer) LoadPlaylistDashboards(ctx context.Context, orgID int64, signedInUser *user.SignedInUser, playlistUID string) (dtos.PlaylistDashboardsSlice, error)

Deprecated -- the frontend can do this better

func (*HTTPServer) LoginAPIPing

func (hs *HTTPServer) LoginAPIPing(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) LoginPost

func (*HTTPServer) LoginView

func (hs *HTTPServer) LoginView(c *contextmodel.ReqContext)

func (*HTTPServer) Logout

func (hs *HTTPServer) Logout(c *contextmodel.ReqContext)

func (*HTTPServer) MassDeleteAnnotations

func (hs *HTTPServer) MassDeleteAnnotations(c *contextmodel.ReqContext) response.Response

swagger:route POST /annotations/mass-delete annotations massDeleteAnnotations

Delete multiple annotations.

Responses: 200: okResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) MoveFolder

func (hs *HTTPServer) MoveFolder(c *contextmodel.ReqContext) response.Response

swagger:route POST /folders/{folder_uid}/move folders moveFolder

Move folder.

Responses: 200: folderResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) NotFoundHandler

func (hs *HTTPServer) NotFoundHandler(c *contextmodel.ReqContext)

func (*HTTPServer) NotificationTest

func (hs *HTTPServer) NotificationTest(c *contextmodel.ReqContext) response.Response

swagger:route POST /alert-notifications/test legacy_alerts_notification_channels notificationChannelTest

Test notification channel.

Sends a test notification to the channel.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 412: SMTPNotEnabledError 500: internalServerError

func (*HTTPServer) OAuthLogin

func (hs *HTTPServer) OAuthLogin(ctx *contextmodel.ReqContext)

func (*HTTPServer) PatchAnnotation

func (hs *HTTPServer) PatchAnnotation(c *contextmodel.ReqContext) response.Response

swagger:route PATCH /annotations/{annotation_id} annotations patchAnnotation

Patch Annotation.

Updates one or more properties of an annotation that matches the specified ID. This operation currently supports updating of the `text`, `tags`, `time` and `timeEnd` properties. This is available in Grafana 6.0.0-beta2 and above.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) PatchOrgPreferences

func (hs *HTTPServer) PatchOrgPreferences(c *contextmodel.ReqContext) response.Response

swagger:route PATCH /org/preferences org_preferences patchOrgPreferences

Patch Current Org Prefs.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) PatchUserPreferences

func (hs *HTTPServer) PatchUserPreferences(c *contextmodel.ReqContext) response.Response

swagger:route PATCH /user/preferences user_preferences patchUserPreferences

Patch user preferences.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 500: internalServerError

func (*HTTPServer) PauseAlert

func (hs *HTTPServer) PauseAlert(legacyAlertingEnabled *bool) func(c *contextmodel.ReqContext) response.Response

swagger:route POST /alerts/{alert_id}/pause legacy_alerts pauseAlert

Pause/unpause alert by id.

Responses: 200: pauseAlertResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) PauseAllAlerts

func (hs *HTTPServer) PauseAllAlerts(legacyAlertingEnabled *bool) func(c *contextmodel.ReqContext) response.Response

swagger:route POST /admin/pause-all-alerts admin pauseAllAlerts

Pause/unpause all (legacy) alerts.

Security: - basic:

Responses: 200: pauseAlertsResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) PostAnnotation

func (hs *HTTPServer) PostAnnotation(c *contextmodel.ReqContext) response.Response

swagger:route POST /annotations annotations postAnnotation

Create Annotation.

Creates an annotation in the Grafana database. The dashboardId and panelId fields are optional. If they are not specified then an organization annotation is created and can be queried in any dashboard that adds the Grafana annotations data source. When creating a region annotation include the timeEnd property. The format for `time` and `timeEnd` should be epoch numbers in millisecond resolution. The response for this HTTP request is slightly different in versions prior to v6.4. In prior versions you would also get an endId if you where creating a region. But in 6.4 regions are represented using a single event with time and timeEnd properties.

Responses: 200: postAnnotationResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) PostDashboard

func (hs *HTTPServer) PostDashboard(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/db dashboards postDashboard

Create / Update dashboard

Creates a new dashboard or updates an existing dashboard.

Responses: 200: postDashboardResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 412: preconditionFailedError 422: unprocessableEntityError 500: internalServerError

func (*HTTPServer) PostFrontendMetrics

func (hs *HTTPServer) PostFrontendMetrics(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) PostGraphiteAnnotation

func (hs *HTTPServer) PostGraphiteAnnotation(c *contextmodel.ReqContext) response.Response

swagger:route POST /annotations/graphite annotations postGraphiteAnnotation

Create Annotation in Graphite format.

Creates an annotation by using Graphite-compatible event format. The `when` and `data` fields are optional. If `when` is not specified then the current time will be used as annotation’s timestamp. The `tags` field can also be in prior to Graphite `0.10.0` format (string with multiple tags being separated by a space).

Responses: 200: postAnnotationResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) ProxyDataSourceRequest deprecated

func (hs *HTTPServer) ProxyDataSourceRequest(c *contextmodel.ReqContext)

swagger:route DELETE /datasources/proxy/{id}/{datasource_proxy_route} datasources datasourceProxyDELETEcalls

Data source proxy DELETE calls.

Proxies all calls to the actual data source.

Please refer to [updated API](#/datasources/datasourceProxyDELETEByUIDcalls) instead

Deprecated: true

Responses: 202: 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) ProxyDataSourceRequestWithUID

func (hs *HTTPServer) ProxyDataSourceRequestWithUID(c *contextmodel.ReqContext)

swagger:route DELETE /datasources/proxy/uid/{uid}/{datasource_proxy_route} datasources datasourceProxyDELETEByUIDcalls

Data source proxy DELETE calls.

Proxies all calls to the actual data source.

Responses: 202: 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) ProxyGnetRequest

func (hs *HTTPServer) ProxyGnetRequest(c *contextmodel.ReqContext)

func (*HTTPServer) ProxyPluginRequest

func (hs *HTTPServer) ProxyPluginRequest(c *contextmodel.ReqContext)

func (*HTTPServer) QueryMetricsV2

func (hs *HTTPServer) QueryMetricsV2(c *contextmodel.ReqContext) response.Response

QueryMetricsV2 returns query metrics. swagger:route POST /ds/query ds queryMetricsWithExpressions

DataSource query metrics with expressions.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:query`.

Responses: 200: queryMetricsWithExpressionsRespons 207: queryMetricsWithExpressionsRespons 401: unauthorisedError 400: badRequestError 403: forbiddenError 500: internalServerError

func (*HTTPServer) RedirectResponseWithError

func (hs *HTTPServer) RedirectResponseWithError(c *contextmodel.ReqContext, err error, v ...interface{}) *response.RedirectResponse

func (*HTTPServer) RemoveOrgUser

func (hs *HTTPServer) RemoveOrgUser(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /orgs/{org_id}/users/{user_id} orgs removeOrgUser

Delete user in current organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:remove` with scope `users:*`.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) RemoveOrgUserForCurrentOrg

func (hs *HTTPServer) RemoveOrgUserForCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /org/users/{user_id} org removeOrgUserForCurrentOrg

Delete user in current organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:remove` with scope `users:*`.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) RemoveTeamMember

func (hs *HTTPServer) RemoveTeamMember(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /teams/{team_id}/members/{user_id} teams removeTeamMember

Remove Member From Team.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) RenderToPng

func (hs *HTTPServer) RenderToPng(c *contextmodel.ReqContext)

func (*HTTPServer) ResetPassword

func (hs *HTTPServer) ResetPassword(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) RestoreDashboardVersion

func (hs *HTTPServer) RestoreDashboardVersion(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/uid/{uid}/restore dashboard_versions restoreDashboardVersionByUID

Restore a dashboard to a given dashboard version using UID.

Responses: 200: postDashboardResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) RevokeInvite

func (hs *HTTPServer) RevokeInvite(c *contextmodel.ReqContext) response.Response

swagger:route DELETE /org/invites/{invitation_code}/revoke org_invites revokeInvite

Revoke invite.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) RevokeUserAuthToken

func (hs *HTTPServer) RevokeUserAuthToken(c *contextmodel.ReqContext) response.Response

swagger:route POST /user/revoke-auth-token signed_in_user revokeUserAuthToken

Revoke an auth token of the actual User.

Revokes the given auth token (device) for the actual user. User of issued auth token (device) will no longer be logged in and will be required to authenticate again upon next activity.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) RotateUserAuthToken

func (hs *HTTPServer) RotateUserAuthToken(c *contextmodel.ReqContext) response.Response

swagger:route POST /user/auth-tokens/rotate

Rotate the auth token of the caller

Rotate the token of caller, if successful send a new session cookie.

Responses: 200: okResponse 401: unauthorisedError 404: notFoundError 500: internalServerError

func (*HTTPServer) RotateUserAuthTokenRedirect

func (hs *HTTPServer) RotateUserAuthTokenRedirect(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) Run

func (hs *HTTPServer) Run(ctx context.Context) error

func (*HTTPServer) Search

swagger:route GET /search search search

Responses: 200: searchResponse 401: unauthorisedError 422: unprocessableEntityError 500: internalServerError

func (*HTTPServer) SearchDashboardSnapshots

func (hs *HTTPServer) SearchDashboardSnapshots(c *contextmodel.ReqContext) response.Response

swagger:route GET /dashboard/snapshots snapshots searchDashboardSnapshots

List snapshots.

Responses: 200: searchDashboardSnapshotsResponse 500: internalServerError

func (*HTTPServer) SearchOrgUsers

func (hs *HTTPServer) SearchOrgUsers(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs/{org_id}/users/search orgs searchOrgUsers

Search Users in Organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users:read` with scope `users:*`.

Security: - basic:

Responses: 200: searchOrgUsersResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) SearchOrgUsersWithPaging

func (hs *HTTPServer) SearchOrgUsersWithPaging(c *contextmodel.ReqContext) response.Response

SearchOrgUsersWithPaging is an HTTP handler to search for org users with paging. GET /api/org/users/search

func (*HTTPServer) SearchOrgs

func (hs *HTTPServer) SearchOrgs(c *contextmodel.ReqContext) response.Response

swagger:route GET /orgs orgs searchOrgs

Search all Organizations.

Security: - basic:

Responses: 200: searchOrgsResponse 401: unauthorisedError 403: forbiddenError 409: conflictError 500: internalServerError

func (*HTTPServer) SearchPlaylists

func (hs *HTTPServer) SearchPlaylists(c *contextmodel.ReqContext) response.Response

swagger:route GET /playlists playlists searchPlaylists

Get playlists.

Responses: 200: searchPlaylistsResponse 500: internalServerError

func (*HTTPServer) SearchTeams

func (hs *HTTPServer) SearchTeams(c *contextmodel.ReqContext) response.Response

swagger:route GET /teams/search teams searchTeams

Team Search With Paging.

Responses: 200: searchTeamsResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) SendResetPasswordEmail

func (hs *HTTPServer) SendResetPasswordEmail(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) SetHelpFlag

func (hs *HTTPServer) SetHelpFlag(c *contextmodel.ReqContext) response.Response

swagger:route PUT /user/helpflags/{flag_id} signed_in_user setHelpFlag

Set user help flag.

Responses: 200: helpFlagResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) SetHomeDashboard

func (hs *HTTPServer) SetHomeDashboard(c *contextmodel.ReqContext) response.Response

POST /api/preferences/set-home-dash

func (*HTTPServer) SignUp

POST /api/user/signup

func (*HTTPServer) SignUpStep2

func (hs *HTTPServer) SignUpStep2(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) SyncUser

func (hs *HTTPServer) SyncUser(
	ctx *contextmodel.ReqContext,
	extUser *loginservice.ExternalUserInfo,
	connect social.SocialConnector,
) (*user.User, error)

SyncUser syncs a Grafana user profile with the corresponding OAuth profile.

func (*HTTPServer) TrimDashboard

func (hs *HTTPServer) TrimDashboard(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/trim dashboards trimDashboard

Trim defaults from dashboard.

Responses: 200: trimDashboardResponse 401: unauthorisedError 500: internalServerError

func (*HTTPServer) UninstallPlugin

func (hs *HTTPServer) UninstallPlugin(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) UpdateAlertNotification

func (hs *HTTPServer) UpdateAlertNotification(c *contextmodel.ReqContext) response.Response

swagger:route PUT /alert-notifications/{notification_channel_id} legacy_alerts_notification_channels updateAlertNotificationChannel

Update notification channel by ID.

Updates an existing notification channel identified by ID.

Responses: 200: getAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateAlertNotificationByUID

func (hs *HTTPServer) UpdateAlertNotificationByUID(c *contextmodel.ReqContext) response.Response

swagger:route PUT /alert-notifications/uid/{notification_channel_uid} legacy_alerts_notification_channels updateAlertNotificationChannelByUID

Update notification channel by UID.

Updates an existing notification channel identified by uid.

Responses: 200: getAlertNotificationChannelResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateAnnotation

func (hs *HTTPServer) UpdateAnnotation(c *contextmodel.ReqContext) response.Response

swagger:route PUT /annotations/{annotation_id} annotations updateAnnotation

Update Annotation.

Updates all properties of an annotation that matches the specified id. To only update certain property, consider using the Patch Annotation operation.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateCurrentOrg

func (hs *HTTPServer) UpdateCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route PUT /org org updateCurrentOrg

Update current Organization.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateCurrentOrgAddress

func (hs *HTTPServer) UpdateCurrentOrgAddress(c *contextmodel.ReqContext) response.Response

swagger:route PUT /org/address org updateCurrentOrgAddress

Update current Organization's address.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateDashboardPermissions deprecated

func (hs *HTTPServer) UpdateDashboardPermissions(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/id/{DashboardID}/permissions dashboard_permissions updateDashboardPermissionsByID

Updates permissions for a dashboard.

Please refer to [updated API](#/dashboard_permissions/updateDashboardPermissionsByUID) instead

This operation will remove existing permissions if they’re not included in the request.

Deprecated: true

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateDataSourceByID

func (hs *HTTPServer) UpdateDataSourceByID(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) UpdateDataSourceByUID

func (hs *HTTPServer) UpdateDataSourceByUID(c *contextmodel.ReqContext) response.Response

swagger:route PUT /datasources/uid/{uid} datasources updateDataSourceByUID

Update an existing data source.

Similar to creating a data source, `password` and `basicAuthPassword` should be defined under secureJsonData in order to be stored securely as an encrypted blob in the database. Then, the encrypted fields are listed under secureJsonFields section in the response.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `datasources:write` and scopes: `datasources:*`, `datasources:uid:*` and `datasources:uid:1` (single data source).

Responses: 200: createOrUpdateDatasourceResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateFolder

func (hs *HTTPServer) UpdateFolder(c *contextmodel.ReqContext) response.Response

swagger:route PUT /folders/{folder_uid} folders updateFolder

Update folder.

Responses: 200: folderResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 404: notFoundError 409: conflictError 500: internalServerError

func (*HTTPServer) UpdateFolderPermissions

func (hs *HTTPServer) UpdateFolderPermissions(c *contextmodel.ReqContext) response.Response

swagger:route POST /folders/{folder_uid}/permissions folder_permissions updateFolderPermissions

Updates permissions for a folder. This operation will remove existing permissions if they’re not included in the request.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateOrg

swagger:route PUT /orgs/{org_id} orgs updateOrg

Update Organization.

Security: - basic:

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateOrgAddress

func (hs *HTTPServer) UpdateOrgAddress(c *contextmodel.ReqContext) response.Response

swagger:route PUT /orgs/{org_id}/address orgs updateOrgAddress

Update Organization's address.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateOrgPreferences

func (hs *HTTPServer) UpdateOrgPreferences(c *contextmodel.ReqContext) response.Response

swagger:route PUT /org/preferences org_preferences updateOrgPreferences

Update Current Org Prefs.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateOrgQuota

func (hs *HTTPServer) UpdateOrgQuota(c *contextmodel.ReqContext) response.Response

swagger:route PUT /orgs/{org_id}/quotas/{quota_target} orgs updateOrgQuota

Update user quota.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `orgs.quotas:write` and scope `org:id:1` (orgIDScope).

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateOrgUser

func (hs *HTTPServer) UpdateOrgUser(c *contextmodel.ReqContext) response.Response

swagger:route PATCH /orgs/{org_id}/users/{user_id} orgs updateOrgUser

Update Users in Organization.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users.role:update` with scope `users:*`.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateOrgUserForCurrentOrg

func (hs *HTTPServer) UpdateOrgUserForCurrentOrg(c *contextmodel.ReqContext) response.Response

swagger:route PATCH /org/users/{user_id} org updateOrgUserForCurrentOrg

Updates the given user.

If you are running Grafana Enterprise and have Fine-grained access control enabled you need to have a permission with action: `org.users.role:update` with scope `users:*`.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdatePlaylist

func (hs *HTTPServer) UpdatePlaylist(c *contextmodel.ReqContext) response.Response

swagger:route PUT /playlists/{uid} playlists updatePlaylist

Update playlist.

Responses: 200: updatePlaylistResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdatePluginSetting

func (hs *HTTPServer) UpdatePluginSetting(c *contextmodel.ReqContext) response.Response

func (*HTTPServer) UpdateSignedInUser

func (hs *HTTPServer) UpdateSignedInUser(c *contextmodel.ReqContext) response.Response

swagger:route PUT /user signed_in_user updateSignedInUser

Update signed in User.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) UpdateTeam

func (hs *HTTPServer) UpdateTeam(c *contextmodel.ReqContext) response.Response

swagger:route PUT /teams/{team_id} teams updateTeam

Update Team.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 409: conflictError 500: internalServerError

func (*HTTPServer) UpdateTeamMember

func (hs *HTTPServer) UpdateTeamMember(c *contextmodel.ReqContext) response.Response

swagger:route PUT /teams/{team_id}/members/{user_id} teams updateTeamMember

Update Team Member.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateTeamPreferences

func (hs *HTTPServer) UpdateTeamPreferences(c *contextmodel.ReqContext) response.Response

swagger:route PUT /teams/{team_id}/preferences teams updateTeamPreferences

Update Team Preferences.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 500: internalServerError

func (*HTTPServer) UpdateUser

func (hs *HTTPServer) UpdateUser(c *contextmodel.ReqContext) response.Response

swagger:route PUT /users/{user_id} users updateUser

Update user.

Update the user identified by id.

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UpdateUserActiveOrg

func (hs *HTTPServer) UpdateUserActiveOrg(c *contextmodel.ReqContext) response.Response

POST /api/users/:id/using/:orgId

func (*HTTPServer) UpdateUserPreferences

func (hs *HTTPServer) UpdateUserPreferences(c *contextmodel.ReqContext) response.Response

swagger:route PUT /user/preferences user_preferences updateUserPreferences

Update user preferences.

Omitting a key (`theme`, `homeDashboardId`, `timezone`) will cause the current value to be replaced with the system default value.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 500: internalServerError

func (*HTTPServer) UpdateUserQuota

func (hs *HTTPServer) UpdateUserQuota(c *contextmodel.ReqContext) response.Response

swagger:route PUT /admin/users/{user_id}/quotas/{quota_target} admin_users updateUserQuota

Update user quota.

If you are running Grafana Enterprise and have Fine-grained access control enabled, you need to have a permission with action `users.quotas:update` and scope `global.users:1` (userIDScope).

Security: - basic:

Responses: 200: okResponse 401: unauthorisedError 403: forbiddenError 404: notFoundError 500: internalServerError

func (*HTTPServer) UserSetUsingOrg

func (hs *HTTPServer) UserSetUsingOrg(c *contextmodel.ReqContext) response.Response

swagger:route POST /user/using/{org_id} signed_in_user userSetUsingOrg

Switch user context for signed in user.

Switch user context to the given organization.

Responses: 200: okResponse 400: badRequestError 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) ValidateDashboard

func (hs *HTTPServer) ValidateDashboard(c *contextmodel.ReqContext) response.Response

swagger:route POST /dashboards/validate dashboards alpha validateDashboard

Validates a dashboard JSON against the schema.

Produces: - application/json

Responses: 200: validateDashboardResponse 412: validateDashboardResponse 422: validateDashboardResponse 401: unauthorisedError 403: forbiddenError 500: internalServerError

func (*HTTPServer) ValidateOrgAlert

func (hs *HTTPServer) ValidateOrgAlert(c *contextmodel.ReqContext)

func (*HTTPServer) ValidateOrgPlaylist

func (hs *HTTPServer) ValidateOrgPlaylist(c *contextmodel.ReqContext)

func (*HTTPServer) ValidateRedirectTo

func (hs *HTTPServer) ValidateRedirectTo(redirectTo string) error

type HelpFlagResponse

type HelpFlagResponse struct {
	// The response message
	// in: body
	Body struct {
		HelpFlags1 int64  `json:"helpFlags1"`
		Message    string `json:"message"`
	} `json:"body"`
}

swagger:response helpFlagResponse

type InternalServerError

type InternalServerError GenericError

InternalServerError is a general error indicating something went wrong internally.

swagger:response internalServerError

type ListSortOptionsResponse

type ListSortOptionsResponse struct {
	// in: body
	Body struct {
		Name        string `json:"name"`
		DisplayName string `json:"displayName"`
		Description string `json:"description"`
		Meta        string `json:"meta"`
	} `json:"body"`
}

swagger:response listSortOptionsResponse

type LoginError

type LoginError struct {
	HttpStatus    int
	PublicMessage string
	Err           error
}

type LookupAlertNotificationChannelsResponse

type LookupAlertNotificationChannelsResponse struct {
	// The response message
	// in: body
	Body []*dtos.AlertNotificationLookup `json:"body"`
}

swagger:response getAlertNotificationLookupResponse

type LookupOrgUsersParams

type LookupOrgUsersParams struct {
	// in:query
	// required:false
	Query string `json:"query"`
	// in:query
	// required:false
	Limit int `json:"limit"`
}

swagger:parameters getOrgUsersForCurrentOrgLookup

type MassDeleteAnnotationsParams

type MassDeleteAnnotationsParams struct {
	// in:body
	// required:true
	Body dtos.MassDeleteAnnotationsCmd `json:"body"`
}

swagger:parameters massDeleteAnnotations

type MoveFolderParams

type MoveFolderParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
	// in:body
	// required:true
	Body folder.MoveFolderCommand `json:"body"`
}

swagger:parameters moveFolder

type NotFoundError

type NotFoundError GenericError

NotFoundError is returned when the requested resource was not found.

swagger:response notFoundError

type NotificationChannelTestParams

type NotificationChannelTestParams struct {
	// in:body
	// required:true
	Body dtos.NotificationTestCommand `json:"body"`
}

swagger:parameters notificationChannelTest

type OKResponse

type OKResponse struct {
	// in: body
	Body SuccessResponseBody `json:"body"`
}

An OKResponse is returned if the request was successful.

swagger:response okResponse

type PatchAnnotationParams

type PatchAnnotationParams struct {
	// in:path
	// required:true
	AnnotationID string `json:"annotation_id"`
	// in:body
	// required:true
	Body dtos.PatchAnnotationsCmd `json:"body"`
}

swagger:parameters patchAnnotation

type PatchOrgPreferencesParams

type PatchOrgPreferencesParams struct {
	// in:body
	// required:true
	Body dtos.PatchPrefsCmd `json:"body"`
}

swagger:parameters patchOrgPreferences

type PatchUserPreferencesParams

type PatchUserPreferencesParams struct {
	// in:body
	// required:true
	Body dtos.PatchPrefsCmd `json:"body"`
}

swagger:parameters patchUserPreferences

type PauseAlertParams

type PauseAlertParams struct {
	// in:path
	// required:true
	AlertID string `json:"alert_id"`
	// in:body
	// required:true
	Body dtos.PauseAlertCommand `json:"body"`
}

swagger:parameters pauseAlert

type PauseAlertResponse

type PauseAlertResponse struct {
	// in:body
	Body struct {
		// required: true
		AlertID int64 `json:"alertId"`
		// required: true
		Message string `json:"message"`
		// Alert result state
		// required true
		State string `json:"state"`
	} `json:"body"`
}

swagger:response pauseAlertResponse

type PauseAllAlertsParams

type PauseAllAlertsParams struct {
	// in:body
	// required:true
	Body dtos.PauseAllAlertsCommand `json:"body"`
}

swagger:parameters pauseAllAlerts

type PauseAllAlertsResponse

type PauseAllAlertsResponse struct {
	// in:body
	Body struct {
		// AlertsAffected is the number of the affected alerts.
		// required: true
		AlertsAffected int64 `json:"alertsAffected"`
		// required: true
		Message string `json:"message"`
		// Alert result state
		// required true
		State string `json:"state"`
	} `json:"body"`
}

swagger:response pauseAlertsResponse

type PostAPIkeyResponse

type PostAPIkeyResponse struct {
	// The response message
	// in: body
	Body dtos.NewApiKeyResult `json:"body"`
}

swagger:response postAPIkeyResponse

type PostAnnotationParams

type PostAnnotationParams struct {
	// in:body
	// required:true
	Body dtos.PostAnnotationsCmd `json:"body"`
}

swagger:parameters postAnnotation

type PostAnnotationResponse

type PostAnnotationResponse struct {
	// The response message
	// in: body
	Body struct {
		// ID Identifier of the created annotation.
		// required: true
		// example: 65
		ID int64 `json:"id"`

		// Message Message of the created annotation.
		// required: true
		Message string `json:"message"`
	} `json:"body"`
}

swagger:response postAnnotationResponse

type PostDashboardParams

type PostDashboardParams struct {
	// in:body
	// required:true
	Body dashboards.SaveDashboardCommand
}

swagger:parameters postDashboard

type PostDashboardResponse

type PostDashboardResponse struct {
	// in: body
	Body struct {
		// Status status of the response.
		// required: true
		// example: success
		Status string `json:"status"`

		// Slug The slug of the dashboard.
		// required: true
		// example: my-dashboard
		Slug string `json:"title"`

		// Version The version of the dashboard.
		// required: true
		// example: 2
		Verion int64 `json:"version"`

		// ID The unique identifier (id) of the created/updated dashboard.
		// required: true
		// example: 1
		ID string `json:"id"`

		// UID The unique identifier (uid) of the created/updated dashboard.
		// required: true
		// example: nHz3SXiiz
		UID string `json:"uid"`

		// URL The relative URL for accessing the created/updated dashboard.
		// required: true
		// example: /d/nHz3SXiiz/my-dashboard
		URL string `json:"url"`
	} `json:"body"`
}

swagger:response postDashboardResponse

type PostGraphiteAnnotationParams

type PostGraphiteAnnotationParams struct {
	// in:body
	// required:true
	Body dtos.PostGraphiteAnnotationsCmd `json:"body"`
}

swagger:parameters postGraphiteAnnotation

type PreconditionFailedError

type PreconditionFailedError GenericError

PreconditionFailedError

swagger:response preconditionFailedError

type QueryMetricsWithExpressionsBodyParams

type QueryMetricsWithExpressionsBodyParams struct {
	// in:body
	// required:true
	Body dtos.MetricRequest `json:"body"`
}

swagger:parameters queryMetricsWithExpressions

type QueryMetricsWithExpressionsRespons

type QueryMetricsWithExpressionsRespons struct {
	// The response message
	// in: body
	Body *backend.QueryDataResponse `json:"body"`
}

swagger:response queryMetricsWithExpressionsRespons

type RemoveOrgUserForCurrentOrgParams

type RemoveOrgUserForCurrentOrgParams struct {
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters removeOrgUserForCurrentOrg

type RemoveOrgUserParams

type RemoveOrgUserParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters removeOrgUser

type RemoveTeamMemberParams

type RemoveTeamMemberParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters removeTeamMember

type RenderReportPDFParams

type RenderReportPDFParams struct {
	// in:path
	DashboardID int64
}

swagger:parameters renderReportPDF

type RestoreDashboardVersionByIDParams

type RestoreDashboardVersionByIDParams struct {
	// in:body
	// required:true
	Body dtos.RestoreDashboardVersionCommand
	// in:path
	DashboardID int64
}

swagger:parameters restoreDashboardVersionByID

type RestoreDashboardVersionByUIDParams

type RestoreDashboardVersionByUIDParams struct {
	// in:body
	// required:true
	Body dtos.RestoreDashboardVersionCommand
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters restoreDashboardVersionByUID

type RevokeInviteParams

type RevokeInviteParams struct {
	// in:path
	// required:true
	Code string `json:"invitation_code"`
}

swagger:parameters revokeInvite

type RevokeUserAuthTokenParams

type RevokeUserAuthTokenParams struct {
	// in:body
	// required:true
	Body auth.RevokeAuthTokenCmd `json:"body"`
}

swagger:parameters revokeUserAuthToken

type SMTPNotEnabledError

type SMTPNotEnabledError PreconditionFailedError

swagger:response SMTPNotEnabledError

type SearchDashboardSnapshotsResponse

type SearchDashboardSnapshotsResponse struct {
	// in:body
	Body []*dashboardsnapshots.DashboardSnapshotDTO `json:"body"`
}

swagger:response searchDashboardSnapshotsResponse

type SearchOrgParams

type SearchOrgParams struct {
	// in:query
	// required:false
	// default: 1
	Page int `json:"page"`
	// Number of items per page
	// The totalCount field in the response can be used for pagination list E.g. if totalCount is equal to 100 teams and the perpage parameter is set to 10 then there are 10 pages of teams.
	// in:query
	// required:false
	// default: 1000
	PerPage int    `json:"perpage"`
	Name    string `json:"name"`
	// If set it will return results where the query value is contained in the name field. Query values with spaces need to be URL encoded.
	// required:false
	Query string `json:"query"`
}

swagger:parameters searchOrgs

type SearchOrgUsersParams

type SearchOrgUsersParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters searchOrgUsers

type SearchOrgUsersResponse

type SearchOrgUsersResponse struct {
	// The response message
	// in: body
	Body *org.SearchOrgUsersQueryResult `json:"body"`
}

swagger:response searchOrgUsersResponse

type SearchOrgsResponse

type SearchOrgsResponse struct {
	// The response message
	// in: body
	Body []*org.OrgDTO `json:"body"`
}

swagger:response searchOrgsResponse

type SearchParams

type SearchParams struct {
	// Search Query
	// in:query
	// required: false
	Query string `json:"query"`
	// List of tags to search for
	// in:query
	// required: false
	// type: array
	// collectionFormat: multi
	Tag []string `json:"tag"`
	// Type to search for, dash-folder or dash-db
	// in:query
	// required: false
	// Description:
	// * `dash-folder` - Search for folder
	// * `dash-db` - Seatch for dashboard
	// Enum: dash-folder,dash-db
	Type string `json:"type"`
	// List of dashboard id’s to search for
	// in:query
	// required: false
	DashboardIds []int64 `json:"dashboardIds"`
	// List of dashboard uid’s to search for
	// in:query
	// required: false
	DashboardUIDs []string `json:"dashboardUIDs"`
	// List of folder id’s to search in for dashboards
	// in:query
	// required: false
	FolderIds []int64 `json:"folderIds"`
	// Flag indicating if only starred Dashboards should be returned
	// in:query
	// required: false
	Starred bool `json:"starred"`
	// Limit the number of returned results (max 5000)
	// in:query
	// required: false
	Limit int64 `json:"limit"`
	// Use this parameter to access hits beyond limit. Numbering starts at 1. limit param acts as page size. Only available in Grafana v6.2+.
	// in:query
	// required: false
	Page int64 `json:"page"`
	// Set to `Edit` to return dashboards/folders that the user can edit
	// in:query
	// required: false
	// default:View
	// Enum: Edit,View
	Permission string `json:"permission"`
	// Sort method; for listing all the possible sort methods use the search sorting endpoint.
	// in:query
	// required: false
	// default: alpha-asc
	// Enum: alpha-asc,alpha-desc
	Sort string `json:"sort"`
}

swagger:parameters search

type SearchPlaylistsParams

type SearchPlaylistsParams struct {
	// in:query
	// required:false
	Query string `json:"query"`
	// in:limit
	// required:false
	Limit int `json:"limit"`
}

swagger:parameters searchPlaylists

type SearchPlaylistsResponse

type SearchPlaylistsResponse struct {
	// The response message
	// in: body
	Body playlist.Playlists `json:"body"`
}

swagger:response searchPlaylistsResponse

type SearchResponse

type SearchResponse struct {
	// in: body
	Body model.HitList `json:"body"`
}

swagger:response searchResponse

type SearchTeamsParams

type SearchTeamsParams struct {
	// in:query
	// required:false
	// default: 1
	Page int `json:"page"`
	// Number of items per page
	// The totalCount field in the response can be used for pagination list E.g. if totalCount is equal to 100 teams and the perpage parameter is set to 10 then there are 10 pages of teams.
	// in:query
	// required:false
	// default: 1000
	PerPage int    `json:"perpage"`
	Name    string `json:"name"`
	// If set it will return results where the query value is contained in the name field. Query values with spaces need to be URL encoded.
	// required:false
	Query string `json:"query"`
}

swagger:parameters searchTeams

type SearchTeamsResponse

type SearchTeamsResponse struct {
	// The response message
	// in: body
	Body team.SearchTeamQueryResult `json:"body"`
}

swagger:response searchTeamsResponse

type SearchUsersParams

type SearchUsersParams struct {
	// Limit the maximum number of users to return per page
	// in:query
	// required:false
	// default:1000
	Limit int64 `json:"perpage"`
	// Page index for starting fetching users
	// in:query
	// required:false
	// default:1
	Page int64 `json:"page"`
}

swagger:parameters searchUsers

type SearchUsersResponse

type SearchUsersResponse struct {
	// The response message
	// in: body
	Body user.SearchUserQueryResult `json:"body"`
}

swagger:response searchUsersResponse

type SearchUsersWithPagingParams

type SearchUsersWithPagingParams struct {
	// Limit the maximum number of users to return per page
	// in:query
	// required:false
	// default:1000
	Limit int64 `json:"perpage"`
	// Page index for starting fetching users
	// in:query
	// required:false
	// default:1
	Page int64 `json:"page"`
	// Query allows return results where the query value is contained in one of the name, login or email fields. Query values with spaces need to be URL encoded e.g. query=Jane%20Doe
	// in:query
	// required:false
	Query string `json:"query"`
}

type ServerOptions

type ServerOptions struct {
	Listener net.Listener
}

type SetHelpFlagParams

type SetHelpFlagParams struct {
	// in:path
	// required:true
	FlagID string `json:"flag_id"`
}

swagger:parameters setHelpFlag

type SuccessResponseBody

type SuccessResponseBody struct {
	Message string `json:"message,omitempty"`
}

swagger:model

type TestAlertParams

type TestAlertParams struct {
	// in:body
	Body dtos.AlertTestCommand `json:"body"`
}

swagger:parameters testAlert

type TestAlertResponse

type TestAlertResponse struct {
	// The response message
	// in: body
	Body *dtos.AlertTestResult `json:"body"`
}

swagger:response testAlertResponse

type TrimDashboardParams

type TrimDashboardParams struct {
	// in:body
	// required:true
	Body dashboards.TrimDashboardCommand
}

swagger:parameters trimDashboard

type TrimDashboardResponse

type TrimDashboardResponse struct {
	// in: body
	Body dtos.TrimDashboardFullWithMeta `json:"body"`
}

swagger:response trimDashboardResponse

type UnauthorizedError

type UnauthorizedError GenericError

UnauthorizedError is returned when the request is not authenticated.

swagger:response unauthorisedError

type UnprocessableEntityError

type UnprocessableEntityError GenericError

UnprocessableEntityError

swagger:response unprocessableEntityError

type UpdateAlertNotificationChannelByUIDParams

type UpdateAlertNotificationChannelByUIDParams struct {
	// in:body
	// required:true
	Body alertmodels.UpdateAlertNotificationWithUidCommand `json:"body"`
	// in:path
	// required:true
	NotificationUID string `json:"notification_channel_uid"`
}

swagger:parameters updateAlertNotificationChannelByUID

type UpdateAlertNotificationChannelParams

type UpdateAlertNotificationChannelParams struct {
	// in:body
	// required:true
	Body alertmodels.UpdateAlertNotificationCommand `json:"body"`
	// in:path
	// required:true
	NotificationID int64 `json:"notification_channel_id"`
}

swagger:parameters updateAlertNotificationChannel

type UpdateAnnotationParams

type UpdateAnnotationParams struct {
	// in:path
	// required:true
	AnnotationID string `json:"annotation_id"`
	// in:body
	// required:true
	Body dtos.UpdateAnnotationsCmd `json:"body"`
}

swagger:parameters updateAnnotation

type UpdateCurrentOrgAddressParams

type UpdateCurrentOrgAddressParams struct {
	// in:body
	// required:true
	Body dtos.UpdateOrgAddressForm `json:"body"`
}

swagger:parameters updateCurrentOrgAddress

type UpdateCurrentOrgParams

type UpdateCurrentOrgParams struct {
	// in:body
	// required:true
	Body dtos.UpdateOrgForm `json:"body"`
}

swagger:parameters updateCurrentOrg

type UpdateCurrentOrgUserParams

type UpdateCurrentOrgUserParams struct {
	// in:body
	// required:true
	Body org.UpdateOrgUserCommand `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateCurrentOrgUser

type UpdateDashboardPermissionsByIDParams

type UpdateDashboardPermissionsByIDParams struct {
	// in:body
	// required:true
	Body dtos.UpdateDashboardACLCommand
	// in:path
	DashboardID int64
}

swagger:parameters updateDashboardPermissionsByID

type UpdateDashboardPermissionsByUIDParams

type UpdateDashboardPermissionsByUIDParams struct {
	// in:body
	// required:true
	Body dtos.UpdateDashboardACLCommand
	// in:path
	// required:true
	// description: The dashboard UID
	UID string `json:"uid"`
}

swagger:parameters updateDashboardPermissionsByUID

type UpdateDataSourceByIDParams

type UpdateDataSourceByIDParams struct {
	// in:body
	// required:true
	Body datasources.UpdateDataSourceCommand
	// in:path
	// required:true
	DatasourceID string `json:"id"`
}

swagger:parameters updateDataSourceByID

type UpdateDataSourceByUIDParams

type UpdateDataSourceByUIDParams struct {
	// in:body
	// required:true
	Body datasources.UpdateDataSourceCommand
	// in:path
	// required:true
	DatasourceUID string `json:"uid"`
}

swagger:parameters updateDataSourceByUID

type UpdateFolderParams

type UpdateFolderParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
	// To change the unique identifier (uid), provide another one.
	// To overwrite an existing folder with newer version, set `overwrite` to `true`.
	// Provide the current version to safelly update the folder: if the provided version differs from the stored one the request will fail, unless `overwrite` is `true`.
	//
	// in:body
	// required:true
	Body folder.UpdateFolderCommand `json:"body"`
}

swagger:parameters updateFolder

type UpdateFolderPermissionsParams

type UpdateFolderPermissionsParams struct {
	// in:path
	// required:true
	FolderUID string `json:"folder_uid"`
	// in:body
	// required:true
	Body dtos.UpdateDashboardACLCommand
}

swagger:parameters updateFolderPermissions

type UpdateOrgAddressParams

type UpdateOrgAddressParams struct {
	// in:body
	// required:true
	Body dtos.UpdateOrgAddressForm `json:"body"`
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters updateOrgAddress

type UpdateOrgParams

type UpdateOrgParams struct {
	// in:body
	// required:true
	Body dtos.UpdateOrgForm `json:"body"`
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters updateOrg

type UpdateOrgPreferencesParams

type UpdateOrgPreferencesParams struct {
	// in:body
	// required:true
	Body dtos.UpdatePrefsCmd `json:"body"`
}

swagger:parameters updateOrgPreferences

type UpdateOrgQuotaParam

type UpdateOrgQuotaParam struct {
	// in:body
	// required:true
	Body quota.UpdateQuotaCmd `json:"body"`
	// in:path
	// required:true
	QuotaTarget string `json:"quota_target"`
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters updateOrgQuota

type UpdateOrgUserForCurrentOrgParams

type UpdateOrgUserForCurrentOrgParams struct {
	// in:body
	// required:true
	Body org.UpdateOrgUserCommand `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateOrgUserForCurrentOrg

type UpdateOrgUserParams

type UpdateOrgUserParams struct {
	// in:body
	// required:true
	Body org.UpdateOrgUserCommand `json:"body"`
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateOrgUser

type UpdatePlaylistParams

type UpdatePlaylistParams struct {
	// in:body
	// required:true
	Body playlist.UpdatePlaylistCommand
	// in:path
	// required:true
	UID string `json:"uid"`
}

swagger:parameters updatePlaylist

type UpdatePlaylistResponse

type UpdatePlaylistResponse struct {
	// The response message
	// in: body
	Body *playlist.PlaylistDTO `json:"body"`
}

swagger:response updatePlaylistResponse

type UpdateSignedInUserParams

type UpdateSignedInUserParams struct {
	// To change the email, name, login, theme, provide another one.
	// in:body
	// required:true
	Body user.UpdateUserCommand `json:"body"`
}

swagger:parameters updateSignedInUser

type UpdateTeamMemberParams

type UpdateTeamMemberParams struct {
	// in:body
	// required:true
	Body team.UpdateTeamMemberCommand `json:"body"`
	// in:path
	// required:true
	TeamID string `json:"team_id"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateTeamMember

type UpdateTeamParams

type UpdateTeamParams struct {
	// in:body
	// required:true
	Body team.UpdateTeamCommand `json:"body"`
	// in:path
	// required:true
	TeamID string `json:"team_id"`
}

swagger:parameters updateTeam

type UpdateTeamPreferencesParams

type UpdateTeamPreferencesParams struct {
	// in:path
	// required:true
	TeamID string `json:"team_id"`
	// in:body
	// required:true
	Body dtos.UpdatePrefsCmd `json:"body"`
}

swagger:parameters updateTeamPreferences

type UpdateUserParams

type UpdateUserParams struct {
	// To change the email, name, login, theme, provide another one.
	// in:body
	// required:true
	Body user.UpdateUserCommand `json:"body"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateUser

type UpdateUserPreferencesParams

type UpdateUserPreferencesParams struct {
	// in:body
	// required:true
	Body dtos.UpdatePrefsCmd `json:"body"`
}

swagger:parameters updateUserPreferences

type UpdateUserQuotaParams

type UpdateUserQuotaParams struct {
	// in:body
	// required:true
	Body quota.UpdateQuotaCmd `json:"body"`
	// in:path
	// required:true
	QuotaTarget string `json:"quota_target"`
	// in:path
	// required:true
	UserID int64 `json:"user_id"`
}

swagger:parameters updateUserQuota

type UserResponse

type UserResponse struct {
	// The response message
	// in: body
	Body user.UserProfileDTO `json:"body"`
}

swagger:response userResponse

type UserSetUsingOrgParams

type UserSetUsingOrgParams struct {
	// in:path
	// required:true
	OrgID int64 `json:"org_id"`
}

swagger:parameters userSetUsingOrg

type ValidateDashboardResponse

type ValidateDashboardResponse struct {
	IsValid bool   `json:"isValid"`
	Message string `json:"message,omitempty"`
}

swagger:response validateDashboardResponse

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL