Actions
Les 5 blocs de type action. Ils exécutent une opération interne (tâche) ou externe (HTTP, IA).
Les blocs de type action exécutent une opération. Il existe 5 actions standard : créer une tâche, appeler un service HTTP, créer un contact CRM, générer une réponse IA, marquer le contact.
1. Créer une tâche commerciale
Crée une tâche interne pour que l'équipe reprenne manuellement le contact.
{
"id": "create-sales-task",
"type": "action",
"position": { "x": 960, "y": 100 },
"data": {
"label": "Créer une tâche commerciale",
"subtitle": "Suivi humain",
"channel": "commercial",
"description": "Ouvre une tâche pour l'équipe commerciale.",
"parameters": {
"assignation": "commercial",
"priorite": "haute"
}
}
}| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
assignation | texte | non | Personne ou équipe à qui assigner la tâche. |
priorite | texte | non | haute, normale, basse. normale par défaut. |
2. Appeler une source HTTP
Envoie un appel HTTP à un service externe (CRM, ERP, tableur, outil interne). Le bloc supporte GET, POST, PUT, DELETE.
{
"id": "http-notify",
"type": "action",
"position": { "x": 960, "y": 250 },
"data": {
"label": "Appeler une source HTTP",
"subtitle": "Récupération externe",
"channel": "http",
"description": "Contacte un service externe pendant la relance.",
"parameters": {
"action_type": "http_request",
"http_method": "POST",
"url": "https://exemple.com/relance",
"content_type": "json",
"headers_json": "{\"Authorization\": \"Bearer VOTRE_TOKEN\"}",
"body_json": "{\"event\": \"relance_envoyee\"}",
"body_text": "",
"timeout_seconds": "10"
}
}
}| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
action_type | texte | oui | Doit valoir exactement http_request. |
http_method | texte | oui | GET, POST, PUT, DELETE. |
url | texte | oui | URL appelée. Doit être une URL HTTPS en production. |
content_type | texte | non | json ou text. json par défaut. |
headers_json | texte JSON | non | En-têtes HTTP au format JSON en texte. Inclure ici un token d'authentification si nécessaire. |
body_json | texte JSON | non | Corps de la requête au format JSON en texte. |
body_text | texte | non | Corps de la requête en texte brut. |
timeout_seconds | nombre en texte | non | Délai d'attente en secondes. 10 par défaut, maximum 60. |
Exemple minimal d'appel HTTP
Pour un appel simple sans authentification :
{
"action_type": "http_request",
"http_method": "POST",
"url": "https://hooks.exemple.com/relance",
"content_type": "json",
"headers_json": "",
"body_json": "{\"event\": \"relance_envoyee\"}",
"body_text": "",
"timeout_seconds": "10"
}3. Créer un contact CRM
Crée ou met à jour un contact dans le CRM connecté.
{
"id": "create-crm-contact",
"type": "action",
"position": { "x": 960, "y": 400 },
"data": {
"label": "Créer un contact CRM",
"subtitle": "Synchronisation CRM",
"channel": "crm",
"description": "Crée ou met à jour un contact dans le CRM.",
"parameters": {
"action_type": "crm_upsert",
"crm_champ_email": "email",
"crm_champ_telephone": "phone"
}
}
}| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
action_type | texte | oui | Doit valoir exactement crm_upsert. |
crm_champ_email | texte | non | Nom du champ dans le CRM pour l'email. |
crm_champ_telephone | texte | non | Nom du champ dans le CRM pour le téléphone. |
4. Générer une réponse IA
Demande à une IA connectée de rédiger un message personnalisé. Le résultat peut être utilisé dans un message WhatsApp ou un email.
{
"id": "ai-reply",
"type": "action",
"position": { "x": 960, "y": 550 },
"data": {
"label": "Générer une réponse IA",
"subtitle": "Personnalisation",
"channel": "ai",
"description": "Prépare un texte personnalisé via l'IA connectée.",
"parameters": {
"action_type": "ai_reply",
"body_source": "ai",
"temperature": "0.4",
"max_output_tokens": "240",
"system_prompt": "",
"model": ""
}
}
}| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
action_type | texte | oui | Doit valoir exactement ai_reply. |
body_source | texte | non | ai (génère via IA), template (modèle), statique (texte fixe). |
temperature | nombre en texte | non | Température du modèle, de 0.0 (précis) à 1.0 (créatif). 0.4 par défaut. |
max_output_tokens | nombre en texte | non | Limite de tokens en sortie. 240 par défaut, maximum 2000. |
system_prompt | texte | non | Consigne système donnée à l'IA pour cadrer sa réponse. |
model | texte | non | Modèle à utiliser. Laisser vide pour utiliser celui configuré dans Sources. |
5. Marquer le contact
Marque le contact avec un tag pour le retrouver dans la base ou déclencher d'autres automatisations.
{
"id": "tag-contact",
"type": "action",
"position": { "x": 1200, "y": 250 },
"data": {
"label": "Marquer le contact",
"subtitle": "Étiquetage",
"channel": "commercial",
"description": "Pose une étiquette sur le contact.",
"parameters": {
"action_type": "tag_contact",
"tag": "relance_envoyee"
}
}
}| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
action_type | texte | oui | Doit valoir exactement tag_contact. |
tag | texte | oui | Nom de l'étiquette à poser sur le contact. |