getGeofence method
Retrieves the geofence details from a geofence collection.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter collectionName :
The geofence collection storing the target geofence.
Parameter geofenceId :
The geofence you're retrieving details for.
Implementation
Future<GetGeofenceResponse> getGeofence({
required String collectionName,
required String geofenceId,
}) async {
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/geofencing/v0/collections/${Uri.encodeComponent(collectionName)}/geofences/${Uri.encodeComponent(geofenceId)}',
exceptionFnMap: _exceptionFns,
);
return GetGeofenceResponse.fromJson(response);
}