Track Event
curl --request POST \
--url https://api.vellaro.io/api/v1/whatsapp/eventsimport requests
url = "https://api.vellaro.io/api/v1/whatsapp/events"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.vellaro.io/api/v1/whatsapp/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.vellaro.io/api/v1/whatsapp/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.vellaro.io/api/v1/whatsapp/events"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.vellaro.io/api/v1/whatsapp/events")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vellaro.io/api/v1/whatsapp/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"counted": true
},
"meta": {
"page": 123,
"page_size": 123,
"total": 123,
"total_pages": 123
},
"error": "<string>",
"error_code": "<string>"
}Checkout & orders
Track Event
Conta un clic su «Ordina su WhatsApp» (product) o «Invia l’ordine su
WhatsApp» (cart): {kind, product_id?, variant_id?, code?}.
Il corpo si legge in qualunque Content-Type (anche text/plain, quello di
navigator.sendBeacon). 202 {counted}: false col modulo spento, per il
dedup di 30 minuti (IP, tipo, prodotto) o per un prodotto che non è del
negozio; mai un errore alla vetrina per questo. 422 whatsapp.event_invalid
per un corpo illeggibile, 429 oltre 60/minuto per IP.
POST
/
api
/
v1
/
whatsapp
/
events
Track Event
curl --request POST \
--url https://api.vellaro.io/api/v1/whatsapp/eventsimport requests
url = "https://api.vellaro.io/api/v1/whatsapp/events"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.vellaro.io/api/v1/whatsapp/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.vellaro.io/api/v1/whatsapp/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.vellaro.io/api/v1/whatsapp/events"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.vellaro.io/api/v1/whatsapp/events")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vellaro.io/api/v1/whatsapp/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"counted": true
},
"meta": {
"page": 123,
"page_size": 123,
"total": 123,
"total_pages": 123
},
"error": "<string>",
"error_code": "<string>"
}