dfdfdffd
This commit is contained in:
parent
715e8fd5c1
commit
4838df8c02
2
index.js
2
index.js
@ -132,6 +132,7 @@ app.post('/sendInteractiveImage', async (req, res) => {
|
|||||||
// 1) URL publique de votre image
|
// 1) URL publique de votre image
|
||||||
const BASE_URL = process.env.BASE_URL || 'https://wa.canguidev.fr';
|
const BASE_URL = process.env.BASE_URL || 'https://wa.canguidev.fr';
|
||||||
const imageUrl = `${BASE_URL}/static/logo-merlo-cs-FR.jpg`;
|
const imageUrl = `${BASE_URL}/static/logo-merlo-cs-FR.jpg`;
|
||||||
|
console.log(imageUrl);
|
||||||
|
|
||||||
// 2) Contenu brut du message interactif
|
// 2) Contenu brut du message interactif
|
||||||
const rawMessage = {
|
const rawMessage = {
|
||||||
@ -147,7 +148,6 @@ app.post('/sendInteractiveImage', async (req, res) => {
|
|||||||
imageMessage: { url: imageUrl },
|
imageMessage: { url: imageUrl },
|
||||||
title: 'Igna', // facultatif
|
title: 'Igna', // facultatif
|
||||||
subtitle: 'test' , // facultatif
|
subtitle: 'test' , // facultatif
|
||||||
hasMediaAttachment: true
|
|
||||||
}),
|
}),
|
||||||
body: proto.Message.InteractiveMessage.Body.create({
|
body: proto.Message.InteractiveMessage.Body.create({
|
||||||
text: caption || 'Description par défaut'
|
text: caption || 'Description par défaut'
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user