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

# Retrieve a SMART Health Link

> How a provider system or EHR retrieves data from a haau3 SMART Health Link after scanning a QR code.

Provider systems and EHRs retrieve data from a SMART Health Link (SHLink) after scanning a QR
code or decoding the SHLink payload. The decoded payload contains a `url` that points to the
SMART Health Link resource server.

haau3 implements the retrieval protocol defined by the
[SMART Health Links specification](https://build.fhir.org/ig/HL7/smart-health-cards-and-links/links-specification.html).
Depending on the flags present in the decoded SHLink payload, the receiving application
retrieves the data using one of two methods.

## Retrieval methods

| Method                  | HTTP   | When used                                                                                     | Response           |
| ----------------------- | ------ | --------------------------------------------------------------------------------------------- | ------------------ |
| **Direct file request** | `GET`  | The SHLink payload contains the `U` flag. The encrypted file is returned directly.            | `application/jose` |
| **Manifest request**    | `POST` | No `U` flag is present. The server returns a manifest describing one or more encrypted files. | `application/json` |

## Choose a method

<CardGroup cols={2}>
  <Card title="Direct file request (GET)" icon="file-arrow-down" href="/app/provider-integration/direct-file-request">
    Retrieve the encrypted payload directly when the SHLink payload contains the `U` flag.
  </Card>

  <Card title="Manifest request (POST)" icon="list" href="/app/provider-integration/manifest-request">
    Retrieve a SMART Health Link manifest when no `U` flag is present.
  </Card>
</CardGroup>

<Note>
  To understand the FHIR bundle you get back after decrypting, see
  [Bundle & artifact reference](/app/provider-integration/bundle-and-artifacts).
</Note>
