useractions

package
v0.0.0-...-e28bd7b Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2024 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Session(actor, emulator string, isAdmin bool) (Session, error)
}

Client is an interface for interacting with the UserAction microservice. Implementations of this interface should encapsulate information necessary to interact with the microservice, such as Nats and Stan connection information.

func New

New creates a new UserActions microservice client.

type Session

type Session interface {
	ListUserActions() ([]cacao_common_http.UserAction, error)
	GetUserAction(userActionID cacao_common.ID) (cacao_common_http.UserAction, error)

	CreateUserAction(creationRequest cacao_common_http.UserAction) (cacao_common.ID, error)
	ValidateUserActionCreationRequest(creationRequest cacao_common_http.UserAction) error
	UpdateUserAction(userActionID cacao_common.ID, updateRequest cacao_common_http.UserAction) (cacao_common.ID, error)
	ValidateUserActionUpdateRequest(userActionID cacao_common.ID, updateRequest cacao_common_http.UserAction) error
	UpdateUserActionFields(userActionID cacao_common.ID, updateRequest cacao_common_http.UserAction, updateFields []string) (cacao_common.ID, error)
	ValidateUserActionUpdateFieldsRequest(userActionID cacao_common.ID, updateRequest cacao_common_http.UserAction, updateFields []string) error
	DeleteUserAction(userActionID cacao_common.ID) (cacao_common.ID, error)
	ValidateUserActionDeletionRequest(userActionID cacao_common.ID) error
}

Session is an interface for interacting with the UserAction microservice on behalf of a user. The purpose of having a session is to consolidate parameters that are common in all or most requests, but are not known at configuration time.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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