applyPreset

abstract suspend fun applyPreset(connection: MockzillaConnectionConfig, key: EndpointConfiguration.Key, dashboardOverridePreset: DashboardOverridePreset): Result<Unit>

Applies a dashboard preset to the endpoint identified by key on the device at connection, overriding the endpoint's response until the override is cleared.

Return

Result.success on success, Result.failure if the request could not be completed.

Parameters

connection

The device to target.

key

The key of the endpoint to update.

dashboardOverridePreset

The preset to apply.