---
title: AnyTransientAppEntity
framework: appintentstesting
role: symbol
role_heading: Structure
path: appintentstesting/anytransientappentity
---

# AnyTransientAppEntity

A type-erased representation of a transient app entity that provides dynamic property access.

## Declaration

```swift
@dynamicMemberLookup struct AnyTransientAppEntity
```

## Overview

Overview Use AnyTransientAppEntity to work with transient entities when you don’t know the specific entity type at compile time. // Getting transient entity definitions. let definitions = IntentDefinitions(bundleIdentifier: "com.apple.example") let sessionEntity = definitions.transientEntities["UserSessionEntity"]

// Creating a transient entity with properties. var entity = sessionEntity.withProperties(     name: "John Doe",     age: 30 )

// Accessing properties with type safety. let userName: String? = try entity.name let userAge: Int? = try entity.age

// Accessing nested properties (requires try). if try entity.profile.name == "John Doe" {     print("User found") }

## Topics

### Identifying the entity type

- [entityType](appintentstesting/anytransientappentity/entitytype.md)

### Instance Methods

- [exported(as:)](appintentstesting/anytransientappentity/exported(as:)-2rmw6.md)
- [exported(as:)](appintentstesting/anytransientappentity/exported(as:)-7mrbg.md)
- [exported(as:)](appintentstesting/anytransientappentity/exported(as:)-8zhnu.md)

### Subscripts

- [subscript(dynamicMember:)](appintentstesting/anytransientappentity/subscript(dynamicmember:)-5ygut.md)
- [subscript(dynamicMember:)](appintentstesting/anytransientappentity/subscript(dynamicmember:)-63vyv.md)
- [subscript(dynamicMember:)](appintentstesting/anytransientappentity/subscript(dynamicmember:)-8pfwv.md)

## Relationships

### Conforms To

- [Copyable](swift/copyable.md)
- [Equatable](swift/equatable.md)
- [Escapable](swift/escapable.md)
- [IntentValueConvertible](appintents/intentvalueconvertible.md)
- [IntentValueExpressing](appintents/intentvalueexpressing.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Intermediate types

- [AnyAppIntent](appintentstesting/anyappintent.md)
- [AnyAppEntity](appintentstesting/anyappentity.md)
- [AnyEntityQuery](appintentstesting/anyentityquery.md)
- [AnyAppEnum](appintentstesting/anyappenum.md)
