@pontasockets/baileys 0.2.6 → 0.2.7
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/README.md +36 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -494,6 +494,12 @@ await sock.sendMessage(jid, {
|
|
|
494
494
|
|
|
495
495
|
> Render teks dengan citation/footnote yang bisa diklik — mirip jawaban AI WhatsApp yang punya referensi sumber
|
|
496
496
|
|
|
497
|
+
**Format citation di teks:** `{{KEY}}N{{/KEY}}`
|
|
498
|
+
- `KEY` harus cocok dengan field `key` di `inlineEntities`
|
|
499
|
+
- `N` adalah nomor urut footnote (¹²³ atau 1 2 3)
|
|
500
|
+
|
|
501
|
+
---
|
|
502
|
+
|
|
497
503
|
**Single citation**
|
|
498
504
|
|
|
499
505
|
```javascript
|
|
@@ -537,7 +543,12 @@ await sock.sendMessage(jid, {
|
|
|
537
543
|
reference_url: 'https://nodejs.org',
|
|
538
544
|
reference_title: 'Node.js Official',
|
|
539
545
|
reference_display_name: 'nodejs.org',
|
|
540
|
-
sources: [{
|
|
546
|
+
sources: [{
|
|
547
|
+
source_type: 'THIRD_PARTY',
|
|
548
|
+
source_display_name: 'nodejs.org',
|
|
549
|
+
source_subtitle: 'nodejs.org',
|
|
550
|
+
source_url: 'https://nodejs.org'
|
|
551
|
+
}],
|
|
541
552
|
__typename: 'GenAISearchCitationItem'
|
|
542
553
|
}
|
|
543
554
|
},
|
|
@@ -548,7 +559,12 @@ await sock.sendMessage(jid, {
|
|
|
548
559
|
reference_url: 'https://wikipedia.org/wiki/Ryan_Dahl',
|
|
549
560
|
reference_title: 'Ryan Dahl - Wikipedia',
|
|
550
561
|
reference_display_name: 'Wikipedia',
|
|
551
|
-
sources: [{
|
|
562
|
+
sources: [{
|
|
563
|
+
source_type: 'THIRD_PARTY',
|
|
564
|
+
source_display_name: 'Wikipedia',
|
|
565
|
+
source_subtitle: 'wikipedia.org',
|
|
566
|
+
source_url: 'https://wikipedia.org/wiki/Ryan_Dahl'
|
|
567
|
+
}],
|
|
552
568
|
__typename: 'GenAISearchCitationItem'
|
|
553
569
|
}
|
|
554
570
|
}
|
|
@@ -572,23 +588,32 @@ await sock.sendMessage(jid, {
|
|
|
572
588
|
reference_url: 'https://nodejs.org/en/download',
|
|
573
589
|
reference_title: 'Download Node.js',
|
|
574
590
|
reference_display_name: 'nodejs.org',
|
|
575
|
-
sources: [{
|
|
591
|
+
sources: [{
|
|
592
|
+
source_type: 'THIRD_PARTY',
|
|
593
|
+
source_display_name: 'nodejs.org',
|
|
594
|
+
source_subtitle: 'nodejs.org',
|
|
595
|
+
source_url: 'https://nodejs.org/en/download'
|
|
596
|
+
}],
|
|
576
597
|
__typename: 'GenAISearchCitationItem'
|
|
577
598
|
}
|
|
578
599
|
}]
|
|
579
600
|
},
|
|
580
|
-
{
|
|
581
|
-
|
|
601
|
+
{
|
|
602
|
+
code: 'curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -
|
|
603
|
+
apt-get install -y nodejs',
|
|
604
|
+
language: 'bash'
|
|
605
|
+
},
|
|
606
|
+
{
|
|
607
|
+
text: '_Verifikasi instalasi dengan_ `node --version`'
|
|
608
|
+
}
|
|
582
609
|
]
|
|
583
610
|
}, { quoted: message })
|
|
584
611
|
```
|
|
585
612
|
|
|
586
|
-
> **
|
|
587
|
-
|
|
588
|
-
>
|
|
589
|
-
> - `{
|
|
590
|
-
> - `{ code, language }` — code block
|
|
591
|
-
> - `{ table, title? }` — tabel (rows langsung array of arrays `[items[], isHeading?]`)
|
|
613
|
+
> **Tipe yang valid di dalam `richResponse`:**
|
|
614
|
+
> - `{ text, inlineEntities? }` — teks/markdown, dengan optional citation
|
|
615
|
+
> - `{ code, language }` — code block (tokenized)
|
|
616
|
+
> - `{ table, title? }` — tabel, `table` berupa `[{ items: string[], isHeading?: bool }, ...]`
|
|
592
617
|
|
|
593
618
|
</details>`{ code: 'string', language: 'string' }` — code block
|
|
594
619
|
> - `{ table: { title?, headers?, rows } }` — tabel
|