# Send Digital Receipt

## tapToPaySdk.requestDigitalReceipt(transactionId: String, email: String) async throws -> Bool

Sends a digital receipt after the transaction completes. See [TransactionOutcome](/pos/embedded-payments/iphone/sdk/transaction-outcome).


```swift
public func requestDigitalReceipt(transactionId: String, email: String) async throws -> Bool
```

### Parameters


```json
{
  "type": "object",
  "properties": {
    "transactionId": {
      "type": "String",
      "description": "The transactonId returned in the TransactionOutcome."
    },
    "email": {
      "type": "String",
      "description": "The recipient of the digital receipt email."
    }
  },
  "required": [
    "transactionId",
    "email"
  ]
}
```

### Returns

Returns `true` if the email request was successfully sent. Note: The email may take a new minutes to be sent. A response of `true` does not guaratee the email was sent successfully to the receipient.

### Throws

#### TapToPaySDKError.invalidParameter(String)

Throws `TapToPaySDKError.invalidParameter` if there is an issue with one of the parameters. For example, if the transactionId/email is blank, or if the email supplied is invalid.

See [TapToPaySDKError](/pos/embedded-payments/iphone/sdk/errors) for more details on errors thrown.