Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
@curium.rocks/openweathermap-client
Advanced tools
A typescript OpenWeatherMap client, API docs located here.
APIs supported.
API documentation for this library can be found here
import axios from "axios";
import {OwmClient} from '@curium.rocks/openweathermap-client';
const apiToken = process.env.OWM_TOKEN;
const owmClient = new OwmClient(axios);
const currentWeather = await owmClient.current.getCurrentWeather({
appid: apiToken,
city: 'London'
});
console.log('The current weather in London: ', currentWeather);
const currentWeatherNearArea = await owmClient.current.getCurrentWeatherNearby({
appid: apiToken,
lat: 29.422789,
lon: -98.507065,
cnt: 50
});
console.log('The current weather for areas nearby: ', currentWeatherNearArea);
const currentWeatherInRegion = await owmClient.current.getCurrentWeatherForArea({
appid: apiToken,
bbox: [
{
lat: 41.76106,
lon: -89.45617,
},
{
lat: 42.69255,
lon: -85.94055
}
]
});
console.log('The current weather data for the bounding area: ', currentWeatherInRegion);
const currentPollution = owmClient.pollution.getCurrentAirPollution({
appid: apiToken,
lat: 41.76106,
lon: -85.94055
});
console.log('The current pollution levels: ', currentPollution);
const forecastedPollution = await owmClient.pollution.getForecastedAirPollution({
appid: apiToken,
lat: 41.76106,
lon: -85.94055
});
console.log('The forecasted air pollution levels: ', forecastedPollution);
const historicalPollution = await owmClient.pollution.getHistoricalAirPollution({
lat: 41.76106,
lon: -85.94055,
start: new Date(new Date().getDate()-1),
end: new Date(),
appid: apiToken
});
console.log('The pollution levels for the past day: ', historicalPollution);
const allInOne = await owmClient.onecall.getDate({
lat: 41.76106,
lon: -85.94055,
appid: apiToken
});
console.log('The combined summary data is: ', allInOne);
FAQs
A typescript client for the OpenWeatherMap APIs
The npm package @curium.rocks/openweathermap-client receives a total of 7 weekly downloads. As such, @curium.rocks/openweathermap-client popularity was classified as not popular.
We found that @curium.rocks/openweathermap-client demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
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.