📒 Centro Risorse Acconsentobot
-
🏃♂️ Come funziona Acconsentobot?
- 🛠️ Errori comuni e risoluzione dei problemi
📖 Guide Prodotto e Formazione
🛠️ Riferimenti API
POST Messaggio Template WhatsApp
Descrizione dei Parametri
userName: si riferisce al nome dell'utente a cui intendiamo inviare il messaggiowa_id: si riferisce al numero WhatsApp dell'utente a cui intendiamo inviare il messaggio NOTA: Il numero deve contenere il prefisso del paese senza il segno piùtemplateId: si riferisce all'ID del template NOTA: Il template deve essere approvato prima di utilizzare questa APIparams: viene utilizzato per le variabili utilizzate nel template, è un array vuoto nel caso di un template di testo semplice senza variabili. In caso di variabili nel template, fare riferimento al JSON qui sotto
Endpoint API
https://api.v7.express-chat.com/whatsapp-automation/wa/send-template?apiKey=*API KEY*
Intestazioni della Richiesta
| Intestazione | Dettagli |
|---|---|
| apiKey | API KEY |
Parametri Query
| Intestazione | Dettagli |
|---|---|
| apiKey | API KEY |
Corpo
{
"userName": "Divyansh Test",
"wa_id": "9175080****",
"templateId": "62b5c16bf*****cfa9a72335",
"params": [
{
"type" : "header",
"parameters": [
{
"type": "document",
"document": {
"link": "https://www.africau.edu/images/default/sample.pdf"
}
}
]
},
{
"type": "body",
"parameters": [
{
"type": "text",
"text": "Abc"
},
{
"type": "text",
"text": "def"
},
{
"type": "text",
"text": "Monday"
}
]
}
]
}
Esempi
Richiesta
curl --location --request POST 'https://api.v7.express-chat.com/whatsapp-automation/wa/send-template?apiKey= *Condiviso Separatamente*' \\
--header 'apiKey: *API KEY*' \\
--header 'Content-Type: application/json' \\
--data-raw '{
"userName": "Test",
"wa_id": "91885917****",
"templateId": "63dba1617****52face07078",
"params": [
{
"type": "header",
"parameters": [
{
"type": "document",
"document": {
"link": "https://www.africau.edu/images/default/sample.pdf"
}
}
]
},
{
"type": "body",
"parameters": [
{
"type": "text",
"text": "Abc"
},
{
"type": "text",
"text": "def"
},
{
"type": "text",
"text": "Monday"
}
]
}
]
}'
Risposta
Intestazioni
| Intestazione | Dettagli |
|---|---|
| X-Powered-By | Express |
| Vary | Origin |
| Access-Control-Allow-Credentials | true |
| _user | 61c1c2058e0****e9bb420f8 |
| _bot | 62e77a807f1****ecce980f0 |
| whatsAppId | ****bsIWcYgazd5ZDAK |
| Content-Type | application/json; charset=utf-8 |
| Content-Length | 507 |
| ETag | W/"1fb-urlVjgGZAUBRNyxQDAOnZ3ONF1I" |
| Date | Wed, 03 Aug 2022 11:16:13 GMT |
| Connection | keep-alive |
| Keep-Alive | timeout=5 |
❓ Hai domande?
Se hai domande, puoi consultare il nostro repository di FAQ, molto probabilmente troverai la tua risposta qui. In caso contrario, scrivici su https://acconsentobot.click/contatti/