
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.
@cloudcall/batch-requester
Advanced tools
A really simple library that just may save you a headache . . . for the time being. A temporary batcher to stop mulitple requests to API endpoints or just general batching of data
A really simple library that just may save you a headache . . . for the time being.
Do any of the below sound familiar?
Sometimes, writing good, logical code is - unfortunately - just not an option. Most developers have come across a legacy codebase that just needs rewriting to avoid those 100 duplicate requests ripping apart an API endpoint. As you will know, this is not always an option; whether it's commercial or technical limitations.
Hindsight is always a great thing, especially when it comes to code implementations. If past decisions or mis-considerations are now causing you a headache similar to above and you need a quick, temporary fix. This is what you need.
Important: This library is not a permanent solution. This is a sticky plaster that is to get you and your users by.
Currently the library can be added via NPM and saved as a dependency. This library is not suitable for global installation
npm install --save @cloudcall/batch-requester
With simple usage, this library is super easy to hit the ground running with. To get going, you will simply need to do 3 things:
import { Batcher } from 'batch-requests';
class TestClass {
constructor() {
this.lookupAPI();
}
private _httpLookup(requestData) {
return [
{
id: 1,
name: 'Name 1'
},
...
{
id: 10,
name: 'Name 10',
}
]
}
private _mappingCallback(requestedData, requestResponse) {
return requestResponse
.filter((item) => requestedData.indexOf(item.id) !== -1)
.map((item) => item.name);
}
public lookupAPI() {
const batch = new Batcher({
getDataCallback: this._httpLookup,
mappingCallback: this._mappingCallback
});
for (let i = 0; i < 10; i++) {
batch.makeRequest(i).then((response) => {
console.log('Index ' + i + ' = ' + response);
// Index 1 = Name 1
// ...
// Index 10 = Name 10
});
}
}
}
See the LICENSE file for details
FAQs
A really simple library that just may save you a headache . . . for the time being. A temporary batcher to stop mulitple requests to API endpoints or just general batching of data
The npm package @cloudcall/batch-requester receives a total of 14 weekly downloads. As such, @cloudcall/batch-requester popularity was classified as not popular.
We found that @cloudcall/batch-requester demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 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.