> For the complete documentation index, see [llms.txt](https://support.whapi.cloud/help-desk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.whapi.cloud/help-desk/receiving/http-api/restoring-missing-messages-using-resync.md).

# Restoring Missing Messages Using Resync

In situations where incoming or outgoing WhatsApp messages are temporarily inaccessible (returning a 404 error via HTTP GET requests), Whapi.Cloud provides a resync functionality allowing you to recover these messages into your cache.

#### When to Use the Resync Function

* Messages sent or received during internal synchronization issues.
* HTTP GET requests for messages returning a 404 error.
* Quoting a message that returns a 404 error.

#### How to Resync Messages

Send a GET request with the `resync=true` parameter to the Whapi endpoint:\
`GET https://gate.whapi.cloud/messages/{MessageID}?resync=true`

{% hint style="warning" %}

* Make sure that the linked phone is connected to the network during the request (it is sufficient for the phone to be simply turned on).&#x20;
* Processing the request takes 15 seconds and may return a 404 response, but this does not indicate an error.
  {% endhint %}

The HTTP GET request for the message will cease returning a 404 within a few minutes, allowing you to reference and use the message ID normally.

#### Important Considerations

**After resyncing, a webhook notification about the message will be triggered!** If you have automation scripts or bots configured to listen for new message webhooks, temporarily disable them to avoid unintended processing of these restored messages.

<figure><img src="/files/G2ruQRRXAfD0ITIpWVuy" alt=""><figcaption></figcaption></figure>


---

# 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://support.whapi.cloud/help-desk/receiving/http-api/restoring-missing-messages-using-resync.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.
