> For the complete documentation index, see [llms.txt](https://docs.optty.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.optty.com/hosted-payment-page/in-store-use-case.md).

# In Store Use Case

Optty Direct lets a terminal or POS offer every Optty payment method in-store. The terminal requests a payment link from Optty and displays the returned QR code, and the customer completes the payment on their own device. The final status is sent to the terminal by webhook and shown to the customer on the Optty Direct page.

To keep checkout as short as possible, the steps that add friction are optional:

* **Payment method selection** on the Optty Direct page is skipped when the customer's choice is passed from the terminal.
* **Customer information** collected is dynamic, adapting to the requirements of the chosen payment method.

For the request and webhook details, see [In Store API Integration](https://docs.optty.com/hosted-payment-page/in-store-use-case/in-store-api-integration.md).

### 1. Customer Experience

| Step                               | Where                        | When it happens                                      |
| ---------------------------------- | ---------------------------- | ---------------------------------------------------- |
| 1. Customer selects payment method | Terminal                     | Optional, otherwise the customer selects at step 4   |
| 2. Customer scans QR code          | Terminal → customer device   | Always                                               |
| 3. Customer information            | Customer device              | Only if the payment method requires it               |
| 4. Payment method selection        | Customer device              | Only if no payment method was chosen on the terminal |
| 5. Payment                         | Customer device              | Always                                               |
| 6. Status displayed                | Customer device and terminal | Always                                               |

#### 1.1 Customer Selects Payment Method

Once the cashier has entered the amount of the purchase, the customer chooses on the terminal to pay with an alternative payment method. The terminal can offer:

* **Specific payment methods.** The customer's choice is passed when the payment link is created and step 4 is skipped.
* **A "Pay another way" option.** The customer is shown the list of available payment methods and selects one on their device at step 4.

#### 1.2 QR Code

The terminal creates an Optty Direct payment link and displays the returned QR code. The customer scans it with their mobile phone to open the Optty Direct page.

A timeout can be set on the payment link. When it expires, the Optty Direct link is cancelled along with any payment in progress with the payment method, and the terminal is notified.

#### 1.3 Customer Information

Some payment methods require customer or billing information before checkout can start. Only the fields required by the chosen payment method are displayed, and if no information is required this step is skipped. Each payment method sets its own requirements, which can be taken into account when choosing which payment methods to offer.

The example below shows the maximum information that could be requested, which is unrealistic in practice. Only the minimum fields required are displayed.

<figure><img src="https://content.gitbook.com/content/fCUCEi1845pQGMcbjae6/blobs/wrJBR78YkcYVihYfJeoM/Optty%20Direct%20In%20Store%20Step%201%20(1).png" alt="" width="563"><figcaption></figcaption></figure>

#### 1.4 Payment Method Selection

If no payment method was chosen on the terminal, the customer is shown the payment methods enabled for the merchant and selects one to continue.

<figure><img src="https://content.gitbook.com/content/fCUCEi1845pQGMcbjae6/blobs/Ybawyqf7CiiYnyR0Ac7W/Optty%20Direct%20In%20Store%20Step%202_%20Decision.png" alt="" width="563"><figcaption></figcaption></figure>

#### 1.5 Payment

The customer completes checkout on their device with their chosen payment method.

<figure><img src="https://content.gitbook.com/content/fCUCEi1845pQGMcbjae6/blobs/QAYm63L7G8Pbs0vN7x2a/Optty%20Direct%20In%20Store%20Step%203_%20Payment.png" alt="" width="563"><figcaption></figcaption></figure>

#### 1.6 Status Displayed

The final transaction status is shown to the customer on the Optty Direct page and sent to the terminal by webhook, so the cashier sees the same result.

<figure><img src="https://content.gitbook.com/content/fCUCEi1845pQGMcbjae6/blobs/wZQLTJUWbcw0Ry3c1fUx/Optty%20Direct%20In%20Store%20Step%204_%20Status%20Displayed.png" alt="" width="563"><figcaption></figcaption></figure>

### 2. Technical Flow

Below is an example of the technical API flow for Optty Direct payments in the In-Store use case. It can be converted to an invoice flow by replacing the cashier and terminal with an employee and invoicing system respectively.

<figure><img src="https://content.gitbook.com/content/fCUCEi1845pQGMcbjae6/blobs/RU5Fl9p1exLIqXms9nkl/Optty%20Direct%20In%20Store%20Flow.svg" alt="" width="563"><figcaption><p>Use Case Flow with In Store</p></figcaption></figure>
