Files
grafana/pkg/services/cloudmigration/cloudmigration.go
grafana-delivery-bot[bot] 0fe31d86fc [v11.0.x] Cloud migrations: create endpoint to create an access token (#86137)
Cloud migrations: create endpoint to create an access token (#84690)

* fix merge conflicts

* make token expiration configurable

(cherry picked from commit a2e21eac8c)

Co-authored-by: Bruno <brunotj2015@hotmail.com>
2024-04-15 14:53:53 +01:00

21 lines
851 B
Go

package cloudmigration
import (
"context"
)
type Service interface {
CreateToken(context.Context) (CreateAccessTokenResponse, error)
ValidateToken(context.Context, string) error
SaveEncryptedToken(context.Context, string) error
// migration
GetMigration(context.Context, int64) (*CloudMigrationResponse, error)
GetMigrationList(context.Context) ([]CloudMigrationResponse, error)
CreateMigration(context.Context, CloudMigrationRequest) (*CloudMigrationResponse, error)
UpdateMigration(context.Context, int64, CloudMigrationRequest) (*CloudMigrationResponse, error)
RunMigration(context.Context, string) (*CloudMigrationRun, error)
GetMigrationStatus(context.Context, string, string) (*CloudMigrationRun, error)
GetMigrationStatusList(context.Context, string) ([]CloudMigrationRun, error)
DeleteMigration(context.Context, string) error
}