mirror of
https://github.com/discountry/ritmex-bot.git
synced 2026-09-09 08:18:07 +00:00
refactor: restructure aster/ to match standard exchange directory layout
- Move aster-adapter.ts → aster/adapter.ts (consistent with all other exchanges) - Rename aster/client.ts → aster/gateway.ts (consistent naming) - Update all imports across 5 files - Delete old aster-adapter.ts
This commit is contained in:
@@ -6,10 +6,10 @@ import type {
|
||||
KlineListener,
|
||||
OrderListener,
|
||||
TickerListener,
|
||||
} from "./adapter";
|
||||
import type { Order, CreateOrderParams, Depth, Ticker, Kline } from "./types";
|
||||
import { extractMessage } from "../utils/errors";
|
||||
import { AsterGateway } from "./aster/client";
|
||||
} from "../adapter";
|
||||
import type { Order, CreateOrderParams, Depth, Ticker, Kline } from "../types";
|
||||
import { extractMessage } from "../../utils/errors";
|
||||
import { AsterGateway } from "./gateway";
|
||||
|
||||
export interface AsterCredentials {
|
||||
apiKey?: string;
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { ExchangeAdapter } from "./adapter";
|
||||
import { AsterExchangeAdapter, type AsterCredentials } from "./aster-adapter";
|
||||
import { AsterExchangeAdapter, type AsterCredentials } from "./aster/adapter";
|
||||
import { GrvtExchangeAdapter, type GrvtCredentials } from "./grvt/adapter";
|
||||
import { LighterExchangeAdapter, type LighterCredentials } from "./lighter/adapter";
|
||||
import { BackpackExchangeAdapter, type BackpackCredentials } from "./backpack/adapter";
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { ExchangeAdapter } from "./adapter";
|
||||
import { createExchangeAdapter, resolveExchangeId, type SupportedExchangeId } from "./create-adapter";
|
||||
import type { AsterCredentials } from "./aster-adapter";
|
||||
import type { AsterCredentials } from "./aster/adapter";
|
||||
import type { LighterCredentials } from "./lighter/adapter";
|
||||
import type { BackpackCredentials } from "./backpack/adapter";
|
||||
import type { ParadexCredentials } from "./paradex/adapter";
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { BasisArbConfig } from "../config";
|
||||
import type { ExchangeAdapter, FundingRateSnapshot } from "../exchanges/adapter";
|
||||
import type { AccountSnapshot, Depth, AsterSpotBookTicker } from "../exchanges/types";
|
||||
import { AsterSpotRestClient, AsterRestClient } from "../exchanges/aster/client";
|
||||
import { AsterSpotRestClient, AsterRestClient } from "../exchanges/aster/gateway";
|
||||
import { createTradeLog, type TradeLogEntry } from "../logging/trade-log";
|
||||
import { StrategyEventEmitter } from "./common/event-emitter";
|
||||
import { safeSubscribe, type LogHandler } from "./common/subscriptions";
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import crypto from "crypto";
|
||||
import { afterAll, afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
|
||||
import { AsterSpotRestClient } from "../src/exchanges/aster/client";
|
||||
import { AsterSpotRestClient } from "../src/exchanges/aster/gateway";
|
||||
|
||||
describe("AsterSpotRestClient", () => {
|
||||
const originalFetch = globalThis.fetch;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it, beforeEach, afterEach } from "vitest";
|
||||
import { createExchangeAdapter, resolveExchangeId } from "../src/exchanges/create-adapter";
|
||||
import { AsterExchangeAdapter } from "../src/exchanges/aster-adapter";
|
||||
import { AsterExchangeAdapter } from "../src/exchanges/aster/adapter";
|
||||
import { GrvtExchangeAdapter } from "../src/exchanges/grvt/adapter";
|
||||
import { BackpackExchangeAdapter } from "../src/exchanges/backpack/adapter";
|
||||
import { ParadexExchangeAdapter } from "../src/exchanges/paradex/adapter";
|
||||
|
||||
Reference in New Issue
Block a user