confirmation_control_api

package
v0.0.0-...-8122643 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const CallbackResource string = "callback"
View Source
const ConfirmationCacheKey = "confirmation_service"
View Source
const FailedResource string = "failed"
View Source
const OperationResource string = "operation"
View Source
const ServiceName string = "confirmation"

Variables

This section is empty.

Functions

func CallbackConfirmation

func CallbackConfirmation() api.Operation

func CheckConfirmation

func CheckConfirmation() api.Operation

func DeleteTokenFromCache

func DeleteTokenFromCache(ctx auth.AuthContext)

func FailedConfirmation

func FailedConfirmation() api.Operation

func OperationIdCacheKey

func OperationIdCacheKey(operationId string) string

func PrepareCheckConfirmation

func PrepareCheckConfirmation() api.Operation

func PrepareOperation

func PrepareOperation() api.Operation

Types

type CallbackConfirmationCmd

type CallbackConfirmationCmd struct {
	Id string `json:"operation_id" validate:"required,id" vmessage:"Invalid operation ID"`
	confirmation_control.ConfirmationResult
}

type CallbackConfirmationResponse

type CallbackConfirmationResponse struct {
	api.ResponseStub
	Url string `json:"url"`
}

type CheckConfirmationResponse

type CheckConfirmationResponse struct {
	api.ResponseStub
	RedirectUrl string `json:"redirect_url"`
}

type OperationCacheToken

type OperationCacheToken struct {
	Id         string                 `json:"id"`
	Recipient  string                 `json:"recipient"`
	FailedUrl  string                 `json:"failed_url"`
	Parameters map[string]interface{} `json:"parameters"`
}

func GetTokenFromCache

func GetTokenFromCache(ctx auth.AuthContext) (*OperationCacheToken, error)

type PrepareCheckConfirmationResponse

type PrepareCheckConfirmationResponse struct {
	api.ResponseStub
	CodeInBody bool                   `json:"code_in_body"`
	FailedUrl  string                 `json:"failed_url"`
	Parameters map[string]interface{} `json:"parameters"`
}

type PrepareOperationCmd

type PrepareOperationCmd struct {
	Id         string                 `json:"id" validate:"required,id" vmessage:"Operation ID must be specified"`
	Recipient  string                 `json:"recipient" validate:"required" vmessage:"Recipient must be specified"`
	FailedUrl  string                 `json:"failed_url" validate:"required,url" vmessage:"Invalid format of failed URL"`
	Parameters map[string]interface{} `json:"parameters"`
	Ttl        int                    `json:"ttl"`
}

type PrepareOperationResponse

type PrepareOperationResponse struct {
	api.ResponseStub
	Url string `json:"url"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL