Skip to content
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
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,13 +242,13 @@ console.log(version, Object.keys(exchanges));

All-in-one browser bundle (dependencies included), served from a CDN of your choice:

- jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.16.0/dist/ccxt.browser.min.js
- unpkg: https://unpkg.com/ccxt@4.16.0/dist/ccxt.browser.min.js
- jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.16.1/dist/ccxt.browser.min.js
- unpkg: https://unpkg.com/ccxt@4.16.1/dist/ccxt.browser.min.js

CDNs are not updated in real-time and may have delays. Defaulting to the most recent version without specifying the version number is not recommended. Please, keep in mind that we are not responsible for the correct operation of those CDN servers.

```HTML
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.16.0/dist/ccxt.browser.min.js"></script>
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.16.1/dist/ccxt.browser.min.js"></script>
console.log (ccxt.exchanges) // print all available exchanges
```

Expand Down
2 changes: 1 addition & 1 deletion cs/ccxt/base/Exchange.MetaData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ namespace ccxt;
// file updated automatically by vss and export-exchanges
public partial class Exchange
{
public static string ccxtVersion = "4.16.0";
public static string ccxtVersion = "4.16.1";


public static List<string> exchanges = new List<string> { "abantether", "afratether", "alpaca", "apex", "arzinja", "arzplus", "asacoine", "ascendex", "asretether", "bequant", "bidarz", "bigone", "binance", "binancecoinm", "binanceus", "binanceusdm", "bingx", "bit24", "bit2c", "bitbank", "bitbarg", "bitbns", "bitfinex", "bitflyer", "bitget", "bithumb", "bitimen", "bitir", "bitmart", "bitmex", "bitopro", "bitpin", "bitrue", "bitso", "bitstamp", "bitteam", "bittrade", "bitunix", "bitvavo", "bitwana", "blockchaincom", "blofin", "btcalpha", "btcbox", "btcmarkets", "btcturk", "bybit", "bydfi", "cafearz", "cex", "changefa", "coinbase", "coinbaseadvanced", "coinbaseexchange", "coinbaseinternational", "coincatch", "coincheck", "coinex", "coinmate", "coinmetro", "coinone", "coinsph", "coinspot", "cryptocom", "cryptomus", "defx", "delta", "deribit", "derive", "digifinex", "ellipx", "eterex", "excoino", "exir", "exmo", "exnovin", "farhadexchange", "fmfwio", "foxbit", "gate", "gateio", "gemini", "hamtapay", "hashkey", "hibachi", "hitbtc", "hitobit", "hollaex", "htx", "huobi", "hyperliquid", "independentreserve", "indodax", "iranexchange", "jibitex", "kcex", "kifpoolme", "kraken", "krakenfutures", "kucoin", "kucoinfutures", "latoken", "lbank", "luno", "mazdax", "mercado", "mexc", "modetrade", "myokx", "ndax", "nobitex", "novadax", "oceanex", "okcoin", "okexchange", "okx", "okxus", "ompfinex", "onetrading", "ourbit", "oxfun", "p2b", "paradex", "paymium", "phemex", "pingi", "poloniex", "pooleno", "probit", "raastin", "ramzinex", "saraf", "sarmayex", "sarrafex", "tabdeal", "talasea", "tehran_exchange", "tetherland", "timex", "tokocrypto", "toobit", "tradeogre", "twox", "ubitex", "upbit", "vertex", "wallex", "wavesexchange", "whitebit", "woo", "woofipro", "xt", "yobit", "zaif", "zonda" };
Expand Down
6 changes: 3 additions & 3 deletions cs/ccxt/ccxt.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
<PropertyGroup>
<PackageId>ccxt</PackageId>
<Authors>Carlos, Kroitor, Carlo</Authors>
<PackageVersion>4.16.0</PackageVersion>
<AssemblyVersion>4.16.0</AssemblyVersion>
<FileVersion>4.16.0</FileVersion>
<PackageVersion>4.16.1</PackageVersion>
<AssemblyVersion>4.16.1</AssemblyVersion>
<FileVersion>4.16.1</FileVersion>
<PackageReadmeFile>README.md</PackageReadmeFile>
<Description>Cryptocurrency trading API with support for more than 100 bitcoin/altcoin exchanges</Description>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
Expand Down
82 changes: 65 additions & 17 deletions dist/ccxt.browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -7789,23 +7789,72 @@ class asacoine extends _base_Exchange_js__WEBPACK_IMPORTED_MODULE_0__/* ["defaul
const quoteId = this.safeString(market, 'quoteId');
const base = this.safeCurrencyCode(baseId);
const quote = this.safeCurrencyCode(quoteId);
const isOtc = this.safeString(market, 'type', 'spot') === 'otc';
let marketType = 'spot';
if (isOtc) {
marketType = 'otc';
}
const suffix = '';
return {
'id': baseId + '/' + quoteId + suffix,
'symbol': base + '/' + quote + suffix,
'id': baseId + '/' + quoteId,
'symbol': base + '/' + quote,
'base': base,
'quote': quote,
'settle': undefined,
'baseId': baseId,
'quoteId': quoteId,
'settleId': undefined,
'type': marketType,
'spot': !isOtc,
'type': 'spot',
'spot': true,
'margin': false,
'swap': false,
'future': false,
'option': false,
'active': true,
'contract': false,
'linear': undefined,
'inverse': undefined,
'contractSize': undefined,
'expiry': undefined,
'expiryDatetime': undefined,
'strike': undefined,
'optionType': undefined,
'precision': {
'amount': undefined,
'price': undefined,
},
'limits': {
'leverage': {
'min': undefined,
'max': undefined,
},
'amount': {
'min': undefined,
'max': undefined,
},
'price': {
'min': undefined,
'max': undefined,
},
'cost': {
'min': undefined,
'max': undefined,
},
},
'created': undefined,
'info': this.safeValue(market, 'info', market),
};
}
parseOtcMarket(market) {
const baseId = this.safeString(market, 'baseId');
const quoteId = this.safeString(market, 'quoteId');
const base = this.safeCurrencyCode(baseId);
const quote = this.safeCurrencyCode(quoteId);
return {
'id': baseId + '/' + quoteId,
'symbol': base + '/' + quote,
'base': base,
'quote': quote,
'settle': undefined,
'baseId': baseId,
'quoteId': quoteId,
'settleId': undefined,
'type': 'otc',
'spot': false,
'margin': false,
'swap': false,
'future': false,
Expand Down Expand Up @@ -7856,12 +7905,12 @@ class asacoine extends _base_Exchange_js__WEBPACK_IMPORTED_MODULE_0__/* ["defaul
for (let j = 0; j < quoteIds.length; j++) {
const quoteId = quoteIds[j];
const ticker = this.safeDict(quotes, quoteId, {});
result.push(this.parseMarket({ 'baseId': baseId, 'quoteId': quoteId, 'info': ticker, 'type': 'spot' }));
result.push(this.parseMarket({ 'baseId': baseId, 'quoteId': quoteId, 'info': ticker }));
}
}
return result;
}
parseCumulativeMarkets(response, type = 'otc') {
parseCumulativeMarkets(response) {
const data = this.safeDict(response, 'data', {});
const keys = this.safeList(data, 'keys', []);
const values = this.safeList(data, 'values', []);
Expand All @@ -7873,15 +7922,14 @@ class asacoine extends _base_Exchange_js__WEBPACK_IMPORTED_MODULE_0__/* ["defaul
market[keys[j]] = row[j];
}
const marketTypes = this.safeList(market, 'marketTypes', []);
if (!this.inArray(type, marketTypes)) {
if (!this.inArray('otc', marketTypes)) {
continue;
}
const name = this.safeString(market, 'name');
const [baseId, quoteId] = name.split('-');
market['baseId'] = baseId;
market['quoteId'] = quoteId;
market['type'] = type;
result.push(this.parseMarket(market));
result.push(this.parseOtcMarket(market));
}
return result;
}
Expand All @@ -7898,7 +7946,7 @@ class asacoine extends _base_Exchange_js__WEBPACK_IMPORTED_MODULE_0__/* ["defaul
const request = this.omit(params, ['type']);
if (type === 'otc') {
const cumulativeResponse = await this.publicGetV1MarketPairsCumulative(request);
return this.parseCumulativeMarkets(cumulativeResponse, type);
return this.parseCumulativeMarkets(cumulativeResponse);
}
const response = await this.publicGetV1MarketPairsPricing(request);
return this.parseMarkets(response);
Expand Down Expand Up @@ -434570,7 +434618,7 @@ SOFTWARE.

//-----------------------------------------------------------------------------
// this is updated by vss.js when building
const ccxt_version = '4.16.0';
const ccxt_version = '4.16.1';
ccxt_src_base_Exchange_js_WEBPACK_IMPORTED_MODULE_0_/* .Exchange */ .k.ccxtVersion = ccxt_version;
//-----------------------------------------------------------------------------

Expand Down
4 changes: 2 additions & 2 deletions dist/ccxt.browser.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cjs/ccxt.js
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ var xt$1 = require('./src/pro/xt.js');

//-----------------------------------------------------------------------------
// this is updated by vss.js when building
const version = '4.16.0';
const version = '4.16.1';
Exchange["default"].ccxtVersion = version;
const exchanges = {
'abantether': abantether["default"],
Expand Down
80 changes: 64 additions & 16 deletions dist/cjs/src/asacoine.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,23 +67,72 @@ class asacoine extends Exchange["default"] {
const quoteId = this.safeString(market, 'quoteId');
const base = this.safeCurrencyCode(baseId);
const quote = this.safeCurrencyCode(quoteId);
const isOtc = this.safeString(market, 'type', 'spot') === 'otc';
let marketType = 'spot';
if (isOtc) {
marketType = 'otc';
}
const suffix = '';
return {
'id': baseId + '/' + quoteId + suffix,
'symbol': base + '/' + quote + suffix,
'id': baseId + '/' + quoteId,
'symbol': base + '/' + quote,
'base': base,
'quote': quote,
'settle': undefined,
'baseId': baseId,
'quoteId': quoteId,
'settleId': undefined,
'type': 'spot',
'spot': true,
'margin': false,
'swap': false,
'future': false,
'option': false,
'active': true,
'contract': false,
'linear': undefined,
'inverse': undefined,
'contractSize': undefined,
'expiry': undefined,
'expiryDatetime': undefined,
'strike': undefined,
'optionType': undefined,
'precision': {
'amount': undefined,
'price': undefined,
},
'limits': {
'leverage': {
'min': undefined,
'max': undefined,
},
'amount': {
'min': undefined,
'max': undefined,
},
'price': {
'min': undefined,
'max': undefined,
},
'cost': {
'min': undefined,
'max': undefined,
},
},
'created': undefined,
'info': this.safeValue(market, 'info', market),
};
}
parseOtcMarket(market) {
const baseId = this.safeString(market, 'baseId');
const quoteId = this.safeString(market, 'quoteId');
const base = this.safeCurrencyCode(baseId);
const quote = this.safeCurrencyCode(quoteId);
return {
'id': baseId + '/' + quoteId,
'symbol': base + '/' + quote,
'base': base,
'quote': quote,
'settle': undefined,
'baseId': baseId,
'quoteId': quoteId,
'settleId': undefined,
'type': marketType,
'spot': !isOtc,
'type': 'otc',
'spot': false,
'margin': false,
'swap': false,
'future': false,
Expand Down Expand Up @@ -134,12 +183,12 @@ class asacoine extends Exchange["default"] {
for (let j = 0; j < quoteIds.length; j++) {
const quoteId = quoteIds[j];
const ticker = this.safeDict(quotes, quoteId, {});
result.push(this.parseMarket({ 'baseId': baseId, 'quoteId': quoteId, 'info': ticker, 'type': 'spot' }));
result.push(this.parseMarket({ 'baseId': baseId, 'quoteId': quoteId, 'info': ticker }));
}
}
return result;
}
parseCumulativeMarkets(response, type = 'otc') {
parseCumulativeMarkets(response) {
const data = this.safeDict(response, 'data', {});
const keys = this.safeList(data, 'keys', []);
const values = this.safeList(data, 'values', []);
Expand All @@ -151,15 +200,14 @@ class asacoine extends Exchange["default"] {
market[keys[j]] = row[j];
}
const marketTypes = this.safeList(market, 'marketTypes', []);
if (!this.inArray(type, marketTypes)) {
if (!this.inArray('otc', marketTypes)) {
continue;
}
const name = this.safeString(market, 'name');
const [baseId, quoteId] = name.split('-');
market['baseId'] = baseId;
market['quoteId'] = quoteId;
market['type'] = type;
result.push(this.parseMarket(market));
result.push(this.parseOtcMarket(market));
}
return result;
}
Expand All @@ -176,7 +224,7 @@ class asacoine extends Exchange["default"] {
const request = this.omit(params, ['type']);
if (type === 'otc') {
const cumulativeResponse = await this.publicGetV1MarketPairsCumulative(request);
return this.parseCumulativeMarkets(cumulativeResponse, type);
return this.parseCumulativeMarkets(cumulativeResponse);
}
const response = await this.publicGetV1MarketPairsPricing(request);
return this.parseMarkets(response);
Expand Down
2 changes: 1 addition & 1 deletion go/v4/exchange_metadata.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
package ccxt

var Version string = "4.16.0"
var Version string = "4.16.1"

var Exchanges []string = []string{ "Abantether", "Afratether", "Alpaca", "Apex", "Arzinja", "Arzplus", "Asacoine", "Ascendex", "Asretether", "Bequant", "Bidarz", "Bigone", "Binance", "Binancecoinm", "Binanceus", "Binanceusdm", "Bingx", "Bit24", "Bit2c", "Bitbank", "Bitbarg", "Bitbns", "Bitfinex", "Bitflyer", "Bitget", "Bithumb", "Bitimen", "Bitir", "Bitmart", "Bitmex", "Bitopro", "Bitpin", "Bitrue", "Bitso", "Bitstamp", "Bitteam", "Bittrade", "Bitunix", "Bitvavo", "Bitwana", "Blockchaincom", "Blofin", "Btcalpha", "Btcbox", "Btcmarkets", "Btcturk", "Bybit", "Bydfi", "Cafearz", "Cex", "Changefa", "Coinbase", "Coinbaseadvanced", "Coinbaseexchange", "Coinbaseinternational", "Coincatch", "Coincheck", "Coinex", "Coinmate", "Coinmetro", "Coinone", "Coinsph", "Coinspot", "Cryptocom", "Cryptomus", "Defx", "Delta", "Deribit", "Derive", "Digifinex", "Ellipx", "Eterex", "Excoino", "Exir", "Exmo", "Exnovin", "Farhadexchange", "Fmfwio", "Foxbit", "Gate", "Gateio", "Gemini", "Hamtapay", "Hashkey", "Hibachi", "Hitbtc", "Hitobit", "Hollaex", "Htx", "Huobi", "Hyperliquid", "Independentreserve", "Indodax", "Iranexchange", "Jibitex", "Kcex", "Kifpoolme", "Kraken", "Krakenfutures", "Kucoin", "Kucoinfutures", "Latoken", "Lbank", "Luno", "Mazdax", "Mercado", "Mexc", "Modetrade", "Myokx", "Ndax", "Nobitex", "Novadax", "Oceanex", "Okcoin", "Okexchange", "Okx", "Okxus", "Ompfinex", "Onetrading", "Ourbit", "Oxfun", "P2b", "Paradex", "Paymium", "Phemex", "Pingi", "Poloniex", "Pooleno", "Probit", "Raastin", "Ramzinex", "Saraf", "Sarmayex", "Sarrafex", "Tabdeal", "Talasea", "Tehran_exchange", "Tetherland", "Timex", "Tokocrypto", "Toobit", "Tradeogre", "Twox", "Ubitex", "Upbit", "Vertex", "Wallex", "Wavesexchange", "Whitebit", "Woo", "Woofipro", "Xt", "Yobit", "Zaif", "Zonda" }
2 changes: 1 addition & 1 deletion js/ccxt.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as functions from './src/base/functions.js';
import * as errors from './src/base/errors.js';
import type { Int, int, Str, Strings, Num, Bool, IndexType, OrderSide, OrderType, MarketType, SubType, Dict, NullableDict, List, NullableList, Fee, OHLCV, OHLCVC, implicitReturnType, Market, Currency, Dictionary, MinMax, FeeInterface, TradingFeeInterface, MarketMarginModes, MarketInterface, Trade, Order, OrderBook, Ticker, Transaction, Tickers, CurrencyInterface, Balance, BalanceAccount, Account, PartialBalances, Balances, DepositAddress, WithdrawalResponse, FundingRate, FundingRates, Position, BorrowInterest, LeverageTier, LedgerEntry, DepositWithdrawFeeNetwork, DepositWithdrawFee, TransferEntry, CrossBorrowRate, IsolatedBorrowRate, FundingRateHistory, OpenInterest, Liquidation, OrderRequest, CancellationRequest, FundingHistory, MarginMode, Greeks, Conversion, Option, LastPrice, Leverage, MarginModification, Leverages, LastPrices, Currencies, TradingFees, MarginModes, OptionChain, IsolatedBorrowRates, CrossBorrowRates, LeverageTiers, LongShortRatio, OrderBooks, OpenInterests, ConstructorArgs } from './src/base/types.js';
import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
declare const version = "4.16.0";
declare const version = "4.16.1";
import abantether from './src/abantether.js';
import afratether from './src/afratether.js';
import alpaca from './src/alpaca.js';
Expand Down
2 changes: 1 addition & 1 deletion js/ccxt.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import * as errors from './src/base/errors.js';
import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
//-----------------------------------------------------------------------------
// this is updated by vss.js when building
const version = '4.16.0';
const version = '4.16.1';
Exchange.ccxtVersion = version;
//-----------------------------------------------------------------------------
import abantether from './src/abantether.js';
Expand Down
3 changes: 2 additions & 1 deletion js/src/asacoine.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ import { Market, Strings, Ticker, Tickers } from './base/types.js';
export default class asacoine extends Exchange {
describe(): any;
parseMarket(market: any): Market;
parseOtcMarket(market: any): Market;
parseMarkets(response: any): Market[];
parseCumulativeMarkets(response: any, type?: string): Market[];
parseCumulativeMarkets(response: any): Market[];
fetchMarkets(params?: {}): Promise<import("./base/types.js").MarketInterface[]>;
parseTicker(ticker: any, market?: Market): Ticker;
fetchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
Expand Down
Loading
Loading