Documentação API WhatsApp Print

  • API, WHATSAPP, WhatsApp API, php
  • 0

GET - Get Chats

https://wapi.nvhost.com.br/chat/all

HEADERS
 
x-instance-id                                     acme
x-instance-secret                                 wpp.e7d569a1b04f2855070368508e3f9074
api_key                                           secret
 
Example Request
 
curl --location 'https://wapi.nvhost.com.br/chat/all' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret'​
 

GETGet Chat By Number

https://wapi.nvhost.com.br/chat/:number

HEADERS

x-instance-id                                     acme
x-instance-secret                                 wpp.e7d569a1b04f2855070368508e3f9074
api_key                                           secret
 
PATH VARIABLES
 
number
 
Example Request
 
curl --location 'https://wapi.nvhost.com.br/chat/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret'

GETGet Chat Messages By Number

https://wapi.nvhost.com.br//chat/:number/messages

Get messages for specific chat

HEADERS
 
x-instance-id                                     acme
x-instance-secret                                 wpp.e7d569a1b04f2855070368508e3f9074
api_key                                           secret
 
PATH VARIABLES
 
number
 
Example Request
 
curl --location 'https://wapi.nvhost.com.br/chat/:number/messages' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret'

 


 

POSTSend Message

https://wapi.nvhost.com.br/chat/send-message/:number

Send text message to a specific number.

HEADERS
 
x-instance-id                                     acme
x-instance-secret                                 wpp.e7d569a1b04f2855070368508e3f9074
api_key                                           secret
 
PATH VARIABLES
number
 
Body raw (json)
 
{
"message": "Test",
"quote_message_id": ""
}

Example Request

curl --location 'https://wapi.nvhost.com.br/chat/send-message/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"message": "Test",
"quote_message_id": ""
}'


POSTSend Buttons (BETA)

https://wapi.nvhost.com.br/chat/send-buttons/:number

Send text message to a specific number.

HEADERS

x-instance-id                                     acme
x-instance-secret                                 wpp.e7d569a1b04f2855070368508e3f9074
api_key                                           secret

PATH VARIABLES

number
 
Body raw (json)
 
{
   "title": "title",
   "footer": "footer",
   "message": "Test",
   "buttons": [
{
         "id": "3",
         "body": "Test 2"
},
{
         "id": "2",
         "body": "Test 3"
}
]
}
Example Request
 
curl --location 'https://wapi.nvhost.com.br/chat/send-buttons/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"title": "title",
"footer": "footer",
"message": "Test",
"buttons": [
{
"id": "3",
"body": "Test 2"
},
{
"id": "2",
"body": "Test 3"
}
]
}'
 
 

 

POSTSend Lists (BETA)

https://wapi.nvhost.com.br/chat/send-lists/:number

Send text message to a specific number.

 

HEADERS
 
x-instance-id                                           acme
x-instance-secret                                       wpp.e7d569a1b04f2855070368508e3f9074
api_key                                                 secret
 
PATH VARIABLES
number
 
Body raw (json)
 
{
"title": "title",
"buttonText": "button text",
"footer": "footer",
"message": "Test",
"sections": [
{
"title": "section title",
"rows": [
{
"id": "1",
"title": "Title 1",
"description": "Description 1"
},
{
"id": "2",
"title": "Title 2",
"description": "Description 2"
},
{
"id": "3",
"title": "Title 3",
"description": "Description 3"
}
]
}
]
}
Example Request
 
 
curl --location 'https://wapi.nvhost.com.br/chat/send-lists/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"title": "title",
"buttonText": "button text",
"footer": "footer",
"message": "Test",
"sections": [
{
"title": "section title",
"rows": [
{
"id": "1",
"title": "Title 1",
"description": "Description 1"
},
{
"id": "2",
"title": "Title 2",
"description": "Description 2"
},
{
"id": "3",
"title": "Title 3",
"description": "Description 3"
}
]
}
]
}'

POSTSend Image

https://wapi.nvhost.com.br/chat/send-image/:number

Send a image to a specific number. You can either provide a base64 encoded image or a direct image URL.

 

HEADERS
 
x-instance-id                                       acme
x-instance-secret                                   wpp.e7d569a1b04f2855070368508e3f9074
api_key                                             secret
 
PATH VARIABLES
number
 
Body raw (json)
 
{
"caption": "",
"image": ""
}
Example Request
 
 
curl --location 'https://wapi.nvhost.com.br/chat/send-image/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"caption": "",
"image": ""
}'
 

POSTSend File

https://wapi.nvhost.com.br/chat/send-file/:number

Send a file to a specific number. You can either provide a base64 encoded file or a direct image URL.

HEADERS
 
x-instance-id                                       acme
x-instance-secret                                   wpp.e7d569a1b04f2855070368508e3f9074
api_key                                             secret
 
 
PATH VARIABLES
number
 
Body raw (json)
 
{
"mime": "",
"file": "",
"caption": ""
}
Example Request
curl --location 'https://wapi.nvhost.com.br/chat/send-file/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"mime": "",
"file": "",
"caption": ""
}'
 
 

POSTSend Location

https://wapi.nvhost.com.br/chat/send-location/:number
Send LatLng location to a specific number.
HEADERS
 
x-instance-id                                       acme
x-instance-secret                                   wpp.e7d569a1b04f2855070368508e3f9074
api_key                                             secret
 
PATH VARIABLES
number
 
Body raw (json)
{
"lat": "",
"lng": ""
}
Example Request
curl --location 'https://wapi.nvhost.com.br/chat/send-location/:number' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"lat": "",
"lng": ""
}'

DELETERevoke Message

https://wapi.nvhost.com.br/chat/revoke-message/:number/:messageId

Delete a specific message. Use everyone = true to delete for all.
 
HEADERS
 
x-instance-id                                       acme
x-instance-secret                                   wpp.e7d569a1b04f2855070368508e3f9074
api_key                                             secret
 
PATH VARIABLES
 
number
 
messageId
 
Body raw (json)
 
{
"everyone": false
}
Example Request
curl --location --request DELETE 'https://wapi.nvhost.com.br/chat/revoke-message/:number/:messageId' \
--header 'x-instance-id: acme' \
--header 'x-instance-secret: wpp.e7d569a1b04f2855070368508e3f9074' \
--header 'api_key: secret' \
--data '{
"everyone": false
}'


Hjalp dette svar dig?
Back

Powered by WHMCompleteSolution