
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
graphql-client
Advanced tools
Small http client based on the fetch api. Uses isomorphic-fetch for wider support
Small http client based on the fetch api. Uses isomorphic-fetch for wider support
If query fails, errors are thrown with messages and query highlight for easy debug
npm install graphql-client -S
Initialize the client
var client = require('graphql-client')({
url: 'http://your-host/graphql',
headers: {
Authorization: 'Bearer ' + token
}
})
Use the promise API
WARNING: Make sure the Promise API is polyfilled for older browsers, you can use es6-promise
var variables = {
query: "Search Query",
limit: 100,
from: 200
}
client.query(`
query search ($query: String, $from: Int, $limit: Int) {
search(query: $query, from: $from, limit: $limit) {
took,
totalHits,
hits {
name
}
}
}`, variables, function(req, res) {
if(res.status === 401) {
throw new Error('Not authorized')
}
})
.then(function(body) {
console.log(body)
})
.catch(function(err) {
console.log(err.message)
})
FAQs
Small http client based on the fetch api. Uses isomorphic-fetch for wider support
We found that graphql-client demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.