Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import { injectable, inject } from 'inversify';
import { CoinpaymentsTransactionResult } from '../../entities/coinpayments.transaction.result';
import config from '../../config';
export const CoinPayments = require('coinpayments');
const { promisify } = require('util');
const rates = promisify(CoinPayments.prototype.rates);
const createTransaction = promisify(CoinPayments.prototype.createTransaction);
const convertCoins = promisify(CoinPayments.prototype.convertCoins);
const getTx = promisify(CoinPayments.prototype.getTx);
const getTxMulti = promisify(CoinPayments.prototype.getTxMulti);
export interface ConversionOptions {
amount: string|number;
from: string;
to: string;
address?: string;
}
export interface ConversionResult {
id: string;
}
export interface ExchangeRateOptions {
short?: number;
accepted?: number;
}
import { injectable, inject } from 'inversify';
import { CoinpaymentsTransactionResult } from '../../entities/coinpayments.transaction.result';
import config from '../../config';
export const CoinPayments = require('coinpayments');
const { promisify } = require('util');
const rates = promisify(CoinPayments.prototype.rates);
const createTransaction = promisify(CoinPayments.prototype.createTransaction);
const convertCoins = promisify(CoinPayments.prototype.convertCoins);
const getTx = promisify(CoinPayments.prototype.getTx);
const getTxMulti = promisify(CoinPayments.prototype.getTxMulti);
export interface ConversionOptions {
amount: string|number;
from: string;
to: string;
address?: string;
}
export interface ConversionResult {
id: string;
}