Skip to main content

Module credential

Module credential 

Source
Expand description

Binance API credential handling and request signing.

This module provides two types of credentials:

  • Credential: HMAC SHA256 signing for REST API and standard WebSocket
  • Ed25519Credential: Ed25519 signing for WebSocket API and SBE streams

Credentials are resolved from standard environment variables (BINANCE_API_KEY/BINANCE_API_SECRET). The deprecated *_ED25519_* variables are no longer supported and will produce a clear error.

Structs§

Credential
Binance API credentials for signing requests (HMAC SHA256).
Ed25519Credential
Binance Ed25519 credentials for WebSocket API authentication.

Enums§

Ed25519CredentialError
Error type for Ed25519 credential creation.
SigningCredential
Unified signing credential that auto-detects Ed25519 vs HMAC key type.

Functions§

resolve_credentials
Resolves API credentials from config or environment variables.