
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
argosy-client
Advanced tools
Use argosy instead. This module is no longer maintained as a separate entity.
Consume micro-services.
Part of the Argosy family.
var http = require('http'),
query = require('querystring'),
service = require('argosy-service')(),
match = require('argosy-pattern/match'),
client = require('argosy-client')()
// connect the client to the service
client.pipe(service).pipe(client)
// create a micro-service that gets weather
service.message({ get: 'weather', location: match.defined }).process(function (msg, cb) {
var qs = query.stringify({ q: msg.location, units: msg.units || 'imperial' })
http.get('http://api.openweathermap.org/data/2.5/weather?' + qs, function (res) {
var body = ''
res.on('data', function (data) {
body += data
}).on('end', function () {
cb(null, JSON.parse(body).main)
})
})
})
// use the service with argosy-client
client.invoke({ get: 'weather', location: 'Boston,MA' }, function (err, weather) {
console.log(weather.temp + ' degrees (F) in Boston.')
})
// or create a convenience function using invoke.partial
var getWeather = client.invoke.partial({ get: 'weather', units: 'metric' })
getWeather({ location: 'Dublin,IE' }, function (err, weather) {
console.log(weather.temp + ' degrees (C) in Dublin.')
})
// or use promises
getWeather({ location: 'London,UK' }).then(function (weather) {
console.log(weather.temp + ' degrees (C) in London.')
})
var argosyClient = require('argosy-client')
Create a new client object. The client object is a stream intended to be connected (piped) to Argosy services
through any number of intermediary streams.
Invoke a service which implements the msg pattern. Upon
completion, the callback cb, if supplied, will be called with the result or error. The client.invoke function also
returns a promise which will resolve or reject appropriately.
Return a function that represents a partial invocation. The function returned has the same signature as client.invoke, but
when called, the msg parameter will be merged with the partialMsg parameter provided at the time the function was created.
Otherwise, the generated function behaves identically to client.invoke.
npm test [--dot | --spec] [--grep=pattern]
Specifying --dot or --spec will change the output from the default TAP style.
Specifying --grep will only run the test files that match the given pattern.
npm run coverage [--html]
This will output a textual coverage report. Including --html will also open
an HTML coverage report in the default browser.
FAQs
Consume micro-services.
The npm package argosy-client receives a total of 3 weekly downloads. As such, argosy-client popularity was classified as not popular.
We found that argosy-client 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.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.