Return the deposit address for the given major currency.

        :param currency: Major currency name in lowercase (e.g. "btc", "eth").
        :type currency: str | unicode
        :return: Deposit address.
        :rtype: str | unicode
4198
def get_deposit_address(self, currency):
        
        self._validate_currency(currency)
        self._log('get deposit address for {}'.format(currency))
        coin_name = self.major_currencies[currency]
        return self._rest_client.post(
            endpoint='/{}_deposit_address'.format(coin_name)
        )
829428
public static String convertToGeminiCcyName(String currency) {

    if (currency.toUpperCase().equals("BTC")) return "btc";
    if (currency.toUpperCase().equals("ETH")) return "eth";

    throw new GeminiException("Cannot determine withdrawal type.");
  }
169118
def normalise(self, to_currency):
        
        out = Money(currency=to_currency)
        for money in self._money_obs:
            out += converter.convert(money, to_currency)
        return Balance([out])
1255948
def ticker(self, base="btc", quote="usd"):
        
        url = self._construct_url("ticker/", base, quote)
        return self._get(url, return_json=True, version=2)
772596
private BigMoney checkCurrencyEqual(BigMoneyProvider moneyProvider) {
        BigMoney money = of(moneyProvider);
        if (isSameCurrency(money) == false) {
            throw new CurrencyMismatchException(getCurrencyUnit(), money.getCurrencyUnit());
        }
        return money;
    }
65221
def get_currencies_info() -> Element:
    
    response = requests.get(const.CBRF_API_URLS['info'])

    return XML(response.text)
126462
def currency(money):
    
    decimals = getattr(settings, 'MIDNIGHT_CATALOG_DECIMALS', 2)
    money = round(float(money), decimals)
    symbol = getattr(settings, 'MIDNIGHT_CATALOG_CURRENCY', 'руб')
    if decimals > 0:
        formatted = (str("%0."+str(decimals)+"f") % money)[-decimals-1:]
    else:
        formatted = ""
    return "%s%s %s" % (intcomma(int(money)), formatted, symbol)
895681
def convert(from_currency, to_currency, from_currency_price=1):
	
	get_cache()
	from_currency, to_currency = validate_currency(from_currency, to_currency)
	update_cache(from_currency, to_currency)
	return ccache[from_currency][to_currency]['value'] * from_currency_price
1004034
def deposit(self, amount):
        
        _json = {"amount": amount}
        self.api_interface.piggy_bank_deposit(self, _json)
923757
public static function getCurrencyCode()
	{
		if (!isset(self::$_currencyCode)) {
			$localeconv = localeconv();
			self::$_currencyCode = ($localeconv['currency_symbol'] != '')
				? $localeconv['currency_symbol'] : $localeconv['int_curr_symbol'];

			if (self::$_currencyCode == '') {
				// Default to $
				self::$_currencyCode = '$';
			}
		}
		return self::$_currencyCode;
	}
731495
public String withdraw(String currency, BigDecimal amount, String address) {
    WexWithDrawInfoReturn info =
        btce.WithdrawCoin(
            apiKey, signatureCreator, exchange.getNonceFactory(), currency, amount, address);
    checkResult(info);
    return String.valueOf(info.getReturnValue().gettId());
  }
603103
def convert_currency(self, base_fiat, base_amount, target_fiat):
        
        url = "http://api.fixer.io/latest?base=%s" % base_fiat
        data = self.get_url(url).json()
        try:
            return data['rates'][target_fiat.upper()] * base_amount
        except KeyError:
            raise Exception("Can not convert %s to %s" % (base_fiat, target_fiat))
327763
def get_type_data(name):
    
    name = name.upper()
    if name in ISO_CURRENCY_TYPES:
        article = 'the '
        type_name = ISO_CURRENCY_TYPES[name]
    elif name in ISO_CURRENCY_ELEMENT_TYPES:
        article = ''
        type_name = ISO_CURRENCY_ELEMENT_TYPES[name]
    else:
        raise NotFound('Currency Type: ' + name)

    return {
        'authority': 'ISO',
        'namespace': '4217',
        'identifier': name,
        'domain': 'ISO Currency Types',
        'display_name': type_name + ' Currency Type',
        'display_label': type_name,
        'description': ('The ISO currency type for ' + article +
                        type_name + '.')
    }
1285192
public static Currency toCurrency(String name) {
        try {
            return Currency.getInstance(name);
        } catch (IllegalArgumentException iae) {
            if (name.length() <= 3) {
                for (Currency c : Currency.getAvailableCurrencies()) {
                    if (matchesCurrency(name, c)) {
                        return c;
                    }
                }
            }
            return toFallbackCurrency(name, iae);
        }
    }
616182
def get_currencys(self, site='Pro', _async=False):
        
        assert site in ['Pro', 'HADAX']
        params = {}
        path = f'/v1{"/" if site == "Pro" else "/hadax/"}common/currencys'
        return api_key_get(params, path, _async=_async)
1367875
def get_currencysymbol(self, code):
        """"""
        if not self._symbols:
            symbolpath = os.path.join(self._dir, 'currencies.json')
            with open(symbolpath, encoding='utf8') as df:
                self._symbols = json.load(df)
        return self._symbols.get(code)
1248086
def to(self, currency):
        """"""
        if currency == self._currency:
            return self
        rate = xrates.quotation(self._currency, currency)
        if rate is None:
            raise ExchangeRateNotFound(xrates.backend_name,
                                         self._currency, currency)
        amount = self._amount * rate
        return self.__class__(amount, currency)