---
title: MKDirections.ETAHandler
framework: mapkit
role: symbol
role_heading: Type Alias
path: mapkit/mkdirections/etahandler
---

# MKDirections.ETAHandler

The block to use for processing travel-time information.

## Declaration

```swift
typealias ETAHandler = (MKDirections.ETAResponse?, (any Error)?) -> Void
```

## Parameters

- `response`: The response parameter contains the travel-time response. If an error occurs or the framework can’t determine the travel time, this parameter is nil.
- `error`: The error parameter contains information about any errors that occur. If no errors occur, this parameter is nil.

## Discussion

Discussion The implementation of your block needs to check for a value in the error parameter and, if that parameter is nil, incorporate the travel-time information from the response parameter.

## See Also

### Getting the ETA

- [calculateETA(completionHandler:)](mapkit/mkdirections/calculateeta(completionhandler:).md)
- [MKDirections.ETAResponse](mapkit/mkdirections/etaresponse.md)
