binance

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2025 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithSamples

func WithSamples(useSamples bool) func(*Parser)

func WithSamplesDir

func WithSamplesDir(samplesDir string) func(*Parser)

Types

type DocumentParser

type DocumentParser struct {
	// contains filtered or unexported fields
}

DocumentParser implements the HTTPDocumentParser interface for Binance WebSocket API

func (*DocumentParser) Parse

func (p *DocumentParser) Parse(r io.Reader, urlEntity *config.URLEntity, protectedMethods []string) ([]parser.Channel, error)

Parse parses the Binance WebSocket API documentation and extracts method information

type Parser

type Parser struct {
	parser.HTTPParser
}

Parser implements the websocket parser.Parser interface for Binance WebSocket API

func NewParser

func NewParser(opts ...func(*Parser)) *Parser

NewParser creates a new Binance WebSocket parser

func (*Parser) CheckVersion

func (p *Parser) CheckVersion(ctx context.Context, doc parser.Documentation) (bool, time.Time, error)

CheckVersion checks if the WebSocket documentation has been updated

type SpotDocumentParser

type SpotDocumentParser struct {
	*DocumentParser
}

SpotDocumentParser implements the HTTPDocumentParser interface for Binance Spot WebSocket API

func (*SpotDocumentParser) Parse

func (p *SpotDocumentParser) Parse(r io.Reader, urlEntity *config.URLEntity, protectedMethods []string) ([]parser.Channel, error)

Parse parses the Binance Spot WebSocket API documentation and extracts method information

type UmfuturesDocumentParser

type UmfuturesDocumentParser struct {
	*SpotDocumentParser
}

UmfuturesDocumentParser implements the HTTPDocumentParser interface for Binance USD-M Futures WebSocket API

func (*UmfuturesDocumentParser) Parse

func (p *UmfuturesDocumentParser) Parse(r io.Reader, urlEntity *config.URLEntity, protectedMethods []string) ([]parser.Channel, error)

Parse parses the Binance USD-M Futures WebSocket API documentation and extracts method information

Jump to

Keyboard shortcuts

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