
Security News
Risky Biz Podcast: Making Reachability Analysis Work in Real-World Codebases
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
@pake/baileys-store
Advanced tools
Minimal Baileys data storage for your favorite DBMS built with Prisma
Minimal Baileys data storage for your favorite DBMS built with Prisma. This library is a simple handler for Baileys event emitter that will listen and update your data in the database
model Session {
pkId BigInt @id @default(autoincrement())
sessionId String
id String
- data String @db.Text
+ data String
@@unique([sessionId, id], map: "unique_id_per_session_id_session")
@@index([sessionId])
}
pkId
field. Then follow the previous CockroachDB guideJSON
scalar type# Using npm
npm i @pake/baileys-store
# Using yarn
yarn add @pake/baileys-store
Before you can actually use this library, you have to setup your database first
.env.example
file from this repository or from the node_modules
directory (should be located at node_modules/@pake/baileys-store/.env.example
). Rename it into .env
and then update your connection url in the DATABASE_URL
fieldprisma
directory from this repository or from the node_modules
directory (should be located at node_modules/@pake/baileys-store/prisma/
). Additionaly, you may want to update your provider
in the schema.prisma
file if you're not using MySQL databaseimport pino from 'pino';
import makeWASocket from '@whiskeysockets/baileys';
import { PrismaClient } from '@prisma/client';
import { initStore, Store } from '@pake/baileys-store';
const logger = pino();
const socket = makeWASocket();
const prisma = new PrismaClient();
// You only need to run this once
initStore({
prisma, // Prisma client instance
logger, // Pino logger (Optional)
});
// Create a store and start listening to the events
const store = new Store('unique-session-id-here', socket.ev);
// That's it, you can now query from the prisma client without having to worry about handling the events
const messages = prisma.message.findMany();
PRs, issues, suggestions, etc are welcome. Please kindly open a new issue to discuss it
FAQs
Minimal Baileys data storage for your favorite DBMS built with Prisma
The npm package @pake/baileys-store receives a total of 0 weekly downloads. As such, @pake/baileys-store popularity was classified as not popular.
We found that @pake/baileys-store 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.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.
Security News
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.