openWork

package
v3.2.5 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MapUserConfig

func MapUserConfig(userConfig *UserConfig) (*object.HashMap, error)

Types

type Http added in v3.0.40

type Http struct {
	Timeout  float64
	BaseURI  string
	ProxyURI string
}

type Log

type Log struct {
	Driver contract.LoggerInterface
	Level  string
	File   string
	Error  string
	ENV    string
}

type OAuth

type OAuth struct {
	Callback string
	Scopes   []string
}

type OpenWork

type OpenWork struct {
	*kernel.ServiceContainer

	Base             *base.Client
	Server           *server.Guard
	User             *user.Client
	ExternalContact  *externalcontact.Client
	Suite            *suit.Client
	SuiteAccessToken *suit.AccessToken
	SuiteTicket      *suit.SuiteTicket

	Encryptor *kernel.Encryptor
	Config    *kernel.Config
	Logger    *logger.Logger
}

func NewOpenWork

func NewOpenWork(config *UserConfig) (*OpenWork, error)

func (*OpenWork) GetAccessToken

func (app *OpenWork) GetAccessToken() *kernel.AccessToken

func (*OpenWork) GetComponent

func (app *OpenWork) GetComponent(name string) interface{}

func (*OpenWork) GetConfig

func (app *OpenWork) GetConfig() *kernel.Config

func (*OpenWork) GetContainer

func (app *OpenWork) GetContainer() *kernel.ServiceContainer

func (*OpenWork) License added in v3.2.0

func (app *OpenWork) License(corpID string) (*license.Client, error)

func (*OpenWork) Provider

func (app *OpenWork) Provider(corpID string) (*provider.Client, error)

type UserConfig

type UserConfig struct {
	AppID          string
	Secret         string
	ProviderCorpID string
	ProviderSecret string
	AuthCode       string
	Token          string
	AESKey         string

	ResponseType string
	Log          Log
	OAuth        OAuth
	Cache        kernel.CacheInterface

	Http Http

	HttpDebug bool
	Debug     bool
	NotifyURL string
	Sandbox   bool
}

Jump to

Keyboard shortcuts

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