
Research
/Security News
Malicious npm Packages Target WhatsApp Developers with Remote Kill Switch
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
funpay-js-api
Advanced tools
This is a Node.js API project designed to interact with the Funpay.com website. The API allows for seamless integration and communication with Funpay's services, making it easier to develop applications that rely on Funpay's features.
Supply Chain Security
Vulnerability
Quality
Maintenance
License
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Unpopular package
QualityThis package is not very popular.
Found 1 instance in 1 package
Socket optimized override available
This is a Node.js API project designed to interact with the Funpay.com website. The API allows for seamless integration and communication with Funpay's services, making it easier to develop applications that rely on Funpay's features.
To install the necessary dependencies, run the following command:
npm i funpay-js-api
import { Api, Runner, Chat } from "funpay-js-api";
const goldenkey = 'YOUR GOLDEN KEY FROM COOKIES';
class app {
constructor(){
Api.setConfig(goldenkey);
this.test()
}
async test(){
Runner.on('orders_counters', (data)=>{
console.log('updated order counter', data);
})
Runner.on('chat_counter', (data)=>{
console.log('updated chat counter', data);
})
let neworders = await Api.getNewOrders();
console.log('neworders', neworders);
let chat = new Chat(11936609, 1);
chat.on('message', (msg)=>{
console.log(msg);
});
}
}
new app();
The Api class provides methods for interacting with the Funpay API.
setConfig(key: string): Promise<void>
getUserLastMessage(id: number): Promise<string>
getOffers(id?: number): Promise<any>
getLots(node: string): Promise<any>
getOfferPage(node: string, offer: string): Promise<any>
updateOfferPage(offerPage: any): Promise<any>
updatePrice(node: string, offer: string, price: number): Promise<void>
getUserLangById(id: number): Promise<string>
getUserByDialogId(dialogId: string): Promise<{ userId: string, lang: string }>
getDialogs(): Promise<any[]>
getLastOrders(): Promise<any[]>
getNewOrders(): Promise<any[]>
refund(orderId: string): Promise<any>
svgtopng(base64Svg: string): Promise<Buffer>
uploadFileFromBuffer(imageBuffer: Buffer, contentType: string): Promise<any>
uploadFileFromUrl(src: string): Promise<any>
The Runner class handles chat interactions and emits events.
on(event: 'orders_counters', listener: (data: any) => void): void
on(event: 'chat_counter', listener: (data: any) => void): void
off(event: 'orders_counters', listener: (data: any) => void): void
off(event: 'chat_counter', listener: (data: any) => void): void
Chat
ClassThe Chat
class manages individual chat instances, allowing you to send messages, send files, and handle chat-specific events.
constructor(id: number, lastMessage?: number)
id
(number): The ID of the chat.lastMessage
(optional, number): The ID of the last message (if available).sendMessage(message: string): Promise<void>
message
(string): The message text to send.sendFile(fileid: string): Promise<void>
fileid
(string): The ID of the file to send.remove(): Promise<void>
on(event: 'message', listener: (message: object) => void): void
event
(string): The event type ('message'
).listener
(function): The callback function to handle incoming messages. The function receives a message
object as an argument.off(event: 'message', listener: (message: object) => void): void
event
(string): The event type ('message'
).listener
(function): The callback function to remove.This project was created by Aleksandr Iurov for https://buynstars.com.
FAQs
This is a Node.js API project designed to interact with the Funpay.com website. The API allows for seamless integration and communication with Funpay's services, making it easier to develop applications that rely on Funpay's features.
The npm package funpay-js-api receives a total of 1 weekly downloads. As such, funpay-js-api popularity was classified as not popular.
We found that funpay-js-api 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
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
Research
/Security News
Socket uncovered 11 malicious Go packages using obfuscated loaders to fetch and execute second-stage payloads via C2 domains.
Security News
TC39 advances 11 JavaScript proposals, with two moving to Stage 4, bringing better math, binary APIs, and more features one step closer to the ECMAScript spec.