> ## Documentation Index
> Fetch the complete documentation index at: https://docs.argyle.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Users Webhooks

> Learn about users webhooks.

API integrations should be designed to leverage Argyle's webhooks so you are notified in real-time when each data resource is available for retrieval. Webhooks can also return full resources when they become available. See the rest of our Webhooks Reference for a complete list.

## Fully synced

**POST** `/v1/webhooks`

Implement the `users.fully_synced` webhook to be notified when [data retrieval](/legacy/api-reference/data-retrieval) has completed for **all** accounts successfully connected by a user.

* Once the `users.fully_synced` webhook is received, data and documents for all accounts successfully connected by a user are fully available via Console or the API.
* If the user connects multiple payroll accounts, the `users.fully_synced` webhook will only be sent if at least one of the accounts has successfully connected. The webhook will not be sent if all accounts fail to connect.
* The `users.fully_synced` webhook is not sent immediately upon successful account connection by a user. Data is pulled from payroll platforms and [delivered gradually](/legacy/api-reference/data-retrieval#gradual-data-delivery).

### Request body

### Webhook message

* `name` (string, optional): Name used for the webhook subscription.
* `data` (object, optional)
* `user` (string (uuid), optional): ID of the user.
* `resource` (object, optional)
* `id` (string (uuid), optional): ID of the user.
* `data_providers_connected` (array of strings, optional): The Link items through which the user connected their payroll accounts in Link.
* `employers_connected` (array of strings, optional): Names of the employers associated with the Link items.

<Tabs>
  <Tab title="curl">
    ```bash theme={}
    curl --request POST \\
    --url https://api.argyle.com/v1/webhooks \\
    --header 'accept: application/json' \\
    --header 'content-type: application/json' \\
    --data '{
    "events": ["users.fully_synced"],
    "name": "name-for-the-webhook-subscription",
    "url": "https://your-webhook-backend.com",
    "secret": "optional-secret"
    }'
    ```
  </Tab>

  <Tab title="python">
    ```python theme={}
    import requests
    url = "https://api.argyle.com/v1/webhooks"
    payload = {
    "events": ["users.fully_synced"],
    "name": "name-for-the-webhook-subscription",
    "url": "https://your-webhook-backend.com",
    "secret": "optional-secret"
    }
    headers = {
    "accept": "application/json",
    "content-type": "application/json"
    }
    response = requests.post(url, json=payload, headers=headers)
    ```
  </Tab>
</Tabs>

```json theme={}

{
  "event": "users.fully_synced",
"name": "<name for your webhook>",
"data": {
"user": "01838ad1-b6bd-22f8-22f1-d3f5b3953484",
"resource": {
"id": "01838ad1-b6bd-22f8-22f1-d3f5b3953484",
"data_providers_connected": [
"mypayroll_platform"
],
"employers_connected": [
"Whole Goods",
"SprintCar"
],
"external_metadata": {},
"created_at": "2022-09-29T19:55:43.166Z"
}
}
},
null,
2
  
```
