From cf397af3abcba6e6c079392ab91db077b6ef7538 Mon Sep 17 00:00:00 2001 From: Jkorf Date: Tue, 21 Jan 2025 13:47:05 +0100 Subject: [PATCH] Added GetMillisecondTimestampLong helper method to AuthenticationProvider --- .../Authentication/AuthenticationProvider.cs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CryptoExchange.Net/Authentication/AuthenticationProvider.cs b/CryptoExchange.Net/Authentication/AuthenticationProvider.cs index 533475a..c2ca2e4 100644 --- a/CryptoExchange.Net/Authentication/AuthenticationProvider.cs +++ b/CryptoExchange.Net/Authentication/AuthenticationProvider.cs @@ -443,6 +443,16 @@ namespace CryptoExchange.Net.Authentication return DateTimeConverter.ConvertToMilliseconds(GetTimestamp(apiClient)).Value.ToString(CultureInfo.InvariantCulture); } + /// + /// Get millisecond timestamp as a long including the time sync offset from the api client + /// + /// + /// + protected long GetMillisecondTimestampLong(RestApiClient apiClient) + { + return DateTimeConverter.ConvertToMilliseconds(GetTimestamp(apiClient)).Value; + } + /// /// Return the serialized request body ///