Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.
Un webhook notifie votre endpoint lorsque des événements se produisent dans Bodyguard, comme la mise à jour d’un message ou d’un auteur. Cette page vous guide pour en enregistrer un dans le dashboard. Pour comprendre le fonctionnement des webhooks, consultez l’introduction aux webhooks.
Vous avez besoin d’un endpoint HTTPS public, prêt à recevoir des notifications. Bodyguard refuse les webhooks enregistrés avec une URL http. Consultez le Démarrage rapide pour créer votre endpoint et vérifier la signature de chaque requête.
Cliquez sur l’icône d’engrenage dans le menu de gauche pour ouvrir Settings, sélectionnez Webhooks, puis cliquez sur Add webhook.
Settings > Webhooks
Remplissez le formulaire. Les numéros correspondent à la capture d’écran ci-dessous.1. Saisissez l’Endpoint URL qui reçoit les notifications. Elle doit être accessible publiquement en HTTPS. 2. Ajoutez au moins un Alert contact. Bodyguard prévient vos contacts lorsque les envois vers cet endpoint échouent. Chaque contact doit être un utilisateur enregistré dans votre organisation sur le dashboard. 3. Choisissez les Sources auxquelles le webhook s’applique. Dans cet exemple, All the organization’s API sources est sélectionné. 4. Sélectionnez les Events auxquels vous vous abonnez : message.updated (lorsqu’un message est mis à jour par Bodyguard) et author.updated (lorsqu’un auteur est mis à jour par Bodyguard). 5. Cliquez sur Create webhook.
Formulaire de création d'un webhook
Consultez Configuration pour le détail de chaque champ et Payloads pour le contenu de chaque événement.
Lorsque vous créez le webhook, Bodyguard envoie un événement webhook.validate à votre endpoint. Votre endpoint doit y répondre avec un code de statut 2xx.
2
Copier votre secret de signature
Bodyguard génère un secret de signature lorsque vous créez le webhook et l’affiche dans la fenêtre Webhook created. Copiez-le avec l’icône de copie et conservez-le en lieu sûr, puis cliquez sur Done. Le secret commence par whsec_.
Secret de signature affiché à la création
Le secret de signature n’est affiché qu’une seule fois. Vous ne pourrez plus le consulter après avoir fermé la fenêtre. Traitez-le comme un mot de passe et ne l’exposez jamais dans du code côté client.
Vous utilisez le secret de signature pour vérifier que chaque requête provient bien de Bodyguard. Consultez le Démarrage rapide.
3
Activer et tester votre webhook
Votre webhook est créé avec le statut Disabled. Activez-le lorsque votre endpoint est prêt à recevoir des événements. Cliquez sur le menu ⋮ à la fin de la ligne du webhook pour ouvrir ses actions :
Menu d'actions du webhook
Enable webhook active le webhook.
Send test event vous permet de vérifier que votre endpoint reçoit des événements.
Edit webhook et Delete webhook vous permettent de modifier ou de supprimer le webhook.
Tant qu’un webhook est désactivé, Bodyguard n’envoie pas ses événements, et ils ne peuvent pas être rejoués lorsque vous réactivez le webhook. Consultez les statuts du webhook.
Créez un endpoint et vérifiez chaque requête avec une bibliothèque Standard Webhooks.
Configuration
Événements, secret de signature, contacts et statuts du webhook.
Gérer les erreurs
Ce qui se passe lorsque votre endpoint échoue, et comment rétablir la situation.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Bodyguard","description":"Bodyguard Product Documentation","colors":{"primary":"#003c7c","light":"#24bfe2","dark":"#00356b"},"logo":{"light":"https://mintcdn.com/bodyguardai/CXXaMNDOCYmwXYkN/images/logo-light.svg?fit=max\u0026auto=format\u0026n=CXXaMNDOCYmwXYkN\u0026q=85\u0026s=53fbcc63f9cb65a2b24e72faf85fcbc6","dark":"https://mintcdn.com/bodyguardai/CXXaMNDOCYmwXYkN/images/logo-dark.svg?fit=max\u0026auto=format\u0026n=CXXaMNDOCYmwXYkN\u0026q=85\u0026s=6493bb8bbf5fcf8d13db821f0694db4f","href":"/en/documentation/introduction"},"favicon":"https://mintcdn.com/bodyguardai/bT4NridthvvIprMF/images/favicon.svg?fit=max\u0026auto=format\u0026n=bT4NridthvvIprMF\u0026q=85\u0026s=2b8d9703c3fcc88f4fb43893eeee43db","appearance":{"default":"light"},"navbar":{"primary":{"type":"button","label":"Dashboard","href":"https://app.bodyguard.ai"}},"footer":{"socials":{"x":"https://twitter.com/Bodyguard_intl","facebook":"https://www.facebook.com/Bodyguard.intl","instagram":"https://www.instagram.com/bodyguard.ai","linkedin":"https://www.linkedin.com/company/bodyguard-intl"},"links":[{"header":"Resources","items":[{"label":"Status page","href":"https://status.bodyguard.ai"}]}]},"seo":{"indexing":"all"},"fonts":{"family":"Inter"},"icons":{"library":"lucide"},"styling":{"eyebrows":"breadcrumbs","latex":false},"navigation":{"languages":[{"language":"en","href":"en/documentation/introduction"},{"language":"fr","href":"fr/documentation/introduction"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"bodyguardai","hasAudioNarration":false,"actualSubdomain":"bodyguardai","customDomains":["docs.bodyguard.ai"],"gitSource":{"type":"github","owner":"bodyguard-ai","repo":"documentation","deployBranch":"main","isPrivate":true,"contentDirectory":"","mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae8bd576e6e556c3ab80981","collectionId":"5a61ad42-6a7c-49c7-8ebb-858714437201","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae8bd576e6e556c3ab80981"},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6ae8bd576e6e556c3ab80981","clientVersion":"0.0.4044","searchFilterCounts":[{"language":"en","tag":"API Reference","count":8},{"language":"fr","tag":"Référence API","count":8},{"language":"en","tag":"Documentation","count":6},{"language":"fr","tag":"Documentation","count":6},{"language":"default","tag":"API Reference","count":6},{"language":"default","tag":"Reference","count":6},{"language":"en","tag":"Webhooks","count":5},{"language":"fr","tag":"Webhooks","count":5},{"language":"en","tag":"API Documentation","count":3},{"language":"en","tag":"Taxonomy","count":3},{"language":"fr","tag":"Documentation API","count":3},{"language":"fr","tag":"Taxonomie","count":3},{"language":"default","tag":"Analyze","count":3},{"language":"default","tag":"Feedback","count":3},{"language":"en","tag":"How-to","count":2},{"language":"fr","tag":"Guides pratiques","count":2},{"language":"en","tag":"Reference","count":1},{"language":"en","tag":"Getting started","count":1},{"language":"fr","tag":"Référence","count":1},{"language":"fr","tag":"Pour commencer","count":1}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"fr/documentation/how-to/connect-webhook","slug":"/fr/documentation/how-to/connect-webhook","pageMetadata":{"title":"Connecter votre webhook","sidebarTitle":"Connecter votre webhook","description":"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.","href":"/fr/documentation/how-to/connect-webhook"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{Card,CardGroup,Frame,Heading,Note,OptimizedImage,Step,Steps,Warning}=_components;if(!Card)_missingMdxReference(`Card`,true);if(!CardGroup)_missingMdxReference(`CardGroup`,true);if(!Frame)_missingMdxReference(`Frame`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Un webhook notifie votre endpoint lorsque des événements se produisent dans Bodyguard, comme la mise à jour d’un message ou d’un auteur. Cette page vous guide pour en enregistrer un dans le dashboard. Pour comprendre le fonctionnement des webhooks, consultez l’`,_jsx(_components.a,{href:`/fr/api-reference/webhooks/introduction`,children:`introduction aux webhooks`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`prérequis`,children:`Prérequis`}),`\n`,_jsxs(_components.p,{children:[`Vous avez besoin d’un endpoint HTTPS public, prêt à recevoir des notifications. Bodyguard refuse les webhooks enregistrés avec une URL `,_jsx(_components.code,{children:`http`}),`. Consultez le `,_jsx(_components.a,{href:`/fr/api-reference/webhooks/quick-start`,children:`Démarrage rapide`}),` pour créer votre endpoint et vérifier la signature de chaque requête.`]}),`\n`,_jsx(Heading,{level:`2`,id:`étapes`,children:`Étapes`}),`\n`,_jsxs(Steps,{children:[_jsx(Step,{title:`Ajouter un webhook`,children:_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Cliquez sur l’icône d’engrenage dans le menu de gauche pour ouvrir `,_jsx(_components.strong,{children:`Settings`}),`, sélectionnez `,_jsx(_components.strong,{children:`Webhooks`}),`, puis cliquez sur `,_jsx(_components.strong,{children:`Add webhook`}),`.`]}),`\n`,_jsx(Frame,{caption:`Settings > Webhooks`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=71ad72d9f89c307321eb2981a9acf4c9`,alt:`Page Webhooks avec l'icône d'engrenage Settings (1), l'entrée Webhooks (2) et le bouton Add webhook (3) en surbrillance`,\"data-og-width\":`1920`,width:`1920`,\"data-og-height\":`855`,height:`855`,\"data-path\":`images/how-to/connect-webhook/01-open-webhooks-page.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=280\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=9e1386be81abc65eac41e6315bd531c3 280w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=560\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=1aebf4e152705319eda256c5965aabb5 560w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=840\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=263c8bb468b53e4291ec7808b9f5c6f4 840w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=1100\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=0c36c229fe7c78e3f34b945ea3790d34 1100w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=1650\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=69d29ae800ceede42491dabfee3cc67f 1650w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/01-open-webhooks-page.png?w=2500\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=952adeb42c1409110aa46274f9fda660 2500w`})}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsx(_components.p,{children:`Remplissez le formulaire. Les numéros correspondent à la capture d’écran ci-dessous.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`1.`}),` Saisissez l’`,_jsx(_components.strong,{children:`Endpoint URL`}),` qui reçoit les notifications. Elle doit être accessible publiquement en HTTPS.`,_jsx(`br`,{}),`\n`,_jsx(_components.strong,{children:`2.`}),` Ajoutez au moins un `,_jsx(_components.strong,{children:`Alert contact`}),`. Bodyguard prévient vos contacts lorsque les envois vers cet endpoint échouent. Chaque contact doit être un utilisateur enregistré dans votre organisation sur le dashboard.`,_jsx(`br`,{}),`\n`,_jsx(_components.strong,{children:`3.`}),` Choisissez les `,_jsx(_components.strong,{children:`Sources`}),` auxquelles le webhook s’applique. Dans cet exemple, `,_jsx(_components.strong,{children:`All the organization’s API sources`}),` est sélectionné.`,_jsx(`br`,{}),`\n`,_jsx(_components.strong,{children:`4.`}),` Sélectionnez les `,_jsx(_components.strong,{children:`Events`}),` auxquels vous vous abonnez : `,_jsx(_components.code,{children:`message.updated`}),` (lorsqu’un message est mis à jour par Bodyguard) et `,_jsx(_components.code,{children:`author.updated`}),` (lorsqu’un auteur est mis à jour par Bodyguard).`,_jsx(`br`,{}),`\n`,_jsx(_components.strong,{children:`5.`}),` Cliquez sur `,_jsx(_components.strong,{children:`Create webhook`}),`.`]}),`\n`,_jsx(Frame,{caption:`Formulaire de création d'un webhook`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=b3c06997e442288a625613943e370d37`,alt:`Fenêtre New webhook avec les champs Endpoint URL (1), Alert contact (2), Sources (3) et Events (4), et le bouton Create webhook (5) en surbrillance`,\"data-og-width\":`1920`,width:`1920`,\"data-og-height\":`855`,height:`855`,\"data-path\":`images/how-to/connect-webhook/02-new-webhook-form.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=280\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=73fe7f7fdbc44335a5f68fb1d251c90d 280w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=560\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=284fca68ef756389eb859abe73d185bf 560w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=840\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=7fdd79e7c469a202d62246715b909e85 840w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=1100\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=8fd6878a671a9da091050779ca42595c 1100w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=1650\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=16321a85f8b5c6db002cea2f11d289b1 1650w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/02-new-webhook-form.png?w=2500\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=daba03d565f9808a37183d68a7fe6a33 2500w`})}),`\n`,_jsxs(_components.p,{children:[`Consultez `,_jsx(_components.a,{href:`/fr/api-reference/webhooks/configuration`,children:`Configuration`}),` pour le détail de chaque champ et `,_jsx(_components.a,{href:`/fr/api-reference/reference/webhooks/payloads`,children:`Payloads`}),` pour le contenu de chaque événement.`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`Lorsque vous créez le webhook, Bodyguard envoie un événement `,_jsx(_components.a,{href:`/fr/api-reference/reference/webhooks/payloads#webhook-validate`,children:_jsx(_components.code,{children:`webhook.validate`})}),` à votre endpoint. Votre endpoint doit y répondre avec un code de statut `,_jsx(_components.code,{children:`2xx`}),`.`]})}),`\n`]}),`\n`]})}),_jsxs(Step,{title:`Copier votre secret de signature`,children:[_jsxs(_components.p,{children:[`Bodyguard génère un secret de signature lorsque vous créez le webhook et l’affiche dans la fenêtre `,_jsx(_components.strong,{children:`Webhook created`}),`. Copiez-le avec l’icône de copie et conservez-le en lieu sûr, puis cliquez sur `,_jsx(_components.strong,{children:`Done`}),`. Le secret commence par `,_jsx(_components.code,{children:`whsec_`}),`.`]}),_jsx(Frame,{caption:`Secret de signature affiché à la création`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=3c03ea994fe4205b5afd49160524df63`,alt:`Fenêtre Webhook created avec le champ du secret de signature et son icône de copie en surbrillance`,\"data-og-width\":`1920`,width:`1920`,\"data-og-height\":`855`,height:`855`,\"data-path\":`images/how-to/connect-webhook/03-signing-secret.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=280\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=aa3538f23cd1dad773e1d82ae0ec908c 280w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=560\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=d55bfe01fe100da4f2526ca7770d5bf7 560w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=840\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=f1eecba2d6b73795a9ef5f8630d112fc 840w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=1100\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=c1f0489f47a04cc6d4e5ede26f2fa4f7 1100w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=1650\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=09f8f9755d889310d2ead711f1806c70 1650w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/03-signing-secret.png?w=2500\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=5f3e38cdc4e0654413f0c4a3f31f775d 2500w`})}),_jsx(Warning,{children:_jsx(_components.p,{children:`Le secret de signature n’est affiché qu’une seule fois. Vous ne pourrez plus le consulter après avoir fermé la fenêtre. Traitez-le comme un mot de passe et ne l’exposez jamais dans du code côté client.`})}),_jsxs(_components.p,{children:[`Vous utilisez le secret de signature pour vérifier que chaque requête provient bien de Bodyguard. Consultez le `,_jsx(_components.a,{href:`/fr/api-reference/webhooks/quick-start`,children:`Démarrage rapide`}),`.`]})]}),_jsxs(Step,{title:`Activer et tester votre webhook`,children:[_jsxs(_components.p,{children:[`Votre webhook est créé avec le statut `,_jsx(_components.code,{children:`Disabled`}),`. Activez-le lorsque votre endpoint est prêt à recevoir des événements. Cliquez sur le menu `,_jsx(_components.strong,{children:`⋮`}),` à la fin de la ligne du webhook pour ouvrir ses actions :`]}),_jsx(Frame,{caption:`Menu d'actions du webhook`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=f6f543e38882a16540b4c21afdfa074c`,alt:`Liste des webhooks avec le bouton trois points de la ligne du webhook (1) et son menu d'actions en surbrillance, affichant Send test event, Edit webhook, Enable webhook et Delete webhook`,\"data-og-width\":`1920`,width:`1920`,\"data-og-height\":`855`,height:`855`,\"data-path\":`images/how-to/connect-webhook/04-webhook-actions-menu.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=280\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=693c87578950f9fab077bc04cbbd3b56 280w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=560\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=7b5e4498c4b2f6ef79b3289ea4dc369d 560w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=840\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=8e6829461398e6ec1c5df5c97c7d7513 840w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=1100\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=3d34033a9ab020a202644cc5221bd5cf 1100w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=1650\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=d0125daa478ac5b6800c686754b8c548 1650w, https://mintcdn.com/bodyguardai/oGCRxEeuFI_d_hrR/images/how-to/connect-webhook/04-webhook-actions-menu.png?w=2500\u0026fit=max\u0026auto=format\u0026n=oGCRxEeuFI_d_hrR\u0026q=85\u0026s=1bdbd4386b0aa6f85b1040ec4bdd121f 2500w`})}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Enable webhook`}),` active le webhook.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Send test event`}),` vous permet de vérifier que votre endpoint reçoit des événements.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Edit webhook`}),` et `,_jsx(_components.strong,{children:`Delete webhook`}),` vous permettent de modifier ou de supprimer le webhook.`]}),`\n`]}),_jsx(Note,{children:_jsxs(_components.p,{children:[`Tant qu’un webhook est désactivé, Bodyguard n’envoie pas ses événements, et ils ne peuvent pas être rejoués lorsque vous réactivez le webhook. Consultez les `,_jsx(_components.a,{href:`/fr/api-reference/webhooks/configuration#statuts-du-webhook`,children:`statuts du webhook`}),`.`]})})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`étapes-suivantes`,children:`Étapes suivantes`}),`\n`,_jsxs(CardGroup,{cols:3,children:[_jsx(Card,{title:`Démarrage rapide`,icon:`rocket`,href:`/fr/api-reference/webhooks/quick-start`,children:_jsx(_components.p,{children:`Créez un endpoint et vérifiez chaque requête avec une bibliothèque Standard Webhooks.`})}),_jsx(Card,{title:`Configuration`,icon:`settings`,href:`/fr/api-reference/webhooks/configuration`,children:_jsx(_components.p,{children:`Événements, secret de signature, contacts et statuts du webhook.`})}),_jsx(Card,{title:`Gérer les erreurs`,icon:`triangle-alert`,href:`/fr/api-reference/webhooks/handling-errors`,children:_jsx(_components.p,{children:`Ce qui se passe lorsque votre endpoint échoue, et comment rétablir la situation.`})})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Connecter votre webhook","sidebarTitle":"Connecter votre webhook","description":"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.","href":"/fr/documentation/how-to/connect-webhook"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Prérequis","slug":"prérequis","depth":2,"children":[]},{"title":"Étapes","slug":"étapes","depth":2,"children":[]},{"title":"Étapes suivantes","slug":"étapes-suivantes","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"bodyguardai","siteName":"Bodyguard","title":"Connecter votre webhook - Bodyguard","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/en/documentation/how-to/connect-webhook","matchLevel":1},"fr":{"href":"/fr/documentation/how-to/connect-webhook","matchLevel":0}}},"lastModified":"2026-11-02T16:42:06.949Z","originalFileLocation":"fr/documentation/how-to/connect-webhook.mdx","locale":"fr"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"light\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Bodyguard\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Connecter votre webhook - Bodyguard\">\u003cmeta data-mint-head property=\"og:description\" content=\"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Bodyguard\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://bodyguardai.mintlify.app/_mintlify/api/og/v2?division=Guides+pratiques\u0026amp;title=Connecter+votre+webhook\u0026amp;description=Enregistrez+un+webhook+dans+le+dashboard+Bodyguard+pour+recevoir+des+notifications+sur+votre+endpoint.\u0026amp;theme=eb2f9429f7a5b336cace50d0\u0026amp;signature=690a0b9c03b4458ccac2a7be7f487f65aae11f6f15c6c2969a1a8fa553abea03\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Connecter votre webhook - Bodyguard\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://bodyguardai.mintlify.app/_mintlify/api/og/v2?division=Guides+pratiques\u0026amp;title=Connecter+votre+webhook\u0026amp;description=Enregistrez+un+webhook+dans+le+dashboard+Bodyguard+pour+recevoir+des+notifications+sur+votre+endpoint.\u0026amp;theme=eb2f9429f7a5b336cace50d0\u0026amp;signature=690a0b9c03b4458ccac2a7be7f487f65aae11f6f15c6c2969a1a8fa553abea03\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/bodyguardai/E1zFw9LKjEKggkfV/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Bodyguard\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#003c7c\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/fr/documentation/how-to/connect-webhook.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"fr\" href=\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://docs.bodyguard.ai/en/documentation/how-to/connect-webhook\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://docs.bodyguard.ai/en/documentation/how-to/connect-webhook\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.bodyguard.ai/#organization\",\"name\":\"Bodyguard\",\"url\":\"https://docs.bodyguard.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/bodyguardai/CXXaMNDOCYmwXYkN/images/logo-light.svg?fit=max\u0026auto=format\u0026n=CXXaMNDOCYmwXYkN\u0026q=85\u0026s=53fbcc63f9cb65a2b24e72faf85fcbc6\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.bodyguard.ai#website\",\"name\":\"Bodyguard\",\"url\":\"https://docs.bodyguard.ai\",\"publisher\":{\"@id\":\"https://docs.bodyguard.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook#webpage\",\"url\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\",\"name\":\"Connecter votre webhook\",\"description\":\"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\",\"dateModified\":\"2026-11-02T16:42:06.949Z\",\"isPartOf\":{\"@id\":\"https://docs.bodyguard.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Guides pratiques\",\"item\":\"https://docs.bodyguard.ai/fr/documentation/how-to/get-api-key\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Connecter votre webhook\",\"item\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook#article\",\"headline\":\"Connecter votre webhook\",\"name\":\"Connecter votre webhook\",\"description\":\"Enregistrez un webhook dans le dashboard Bodyguard pour recevoir des notifications sur votre endpoint.\",\"url\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook\",\"mainEntityOfPage\":{\"@id\":\"https://docs.bodyguard.ai/fr/documentation/how-to/connect-webhook#webpage\"},\"dateModified\":\"2026-11-02T16:42:06.949Z\",\"publisher\":{\"@id\":\"https://docs.bodyguard.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.bodyguard.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Bodyguard\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Bodyguard","nav":{"global":null,"languages":[{"language":"en","pages":[{"title":"en","href":"/en/documentation/how-to/connect-webhook"}]},{"language":"fr","tabs":[{"tab":"Documentation","groups":[{"group":"Pour commencer","pages":[{"title":"Introduction","href":"/fr/documentation/introduction"}]},{"group":"Guides pratiques","pages":[{"title":"Obtenir votre clé API","sidebarTitle":"Obtenir votre clé API","description":"Créez un compte de service et une clé API dans le dashboard Bodyguard pour authentifier vos requêtes API.","href":"/fr/documentation/how-to/get-api-key"},{"title":"Connecter votre webhook","sidebarTitle":"Connecter votre webhook","href":"/fr/documentation/how-to/connect-webhook"}]},{"group":"Taxonomie","pages":[{"title":"Classifications du texte","description":"Référence complète de la taxonomie de texte de Bodyguard : les signaux utilisés pour décrire le contenu et les classifications détectées.","href":"/fr/documentation/taxonomy/text-classifications"},{"title":"Classifications des images","href":"/fr/documentation/taxonomy/image-classifications"},{"title":"Classifications des noms d'utilisateur","href":"/fr/documentation/taxonomy/username-classifications"}]}]},{"tab":"Référence API","pages":[{"title":"Référence API","href":"/fr/api-reference/introduction"}]},{"tab":"Guide de migration","hidden":true,"pages":[{"title":"Guide de migration","href":"/fr/migration-guide/overview"}]}]}]},"basePath":"","title":"Connecter votre webhook - Bodyguard","buildId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","deploymentId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","dynamics":["07c022d89b","a74be98ba7","a9bb46feb3"],"chunks":["Frame-DXXFP6nH.js","DynamicMarkdown-B54_zNBF.js","zoom-image-lightbox-BG6oD64b.js","lightbox-handle-r17bVUz3.js","Markdown-DfhCTwyA.js","clsx-xpJZXxdP.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-BTZUMDnx.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-DqdKa2R4.js"]}