zaileys 0.1.1-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +34 -0
- package/dist/index.d.ts +34 -0
- package/dist/index.js +1 -0
- package/dist/index.mjs +1 -0
- package/package.json +45 -0
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as _whiskeysockets_baileys from '@whiskeysockets/baileys';
|
|
2
|
+
import * as pino from 'pino';
|
|
3
|
+
|
|
4
|
+
type ClientProps = {
|
|
5
|
+
pairing: boolean;
|
|
6
|
+
state: any;
|
|
7
|
+
};
|
|
8
|
+
type ActionsProps = 'ready' | 'message';
|
|
9
|
+
|
|
10
|
+
declare class Client {
|
|
11
|
+
private readonly pairing;
|
|
12
|
+
constructor({ pairing }: ClientProps);
|
|
13
|
+
on(actions: ActionsProps, callback: (ctx: 'a') => void): void;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
declare function ConnectionConfig(props: ClientProps): {
|
|
17
|
+
printQRInTerminal: boolean;
|
|
18
|
+
syncFullHistory: boolean;
|
|
19
|
+
markOnlineOnConnect: boolean;
|
|
20
|
+
connectTimeoutMs: number;
|
|
21
|
+
defaultQueryTimeoutMs: number;
|
|
22
|
+
keepAliveIntervalMs: number;
|
|
23
|
+
generateHighQualityLinkPreview: boolean;
|
|
24
|
+
version: number[];
|
|
25
|
+
browser: string[];
|
|
26
|
+
logger: pino.Logger<never>;
|
|
27
|
+
auth: {
|
|
28
|
+
creds: any;
|
|
29
|
+
keys: _whiskeysockets_baileys.SignalKeyStore;
|
|
30
|
+
};
|
|
31
|
+
patchMessageBeforeSending: (message: any) => any;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export { type ActionsProps, Client, type ClientProps, ConnectionConfig };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as _whiskeysockets_baileys from '@whiskeysockets/baileys';
|
|
2
|
+
import * as pino from 'pino';
|
|
3
|
+
|
|
4
|
+
type ClientProps = {
|
|
5
|
+
pairing: boolean;
|
|
6
|
+
state: any;
|
|
7
|
+
};
|
|
8
|
+
type ActionsProps = 'ready' | 'message';
|
|
9
|
+
|
|
10
|
+
declare class Client {
|
|
11
|
+
private readonly pairing;
|
|
12
|
+
constructor({ pairing }: ClientProps);
|
|
13
|
+
on(actions: ActionsProps, callback: (ctx: 'a') => void): void;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
declare function ConnectionConfig(props: ClientProps): {
|
|
17
|
+
printQRInTerminal: boolean;
|
|
18
|
+
syncFullHistory: boolean;
|
|
19
|
+
markOnlineOnConnect: boolean;
|
|
20
|
+
connectTimeoutMs: number;
|
|
21
|
+
defaultQueryTimeoutMs: number;
|
|
22
|
+
keepAliveIntervalMs: number;
|
|
23
|
+
generateHighQualityLinkPreview: boolean;
|
|
24
|
+
version: number[];
|
|
25
|
+
browser: string[];
|
|
26
|
+
logger: pino.Logger<never>;
|
|
27
|
+
auth: {
|
|
28
|
+
creds: any;
|
|
29
|
+
keys: _whiskeysockets_baileys.SignalKeyStore;
|
|
30
|
+
};
|
|
31
|
+
patchMessageBeforeSending: (message: any) => any;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export { type ActionsProps, Client, type ClientProps, ConnectionConfig };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var f=Object.create;var a=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var g=Object.getOwnPropertyNames;var y=Object.getPrototypeOf,d=Object.prototype.hasOwnProperty;var v=(t,e)=>{for(var o in e)a(t,o,{get:e[o],enumerable:!0})},l=(t,e,o,c)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of g(e))!d.call(t,i)&&i!==o&&a(t,i,{get:()=>e[i],enumerable:!(c=u(e,i))||c.enumerable});return t};var h=(t,e,o)=>(o=t!=null?f(y(t)):{},l(e||!t||!t.__esModule?a(o,"default",{value:t,enumerable:!0}):o,t)),x=t=>l(a({},"__esModule",{value:!0}),t);var M={};v(M,{Client:()=>n,ConnectionConfig:()=>C});module.exports=x(M);var n=class{pairing;constructor({pairing:e}){this.pairing=e}on(e,o){}};var m=require("@whiskeysockets/baileys"),p=h(require("pino"));var s={author:"https://github.com/zaadevofc",repository:"https://github.com/zaadevofc/zaileys",package:"https://www.npmjs.com/package/zaileys",version:[0,0,1]};function C(t){return{printQRInTerminal:!t.pairing,syncFullHistory:!0,markOnlineOnConnect:!0,connectTimeoutMs:6e4,defaultQueryTimeoutMs:0,keepAliveIntervalMs:1e4,generateHighQualityLinkPreview:!0,version:s.version,browser:["Zaileys Node","Chrome",s.version.join(".")],logger:(0,p.default)({level:"fatal"}),auth:{creds:t.state.creds,keys:(0,m.makeCacheableSignalKeyStore)(t.state.keys,(0,p.default)().child({level:"silent",stream:"store"}))},patchMessageBeforeSending:e=>(!!(e.buttonsMessage||e.templateMessage||e.listMessage)&&(e={viewOnceMessage:{message:{messageContextInfo:{deviceListMetadataVersion:2,deviceListMetadata:{}},...e}}}),e)}}0&&(module.exports={Client,ConnectionConfig});
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var a=class{pairing;constructor({pairing:e}){this.pairing=e}on(e,s){}};import{makeCacheableSignalKeyStore as c}from"@whiskeysockets/baileys";import n from"pino";var i={author:"https://github.com/zaadevofc",repository:"https://github.com/zaadevofc/zaileys",package:"https://www.npmjs.com/package/zaileys",version:[0,0,1]};function x(r){return{printQRInTerminal:!r.pairing,syncFullHistory:!0,markOnlineOnConnect:!0,connectTimeoutMs:6e4,defaultQueryTimeoutMs:0,keepAliveIntervalMs:1e4,generateHighQualityLinkPreview:!0,version:i.version,browser:["Zaileys Node","Chrome",i.version.join(".")],logger:n({level:"fatal"}),auth:{creds:r.state.creds,keys:c(r.state.keys,n().child({level:"silent",stream:"store"}))},patchMessageBeforeSending:e=>(!!(e.buttonsMessage||e.templateMessage||e.listMessage)&&(e={viewOnceMessage:{message:{messageContextInfo:{deviceListMetadataVersion:2,deviceListMetadata:{}},...e}}}),e)}}export{a as Client,x as ConnectionConfig};
|
package/package.json
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "zaileys",
|
|
3
|
+
"description": "Zaileys - Typescript/Javascript WhatsApp NodeJS API",
|
|
4
|
+
"author": {
|
|
5
|
+
"name": "zaadevofc",
|
|
6
|
+
"email": "zaadevofc@gmail.com",
|
|
7
|
+
"url": "https://github.com/zaadevofc"
|
|
8
|
+
},
|
|
9
|
+
"version": "0.0001.1-dev",
|
|
10
|
+
"license": "MIT",
|
|
11
|
+
"main": "dist/index.js",
|
|
12
|
+
"module": "dist/index.mjs",
|
|
13
|
+
"types": "dist/index.d.ts",
|
|
14
|
+
"homepage": "https://github.com/zaadevofc/zaileys",
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/zaadevofc/zaileys/issues"
|
|
17
|
+
},
|
|
18
|
+
"repository": {
|
|
19
|
+
"url": "https://github.com/zaadevofc/zaileys"
|
|
20
|
+
},
|
|
21
|
+
"scripts": {
|
|
22
|
+
"build": "tsup",
|
|
23
|
+
"test": "ts-node src/test"
|
|
24
|
+
},
|
|
25
|
+
"engines": {
|
|
26
|
+
"node": ">=18.17.0"
|
|
27
|
+
},
|
|
28
|
+
"keywords": [
|
|
29
|
+
"zaileys",
|
|
30
|
+
"baileys",
|
|
31
|
+
"whatsapp",
|
|
32
|
+
"bot",
|
|
33
|
+
"node",
|
|
34
|
+
"api"
|
|
35
|
+
],
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"@types/node": "^20.12.14",
|
|
38
|
+
"tsup": "^8.0.2",
|
|
39
|
+
"typescript": "^5.4.5"
|
|
40
|
+
},
|
|
41
|
+
"dependencies": {
|
|
42
|
+
"@whiskeysockets/baileys": "^6.7.2",
|
|
43
|
+
"pino": "^9.1.0"
|
|
44
|
+
}
|
|
45
|
+
}
|