> For the complete documentation index, see [llms.txt](https://docs.hiveauth.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hiveauth.com/developer-documentation/has-for-applications/attach.md).

# Attach

At any time, a connection between the **APP** and the **HAS** infrastructure may be interrupted. It is then important that the **APP** can reconnect and know if a request that it sent to the **HAS** has already been processed by a **PKSA** or is still pending.

Fortunately, the **HAS** protocol has a feature to resume such interaction.

When an **APP** wants to resume a broken session, it can ask the **HAS** to reconnect its socket with the request identifier previously received. To do so, the **APP** sends the following message:

### attach\_req

```
{
    cmd: "attach_req", 
    uuid: string
}
```

{% tabs %}
{% tab title="Properties" %}

* **`uuid`** {string} the  request identifier
  {% endtab %}
  {% endtabs %}

If the request has not expired, the **HAS** server will confirm the reconnection with the following message:

### attach\_ack

```
{
    cmd: "attach_ack", 
    uuid: string
}
```

{% tabs %}
{% tab title="Properties" %}

* **`uuid`** {string} the  request identifier
  {% endtab %}
  {% endtabs %}

If the request has expired, or if the response it received from the **PKSA** has expired, the **HAS** server will inform the **APP** that it is no longer handling the request with the following message:

### attach\_nack

```
{
    cmd: "attach_nack", 
    uuid: string
}
```

{% tabs %}
{% tab title="Properties" %}

* **`uuid`** {string} the  request identifier
  {% endtab %}
  {% endtabs %}
