# A2uiUserAction

Artifact: [androidx.a2ui:a2ui-model](https://developer.android.com/jetpack/androidx/releases/a2ui) [View Source](https://cs.android.com/search?q=file:androidx/a2ui/model/protocol/A2uiUserAction.kt+class:androidx.a2ui.model.protocol.A2uiUserAction) Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui#1.0.0-alpha02)

*** ** * ** ***


```
sealed interface A2uiUserAction
```

<br />

Known direct subclasses [A2uiEventAction](https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiEventAction), [A2uiFunctionCallAction](https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiFunctionCallAction)

|---|---|
| `https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiEventAction` | Defines an event action triggered by a user interaction to be sent to the server. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiFunctionCallAction` | Defines a local component function execution action triggered by a user interaction. |

*** ** * ** ***

Defines an A2UI component user interaction.

## Summary

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiUserAction#componentId()` unique identifier of the component that was interacted with |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiUserAction#surfaceId()` unique identifier of the surface where the action occurred |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` | `https://developer.android.com/reference/kotlin/androidx/a2ui/model/protocol/A2uiUserAction#timestamp()` timestamp of when the action occurred, represented as milliseconds since the epoch |

## Public properties

### componentId

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui#1.0.0-alpha02)

```
val componentId: String
```

unique identifier of the component that was interacted with

### surfaceId

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui#1.0.0-alpha02)

```
val surfaceId: String
```

unique identifier of the surface where the action occurred

### timestamp

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui#1.0.0-alpha02)

```
val timestamp: Long
```

timestamp of when the action occurred, represented as milliseconds since the epoch