storage

package
v0.0.0-...-b50a3cc Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUserExists         = errors.New("user already exists")
	ErrNoCollectionsFound = errors.New("no collections found for the user")
)

Functions

func New

func New(url string) (*sqlx.DB, error)

Types

type Collection

type Collection struct {
	ID     string `json:"id"`
	Symbol string `json:"symbol"`
}

type CollectionDTO

type CollectionDTO struct {
	TelegramID int64  `json:"telegram_id"`
	Symbol     string `json:"symbol"`
}

type User

type User struct {
	ID         string `json:"id"`
	TelegramID string `json:"telegram_id"`
	CreatedAt  string `json:"created_at"`
}

type UserDTO

type UserDTO struct {
	TelegramID int64 `json:"telegram_id"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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