1
0
mirror of https://github.com/JKorf/CryptoExchange.Net.git synced 2026-10-15 15:40:52 +00:00
Files
CryptoExchange.Net/CryptoExchange.Net/SharedApis/Interfaces/Legacy/Socket/IBalanceSocketClient.cs
T
Jkorf d93d6b7a2e wip
2026-08-26 14:26:24 +02:00

29 lines
1022 B
C#

using CryptoExchange.Net.Objects;
using CryptoExchange.Net.Objects.Sockets;
using System;
using System.Threading;
using System.Threading.Tasks;
namespace CryptoExchange.Net.SharedApis
{
/// <summary>
/// Client for subscribing to user balance updates
/// </summary>
public interface IBalanceSocketClient : ISharedClient
{
/// <summary>
/// Balance subscription options
/// </summary>
SubscribeBalanceOptions SubscribeBalanceOptions { get; }
/// <summary>
/// Subscribe to user balance updates
/// </summary>
/// <param name="request">Request info</param>
/// <param name="handler">Update handler</param>
/// <param name="ct">Cancellation token, can be used to stop the updates</param>
/// <returns></returns>
Task<WebSocketResult<UpdateSubscription>> SubscribeToBalanceUpdatesAsync(SubscribeBalancesRequest request, Action<DataEvent<SharedBalance[]>> handler, CancellationToken ct = default);
}
}