tgbot

package
v0.0.0-...-7392893 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2022 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RuLanguageCode = "ru"
)

Variables

This section is empty.

Functions

func DetectIntentText

func DetectIntentText(ctx context.Context, projectID, sessionID, text, languageCode string) (string, error)

func New

func New(config *Config) *tgBot

Types

type Config

type Config struct {
	GoogleApplicationCredentials string `toml:"google_application_credentials"`
	GoogleCloudProjectID         string `toml:"google_cloud_project_id"`
	LogLevel                     string `toml:"log_level"`
	TelegramApiToken             string `toml:"telegram_api_token"`
}

func NewConfig

func NewConfig() *Config

func (*Config) LoadFromEnv

func (c *Config) LoadFromEnv() error

Jump to

Keyboard shortcuts

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