
Research
Security News
Malicious PyPI Package Exploits Deezer API for Coordinated Music Piracy
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
fetch-request-browser
Advanced tools
The fetch-request-browser package makes working with external APIs simple and efficient. This intuitive wrapper leverages the power of the Fetch API, providing a clean and concise interface for your API interactions.
The fetch-request-browser
package makes working with external APIs simple and efficient. This intuitive wrapper leverages the power of the Fetch API, providing a clean and concise interface for your API interactions.
If you are working on a node-based environment, make use of fetch-request-node instead.
Install the package:
$ npm install -S fetch-request-browser
import { sendGET } from 'fetch-request-browser';
await send(
'https://httpbin.org/get',
{
requestOptions: {
method: 'GET'
}
},
[3, 5, 10]
);
// {
// code: 200,
// headers: Headers {
// date: 'Tue, 04 Jun 2024 18:52:29 GMT',
// 'content-type': 'application/json',
// 'content-length': '407',
// connection: 'keep-alive',
// server: 'gunicorn/19.9.0',
// 'access-control-allow-origin': '*',
// 'access-control-allow-credentials': 'true'
// },
// data: {
// args: {},
// headers: {
// Accept: 'application/json',
// 'Accept-Encoding': 'br, gzip, deflate',
// 'Accept-Language': '*',
// 'Content-Type': 'application/json',
// Host: 'httpbin.org',
// 'Sec-Fetch-Mode': 'cors',
// 'User-Agent': 'node',
// 'X-Amzn-Trace-Id': '...'
// },
// origin: '...',
// url: 'https://httpbin.org/get'
// }
// }
Build and send an HTTP Request (any method):
send(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
Build and send a GET
HTTP Request:
sendGET(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
Build and send a POST
HTTP Request:
sendPOST(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
Build and send a PUT
HTTP Request:
sendPUT(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
Build and send a PATCH
HTTP Request:
sendPATCH(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
Build and send a DELETE
HTTP Request:
sendDELETE(
input: IRequestInput,
options?: Partial<IOptions>,
retryDelaySchedule?: number[],
): Promise<IRequestResponse>
# Unit Tests
$ npm run test:unit
# Integration Tests
$ npm run test:integration
Install dependencies:
$ npm install
Build the library:
$ npm start
Publish to npm
:
$ npm publish
FAQs
The fetch-request-browser package makes working with external APIs simple and efficient. This intuitive wrapper leverages the power of the Fetch API, providing a clean and concise interface for your API interactions.
The npm package fetch-request-browser receives a total of 4 weekly downloads. As such, fetch-request-browser popularity was classified as not popular.
We found that fetch-request-browser demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.
Security News
Newly introduced telemetry in devenv 1.4 sparked a backlash over privacy concerns, leading to the removal of its AI-powered feature after strong community pushback.