Table of Contents

Class FluxerConfig

Namespace
Fluxer.Net
Assembly
Fluxer.Net.dll

Configuration class for the Fluxer.Net library. Controls behavior for both ApiClient and GatewayClient including endpoints, reconnection, logging, rate limiting, and gateway event handling.

public class FluxerConfig
Inheritance
object
FluxerConfig

Properties

AdminUrl

Get the admin url.

public string AdminUrl { get; set; }

Property Value

string

ApiBaseUrl

Base URL for the Fluxer REST API. The {v} placeholder is replaced with Version. Defaults to "https://api.fluxer.app/v{v}/".

public string ApiBaseUrl { get; set; }

Property Value

string

EnableRateLimiting

Enable client-side rate limiting using a sliding window algorithm. Defaults to true. When enabled, API requests automatically wait when approaching rate limits to prevent 429 responses from the server. See RateLimiting/README.md for details.

public bool EnableRateLimiting { get; set; }

Property Value

bool

GatewaySerilog

Custom Serilog logger configuration for the library. If null, the library will use the application's existing Serilog configuration. Allows for separate log levels and sinks for Fluxer.Net operations.

public ILogger? GatewaySerilog { get; set; }

Property Value

ILogger

GatewayUrl

WebSocket gateway URL for real-time event streaming. Must use JSON encoding. Compression is not currently supported. Defaults to "wss://gateway.fluxer.app/?v=1&encoding=json".

public string GatewayUrl { get; set; }

Property Value

string

GiftUrl

Get the gift url.

public string GiftUrl { get; set; }

Property Value

string

HttpClient

Optional HttpClient instance to use for API requests. If null, a new HttpClient will be created. Providing your own HttpClient allows for connection pooling, custom headers, and proxy configuration.

public HttpClient HttpClient { get; set; }

Property Value

HttpClient

IgnoredGatewayEvents

List of gateway event dispatch types to ignore. Useful for filtering out high-volume events your application doesn't need (e.g., "PRESENCE_UPDATE", "TYPING_START"). Defaults to empty list.

public List<string> IgnoredGatewayEvents { get; set; }

Property Value

List<string>

InviteUrl

Get the invite url.

public string InviteUrl { get; set; }

Property Value

string

MediaUrl

Get the media/user content url.

public string MediaUrl { get; set; }

Property Value

string

Presence

Initial presence data to send when connecting to the gateway. If null, no presence is sent. Allows setting your bot's or user's online status, activity, and other presence information.

public PresenceUpdateGatewayData? Presence { get; set; }

Property Value

PresenceUpdateGatewayData

Proxy

Proxy used for the rest/http client.

public IWebProxy? Proxy { get; set; }

Property Value

IWebProxy

RealApiBaseUrl

Gets the fully resolved API base URL with the version number substituted. This is the actual URL used for API requests.

public string RealApiBaseUrl { get; }

Property Value

string

ReconnectAttemptDelay

Number of seconds to wait between gateway reconnection attempts. Defaults to 10 seconds.

public int ReconnectAttemptDelay { get; set; }

Property Value

int

RestSerilog

Custom Serilog logger configuration for the library. If null, the library will use the application's existing Serilog configuration. Allows for separate log levels and sinks for Fluxer.Net operations.

public ILogger? RestSerilog { get; set; }

Property Value

ILogger

StaticUrl

Get the static content url.

public string StaticUrl { get; set; }

Property Value

string

Version

API version number to use. Defaults to 1, which is currently the only supported version. This value replaces the {v} placeholder in ApiBaseUrl.

public int Version { get; set; }

Property Value

int

WebUrl

Get the web url.

public string WebUrl { get; set; }

Property Value

string