Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
open-exchange-rates
Advanced tools
nodeJS/npm wrapper for the Open Exchange Rates API service. Loads up-to-date or historical currency/exchange rate data from the API, for seamless server-side integration.
Requires a free or paid App ID to connect to the service, available here.
$ npm install open-exchange-rates
To install, type npm install open-exchange-rates
in the terminal.
Requires: http-agent
See the example.js script in this repository for a basic, working example.
var oxr = require('open-exchange-rates');
var oxr = require('open-exchange-rates');
oxr.set({ app_id: 'YOUR_APP_ID' })
oxr.latest(function() {
// You can now use `oxr.rates`, `oxr.base` and `oxr.timestamp`
});
var oxr = require('open-exchange-rates');
oxr.set({ app_id: 'YOUR_APP_ID' })
oxr.historical('2001-02-03', function() {
// You can now use `oxr.rates`, `oxr.base` and `oxr.timestamp`
});
money.js (npm install money
) is a tiny JavaScript currency-conversion library for web and nodeJS.
var oxr = require('open-exchange-rates'),
fx = require('money');
oxr.set({ app_id: 'YOUR_APP_ID' })
oxr.latest(function() {
// Apply exchange rates and base rate to `fx` library object:
fx.rates = oxr.rates;
fx.base = oxr.base;
// money.js is ready to use:
fx(100).from('HKD').to('GBP'); // ~8.0424
});
Advanced API features (such as Time Series requests and real-time value conversion) will be added to this module in future.
For more information, documentation, examples and showcase, check out the Open Exchange Rates homepage
Date
objects for historical queries0.3
0.2
0.1 - first version
FAQs
nodeJS/npm wrapper for the Open Exchange Rates API
The npm package open-exchange-rates receives a total of 777 weekly downloads. As such, open-exchange-rates popularity was classified as not popular.
We found that open-exchange-rates demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.