---
updatedAt: 2026-03-24T12:18:29.000Z
agentTools:
  projectIndex: https://docs.clover.com/dev/llms.txt
---

# Receipts

[block:html]
{
  "html": "<meta name=\"description\" content=\"Learn how to close out all captured (AUTH payments) transactions.\">\n\n<!--DS-5851-->\n<!--DS-6147-->"
}
[/block]

[block:html]
{
  "html": "<div class=\"container-top\">\n  <!--United States-->\n  <div class=\"container-reg\">\n    <div class=\"pill-reg\">\n      <div class=\"label-reg\">United States</div>\n    </div>\n  </div>\n\n</div>\n<!-- CSS moved to global stylesheet-->\n<!--REMOVE\n<style>\n.container-top {\n  top: -15px;\n  position: relative;\n  margin-bottom: -5px;\n}\n\n.container-reg {\n  align-items: center;\n  min-width: auto; \n  width: fit-content;\n  text-align: left;\n  overflow: auto;\n  display: inline-block; \n}\n\n/*Pill format REG*/\n.pill-reg {\n  background: #44BB44;\n  border: .5px solid #44BB44;\n  margin-left: 5px;\n  overflow: auto;\n  display: flex; \n  justify-content: center; \n  align-items: center; \n  border-radius: 10px;\n  height: 1.8rem;\n  margin-top: 10px;\n  margin-bottom: 1.5px; \n  padding: 0 10px; \n}\n\n/*Text FORMAT inside REG pills */\n.pill-reg .label-reg, \n.pill-reg__addon .label-reg \n{\n  font-style: normal;\n  font-weight: normal;\n  font-size: 12px;\n  color: #fff;\n  vertical-align: middle;\n  margin: 0;\n  padding: 0 5px;\n}\n</style>-->"
}
[/block]

Send an order receipt to a user for their transactions. For more information, see [Supported payment methods](https://docs.clover.com/docs/clover-go-sdk#supported-payment-transactions).

# Prerequisites

Before you integrate with the Go SDK, complete the following:

* [Create a global developer account](https://docs.clover.com/docs/gdp-create-global-developer-account) with a default test merchant account.
* Create [additional test merchants](https://docs.clover.com/docs/use-test-merchants-dashboard#create-additional-test-merchants), if needed.
* [Create an app](https://docs.clover.com/docs/creating-an-app) in the sandbox.
* Create at least one [employee](https://docs.clover.com/docs/clover-data-model#employees) role user for the [OAuth flow](https://docs.clover.com/docs/clover-oauth-on-mobile).
* Order a [Clover Go reader Developer Kit (Dev Kit)](https://cloverdevkit.com/) and [set it up](https://docs.clover.com/docs/clover-dev-kits#set-up-devices-and-dev-kits).

# Field descriptions

## SendReceiptRequest

[block:parameters]
{
  "data": {
    "h-0": "Field",
    "h-1": "Required",
    "h-2": "Type",
    "h-3": "Description",
    "0-0": "`orderId`",
    "0-1": "true",
    "0-2": "String",
    "0-3": "Clover-assigned universally unique identifier (UUID) for the order for which the receipt is to be sent.  \n  \n**Note**: The orderID is different from PaymentId and is part of the order that is received as PayResponse for the PayRequest that was sent.  \n  \n**Length:** 13 characters.",
    "1-0": "`emailAddress`",
    "1-1": "false",
    "1-2": "String",
    "1-3": "Email address to which a receipt is to be sent. It can be null if the phone number is provided.",
    "2-0": "`phoneNumber`",
    "2-1": "false",
    "2-2": "String",
    "2-3": "Phone number to which receipt is to be sent via SMS. It can be null if an email address is provided"
  },
  "cols": 4,
  "rows": 3,
  "align": [
    "left",
    "left",
    "left",
    "left"
  ]
}
[/block]

## SendReceiptResponse

| Field               | Type   | Description                                  |
| :------------------ | :----- | :------------------------------------------- |
| `sendReceiptStatus` | String | Indicates whether a receipt was sent or not. |

> 📘 NOTE
>
> The refund transaction details appear on the receipts if the reversalRequest is sent for the payments.

# Android

## Request details

To send an order receipt, enter values in the `PaymentReceiptDeliveryRequest` request parameters.

The following are the response scenarios for the SendReceiptState:

* Successful request returns `OnSendReceiptComplete` with `ReceiptDeliveryResponse`.
* Failed request returns an error. For example, a validation error returns `OnSendReceiptError`.

## Response  details—SendReceiptState

| Field                   | Description                                                                                                                                      |
| :---------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------- |
| `OnSendReceiptComplete` | Indicates the receipt was sent successfully using the method mentioned under ReceiptDeliveryOption. See the ReceiptDeliveryResponse for details. |
| `OnSendReceiptError`    | Indicates the error occurred, and the receipt wasn't sent. See the CloverError types.                                                            |

## CloverError

The following are valid CloverError types:

| Type                   | Description                                                                    |
| :--------------------- | :----------------------------------------------------------------------------- |
| CloverSendReceiptError | Indicates a validation error in SendReceipt. Example: INVALID\_EMAIL\_ADDRESS  |
| CloverNetworkError     | Indicates the merchant status of a declined or pending status from the server. |

## SendReceipt request example

```Text SendReceipt Request
fun sendReceipt(request: SendReceiptRequest): Flow<SendReceiptState>
```

```kotlin Kotlin SendReceipt example
lifecycleScope.launch {
    val request = SendReceiptRequest(
        orderId = orderId,
        emailAddress = emailAddress,
        phoneNumber = phoneNumber
    )
 
    goSdk.sendReceipt(
        request
    ).collectLatest { sendReceiptState ->
 
        when (sendReceiptState) {
            is SendReceiptState.OnSendReceiptError -> {
                println("Receipt request failed: ${sendReceiptState.error}")
                updateUI(sendReceiptState)
            }
            is SendReceiptState.OnSendReceiptComplete -> {
                println("Receipt sent successfully: ${sendReceiptState.response}")
                updateUI(sendReceiptState)
            }
            else -> {
                //Something unexpected happened
            }
        }
    }
}
```

# iOS

Enter an `orderId` followed by an email address or phone number.

**Note:** If both an email and a phone number are provided, a message is sent to both the phone and the email for validation.

To send an order receipt, enter values in the `sendReceipt` request parameters. See [sendReceipt](https://docs.clover.com/docs/receipts#sendreceiptrequest).

```swift Swift SendReceipt example
let sendReceiptRequest = SendReceiptRequest(orderId: orderId, emailAddress: emailTF?.text, phoneNumber: phoneTF.text)
 
do {
   try await CloverPaymentSDK.shared.sendReceipt(sendReceiptRequest)
   print("Receipt Sent")
} catch {
   print("Receipt Error: \(error)")
}
```