File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ push :
5+ branches :
6+ - staging
7+
8+ concurrency : ${{ github.workflow }}-${{ github.ref }}
9+
10+ jobs :
11+ release :
12+ name : Release
13+ runs-on : ubuntu-latest
14+ steps :
15+ - name : Checkout Repo
16+ uses : actions/checkout@v4
17+
18+ - name : Setup Node.js
19+ uses : actions/setup-node@v4
20+ with :
21+ node-version : 20
22+
23+ - name : Setup PNPM
24+ uses : pnpm/action-setup@v4
25+ with :
26+ version : 10
27+
28+ - name : Install Dependencies
29+ run : pnpm install
30+
31+ - name : Create Release Pull Request or Publish to npm
32+ id : changesets
33+ uses : changesets/action@v1
34+ with :
35+ # This expects you to have a script called "release" in your root package.json
36+ publish : pnpm release
37+ env :
38+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
39+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
Original file line number Diff line number Diff line change 11# zaileys
22
3+ ## 3.2.0
4+
5+ ### Minor Changes
6+
7+ - chore: fix npm install footprint and git ignores
8+
9+ ### Patch Changes
10+
11+ - Updated dependencies
12+ - @zaileys/media-process @2.4.0
13+
314## 3.1.2
415
516### Patch Changes
Original file line number Diff line number Diff line change 1+ import { Client } from '../src' ;
2+
3+ /**
4+ * Zaileys - Dev Playground
5+ *
6+ * This file is used by `npm run dev` to test the library during development.
7+ * It provides a basic setup with QR code authentication and a ping/pong command.
8+ */
9+
10+ const wa = new Client ( {
11+ // session name
12+ session : 'zaileys-test' ,
13+
14+ // authentication type
15+ authType : 'qr' ,
16+
17+ // show internal logs
18+ showLogs : true ,
19+
20+ // enable detailed logs
21+ fancyLogs : false ,
22+ } ) ;
23+
24+ wa . on ( 'messages' , async ( ctx ) => {
25+ // Ignore status updates, stories, or messages from the bot itself
26+ if ( ctx . isStatusMention || ctx . isStory || ctx . isFromMe ) return ;
27+
28+ const text = ctx . text ?. toLowerCase ( ) || '' ;
29+
30+ // ─── Simple Ping Command ──────────────────────────────────────
31+ if ( text === 'ping' ) {
32+ console . log ( `[Test] Ping received from ${ ctx . senderName } (${ ctx . senderId } )` ) ;
33+ await wa . send ( ctx . roomId , 'Pong! 🏓' ) ;
34+ }
35+
36+ // ─── Echo Command ─────────────────────────────────────────────
37+ if ( text . startsWith ( 'echo ' ) ) {
38+ const content = text . replace ( 'echo ' , '' ) ;
39+ await wa . send ( ctx . roomId , `Echo: ${ content } ` ) ;
40+ }
41+ } ) ;
42+
43+ // Optional: Notify when the client is ready
44+ wa . ready ( ) . then ( ( ) => {
45+ console . log ( '🚀 Zaileys Test Client is ready!' ) ;
46+ } ) ;
Original file line number Diff line number Diff line change 11{
22 "name" : " zaileys" ,
33 "description" : " Zaileys - Simplified WhatsApp Node.js TypeScript/JavaScript API" ,
4- "version" : " 3.1.2 " ,
4+ "version" : " 3.2.0 " ,
55 "license" : " MIT" ,
66 "main" : " dist/index.js" ,
77 "module" : " dist/index.mjs" ,
Original file line number Diff line number Diff line change 11# @zaileys/media-process
22
3+ ## 2.4.0
4+
5+ ### Minor Changes
6+
7+ - chore: fix npm install footprint and git ignores
8+
39## 2.3.1
410
511### Patch Changes
Original file line number Diff line number Diff line change 11{
22 "name" : " @zaileys/media-process" ,
3- "version" : " 2.3.1 " ,
3+ "version" : " 2.4.0 " ,
44 "description" : " WhatsApp Media Processing library for Zaileys" ,
55 "license" : " MIT" ,
66 "main" : " dist/index.js" ,
You can’t perform that action at this time.
0 commit comments