> For the complete documentation index, see [llms.txt](https://docs.ngsurvey.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ngsurvey.com/fr/form-management/tasks/task-items/webhook.md).

# Webhooks

## ☁️ Que sont les Webhooks ?

Les Webhooks sont un excellent moyen d’envoyer le répondant et ses réponses à n’importe quel endpoint API HTTP dès que le répondant a été enregistré dans la base de données ngSurvey.

## 🔅 Propriétés des Webhooks

* **`URL du Webhook`** de l’API REST ou du serveur HTTP qui doit recevoir le post de la charge utile JSON du répondant.
* **`Modèle de transformation de la charge utile`** utilisé pour changer la structure de la charge utile JSON postée en une autre structure d’objet personnalisée.

## 🔤 Format du post

Le répondant et ses réponses sont envoyés sous forme de charge utile au format JSON en utilisant une requête HTTP POST. La charge utile JSON par défaut ci‑dessous peut être personnalisée à l’aide d’un [modèle de transformation de la charge utile](/fr/form-management/tasks/task-items/webhook/webhooks-payload-transform.md).

```javascript
{
  respondent: {
    id: string;
    surveyId: string;
    panelistId: string;
    contextUsername: string
    resumeUId: string;
    resumePageId: string;
    startDate: Date;
    voteDate: Date;
    iPSource: string;
    changeUID: string;
    progressSaveDate: Date;
    languageCode: string;
    timeToEnd: number;
    validated: boolean;        
  },
  answers: [{
      respondentId: string,
      value:string,
      answerId": string,
      answerText": string,
      questionId": string,
      questionAlias": string,
      questionText": string,
      sectionNumber": number
  }],
  visitedPages: [{
    id: string;
    respondentId: string;
    visitTime: string;
  }],
  dataAttributes: [{
    securityItemId: string;
    respondentId: string;
    attributeName: string;
    attributeValue: string;
  }],
  querystring: string
}
```

{% hint style="info" %}
Réponses chiffrées avec [restreint](/fr/data-encryption/data-classification/restricted.md) la classification des données sera envoyée sous forme de message PGP chiffré.&#x20;
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.ngsurvey.com/fr/form-management/tasks/task-items/webhook.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
