client

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2024 License: Apache-2.0 Imports: 11 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Auth

type Auth[TokenType Token] interface {
	ExchangeUserToken(userid string) (token TokenType, err error)
}

type Client

type Client[TokenType Token] struct {
	// contains filtered or unexported fields
}

func New

func New(apiUrl string, authEndpoint string, authClientId string, authClientSecret string, debug bool) *Client[auth.Token]

func NewWithAuth

func NewWithAuth(apiUrl string, a Auth[auth.Token], debug bool) *Client[auth.Token]

func NewWithGenericAuth

func NewWithGenericAuth[TokenType Token](apiUrl string, auth Auth[TokenType], debug bool) *Client[TokenType]

func (*Client[TokenType]) Bulk

func (this *Client[TokenType]) Bulk(userid string, bulk model.BulkRequest) (outputs model.BulkResponse, err error)

func (*Client[TokenType]) Count

func (this *Client[TokenType]) Count(userid string, query model.VariablesQueryOptions) (result model.Count, err error)

func (*Client[TokenType]) Delete

func (this *Client[TokenType]) Delete(userid string, key string) error

func (*Client[TokenType]) DeleteProcessDefinition

func (this *Client[TokenType]) DeleteProcessDefinition(userid string, definitionId string) error

func (*Client[TokenType]) DeleteProcessInstance

func (this *Client[TokenType]) DeleteProcessInstance(userid string, instanceId string) error

func (*Client[TokenType]) Get

func (this *Client[TokenType]) Get(userid string, key string) (value model.VariableWithUnixTimestamp, err error)

func (*Client[TokenType]) List

func (this *Client[TokenType]) List(userid string, query model.VariablesQueryOptions) (result []model.VariableWithUnixTimestamp, err error)

func (*Client[TokenType]) Set

func (this *Client[TokenType]) Set(userid string, variable model.Variable) (err error)

type Token

type Token interface {
	Jwt() string
	IsAdmin() bool
	GetUserId() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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