Skip to content

add trade stream for ApolloX #748

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions src/ExchangeSharp/API/Exchanges/ApolloX/ExchangeApolloXApi.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
using ExchangeSharp.BinanceGroup;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ExchangeSharp
{
public sealed partial class ExchangeApolloXApi : BinanceGroupCommon
{
public override string BaseUrl { get; set; } = "https://fapi.apollox.finance";
public override string BaseUrlWebSocket { get; set; } = "wss://fstream.apollox.finance";

public override string BaseUrlApi => $"{BaseUrl}/fapi/v1";
}

public partial class ExchangeName { public const string ApolloX = "ApolloX"; }
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace ExchangeSharp.BinanceGroup
{
public abstract class BinanceGroupCommon : ExchangeAPI
{
public string BaseUrlApi => $"{BaseUrl}/api/v3";
public virtual string BaseUrlApi => $"{BaseUrl}/api/v3";

public string BaseUrlSApi => $"{BaseUrl}/sapi/v1";

Expand Down Expand Up @@ -53,6 +53,7 @@ protected BinanceGroupCommon()
NonceStyle = NonceStyle.UnixMilliseconds;
NonceOffset = TimeSpan.FromSeconds(15); // 15 seconds are deducted from current UTCTime as base of the request time window
MarketSymbolSeparator = string.Empty;
MarketSymbolIsUppercase = false;
WebSocketOrderBookType = WebSocketOrderBookType.DeltasOnly;
ExchangeGlobalCurrencyReplacements["BCC"] = "BCH";
}
Expand Down