POST /v1/actions/get-contact

Récupère un contact par id, téléphone ou email — incluant tags et métadonnées d'engagement.

Récupère un seul contact. Recherche par exactement l'un des contact_id, phone ou email.

POST /api/v1/actions/get-contact

Corps de la requête

Champ Type Requis Notes
contact_id UUID l'un des trois Id interne
phone string l'un des trois Format international avec +
email string l'un des trois Doit être un email valide
curl -X POST https://www.qyvo.io/api/v1/actions/get-contact \
  -H "Authorization: Bearer YOUR_TOKEN_HERE" \
  -H "Content-Type: application/json" \
  -d '{"phone": "+14155550123"}'
const contact = await fetch('https://www.qyvo.io/api/v1/actions/get-contact', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.QYVO_TOKEN}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({ phone: '+14155550123' }),
}).then((r) => r.json());
$contact = Http::withToken(env('QYVO_TOKEN'))
    ->post('https://www.qyvo.io/api/v1/actions/get-contact', [
        'phone' => '+14155550123',
    ])
    ->json();
import os, httpx
contact = httpx.post(
    'https://www.qyvo.io/api/v1/actions/get-contact',
    headers={'Authorization': f"Bearer {os.environ['QYVO_TOKEN']}"},
    json={'phone': '+14155550123'},
).json()

Réponse — 200 OK

{
  "id": "01J1Y...",
  "phone": "+14155550123",
  "name": "Romain",
  "email": "[email protected]",
  "source": "shopify",
  "locale": "fr",
  "metadata": { "shopify_id": "12345" },
  "tags": ["vip", "fr-FR"],
  "opted_in_at": "2026-04-15T10:32:00+00:00",
  "opted_out_at": null,
  "last_message_at": "2026-05-07T08:14:23+00:00",
  "total_messages": 27,
  "created_at": "2026-04-15T10:32:00+00:00"
}
Champ Notes
source D'où le contact est entré dans Qyvo : manual, csv_import, shopify, woocommerce, widget, zapier, api
opted_in_at / opted_out_at État du consentement — utilisé pour conditionner les envois marketing
last_message_at Message le plus récent dans un sens ou dans l'autre. Utilisé pour calculer la fenêtre de service client de 24 h.
total_messages Total cumulé

Erreurs

Statut Cause
404 Contact not found
422 Aucun de contact_id, phone, email fourni