---
title: CredentialSession.PresentmentIntentAssertion
framework: secureelementcredential
role: symbol
role_heading: Class
path: secureelementcredential/credentialsession/presentmentintentassertion
---

# CredentialSession.PresentmentIntentAssertion

An object that signals your app’s intention to make exclusive use of the device’s contactless features.

## Declaration

```swift
final class PresentmentIntentAssertion
```

## Mentioned in

Accessing and using secure element credentials

## Overview

Overview Create an instance of this type to obtain a 60-second exclusive use window of the user interface for a selected credential. This prevents interruptions to your app from Wallet, any other default contactless app, or other apps using the SecureElementCredential framework. note: A presentment intent assertion isn’t required before launching the presentment sheet. The assertion expires when any of the following occur: The assertion instance deinitializes. You call the relinquish() method to indicate that you no longer need the assertion. The system’s 60-second timeout expires. The session encounters a CredentialSession.Event.cardEmulationTimeout, potentially caused by one of the performTransaction methods. Apps can only acquire an assertion 15 seconds after relinquishing the previous assertion. Any of the transaction methods automatically acquire an internal instance of the PresentmentIntentAssertion. Because of this, call relinquish() prior to using the transaction methods. The following sequence shows how this works in a SwiftUI application: Call acquirePresentmentAssertion() before showing any proprietary payment UI. 2.Call relinquish() to stop using the assertion before invoking the transaction method. Invoke configuration() to start a transactionTask. Perform the transaction with the transactionTask. Call invalidate() after presenting the credential. Optionally, call acquirePresentmentAssertion()  to finish up any proprietary payment UI. Call relinquish() again to end use of the assertion. In a UIKit app, use the following approach: Call acquirePresentmentAssertion() prior to showing any proprietary payment UI. Call relinquish() to stop using the assertion before invoking the transaction API. Perform the transaction task. Optionally, call acquirePresentmentAssertion() to finish up any proprietary payment UI. Call relinquish() again to end use of the assertion.

## Topics

### Inspecting assertion state

- [state](secureelementcredential/credentialsession/presentmentintentassertion/state-swift.property.md)
- [CredentialSession.PresentmentIntentAssertion.State](secureelementcredential/credentialsession/presentmentintentassertion/state-swift.enum.md)

### Relinquishing presentment intent

- [relinquish()](secureelementcredential/credentialsession/presentmentintentassertion/relinquish().md)

## See Also

### Acquiring exclusive foreground privileges

- [acquirePresentmentAssertion()](secureelementcredential/credentialsession/acquirepresentmentassertion().md)
