Documentazione sviluppatori

Costruisci su un'API REST per messaggistica aziendale pulita e potente

Integra le funzionalità di SyBox nei tuoi sistemi ERP, CRM e gestionali aziendali con le nostre API REST e webhook ad elevate prestazioni.

011. Autenticazione API & Chiavi Dispositivo

Tutte le richieste API richiedono un'autenticazione sicura tramite intestazione X-Device-Key e X-Device-Secret.

Base URL
https://api.smartsybox.com
Authentication
Authorization: Bearer <YOUR_DEVICE_KEY>
Content type
application/json

Endpoint di autenticazione

POST /v26.0/{phone-number-id}/messages
Genera e gestisci le tue chiavi API direttamente dal pannello delle impostazioni dello spazio di lavoro SyBox.

022. Invio Messaggi WhatsApp & Omnicanale

Invia messaggi di testo, immagini, documenti e modelli approvati Meta tramite le nostre rotte REST.

cURL
curl -X POST https://api.smartsybox.com/v26.0/PHONE_NUMBER_ID/messages \
  -H "Authorization: Bearer YOUR_DEVICE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "messaging_product": "whatsapp",
    "to": "15551234567",
    "type": "text",
    "text": { "body": "Hello from SyBox 👋" }
  }'
C# · HttpClient
using System.Net.Http;
using System.Net.Http.Headers;
using System.Text;

var http = new HttpClient();
http.DefaultRequestHeaders.Authorization =
    new AuthenticationHeaderValue("Bearer", "YOUR_DEVICE_KEY");

string json = @"{
  ""messaging_product"": ""whatsapp"",
  ""to"": ""15551234567"",
  ""type"": ""text"",
  ""text"": { ""body"": ""Hello from SyBox"" }
}";

var res = await http.PostAsync(
    "https://api.smartsybox.com/v26.0/PHONE_NUMBER_ID/messages",
    new StringContent(json, Encoding.UTF8, "application/json"));

Console.WriteLine(await res.Content.ReadAsStringAsync());

Esempio di risposta

La risposta include l'ID univoco del messaggio e lo stato di consegna in tempo reale.

200 OK · application/json
{
  "messaging_product": "whatsapp",
  "contacts": [{ "input": "15551234567", "wa_id": "15551234567" }],
  "messages": [{ "id": "wamid.HBgLMTU1NTEyMzQ1NjcVAgARGBI…" }]
}

033. Webhook Eventi in Tempo Reale

Ricevi notifiche istantanee HTTP POST per messaggi in arrivo, aggiornamenti di stato e cambi di assegnazione.

Request body · template
{
  "messaging_product": "whatsapp",
  "to": "15551234567",
  "type": "template",
  "template": {
    "name": "hello_world",
    "language": { "code": "en_US" }
  }
}

044. Integrazione Pannello ERP Integrato nel Chat

Mostra informazioni di fatturazione, saldi e ordini del cliente direttamente nella barra laterale della conversazione.

Request · SyBox → your endpoint
POST YOUR_ERP_URL
Authorization: Bearer YOUR_ERP_KEY
X-Sybox-Action: lookup

# body: { "data": "<json string>" } — the decoded "data":
{
  "phone": "15551234567",
  "email": "customer@example.com",
  "ref": ""
}
Your reply · application/json
{
  "renderAs": "table",
  "content": [
    { "Order": "#10432", "Status": "Shipped", "Total": "$1,250.00" }
  ]
}

renderAs

Rendering di schede personalizzate ERP per gli operatori dell'assistenza.

table
Rows & columns. content = an array of flat objects (or { rows: [ … ] }). Object keys become the column headers.
cards · kpi
Compact tiles (a balance, an order count). content = an array of { label, value } (or { cards: [ … ] }).
feed · list · thread
A timeline of rich cards. content = an array of { title, text, date, tags, media:[{ type, url, name }] }.
message
A single message-style card (one record laid out as a note).
html
Your own trusted HTML — content = a string. Use only for markup you generate yourself.
sections
Several blocks at once: content = { sections: [ { title, renderAs, content } ] } — mix a table + cards + a feed in one reply.
json
The default when renderAs is omitted — SyBox pretty-prints your content as-is.

Riferimenti ai campi dati dinamici importati.

Configura i webhook ERP nelle impostazioni dello spazio di lavoro.

5. Catalogo Prodotti & Schede Articoli ERP

Importa e sincronizza i prodotti del tuo magazzino per un rapido inserimento nei messaggi.

Request · SyBox → your endpoint
POST YOUR_ERP_URL
Authorization: Bearer YOUR_ERP_KEY
X-Sybox-Action: products

# body: { "data": "<json string>" } — the decoded "data":
{
  "q": "wireless keyboard",
  "phone": "15551234567",
  "email": "customer@example.com",
  "ref": ""
}
Your reply · application/json
{
  "content": [
    {
      "name":      "Wireless Keyboard K380",
      "price":     449,
      "oldPrice":  520,
      "currency":  "USD",
      "available": true,
      "stock":     12,
      "image":     "https://cdn.example.com/k380.jpg",
      "link":      "https://shop.example.com/p/k380",
      "note":      "Ships in 24h"
    }
  ]
}
name
Nome Prodotto
price · oldPrice · currency
Prezzo Unitario
available · stock
Disponibilità Magazzino
image
URL Immagine Articolo
link
Link Scheda Prodotto
note
Note e specifiche tecniche
Supporta prezzi con valute multiple e controllo delle giacenze di magazzino.

056. Gestione Contatti & Profili CRM

Crea, aggiorna e ricerca schede clienti e contatti aziendali via API.

cURL
curl -X POST "https://api.smartsybox.com/v1/case" \
  -H "Authorization: Bearer $SYBOX_CASE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "customer_unique_id": "CUST-10432",
    "header": "Screen replacement not delivered",
    "description": "Paid on 12 Aug, promised in 3 days, still nothing.",
    "ext_ref": "TICKET-99817"
  }'

Campi contatto personalizzabili

customer_unique_id
ID Cliente ERP
header / description
Intestazione Scheda
ext_ref
Riferimento Esterno
Supporta l'assegnazione automatica di etichette e dipartimenti.
Sincronizzazione automatica con Google Contacts se abilitata.

067. Limiti di Richiesta & Quote

Per garantire la stabilità della piattaforma, le richieste API sono soggette a limiti di frequenza per spazio di lavoro.

cURL
curl -X POST "https://api.smartsybox.com/v1/inbound" \
  -H "Authorization: Bearer $SYBOX_INBOUND_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "phone": "15551234567",
    "text": "Order 4821 has left the warehouse."
  }'
I limiti standard consentono fino a 100 richieste al secondo per chiave API.

078. Gestione Errori & Codici di Stato HTTP

Le API di SyBox utilizzano codici di risposta HTTP standard e restituiscono dettagliati messaggi di errore JSON.

4xx · application/json
{
  "error": {
    "message": "(#131030) Recipient phone number not in allowed list",
    "type": "OAuthException",
    "code": 131030
  }
}

089. SDK & Librerie di Integrazione

Disponibili SDK per cURL, JavaScript/Node.js, Python, PHP e C# .NET.

  • Panoramica API
  • Invio Messaggi
  • Webhook & Eventi
  • Integrazione ERP

WhatsApp, Messenger, and Instagram are trademarks of Meta Platforms, Inc.
SyBox™ is an independent product built on Meta Cloud API.

SMART SOUQ

SMART SOUQ SARL AU · RC Marrakech N° 154779 · RC Fès N° 87323 · ICE 003587569000031
© 2026. All rights reserved.