1import type * as location from "@distilled.cloud/aws/location";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Tracker } from "./Tracker.ts";
5
6/**
7 * `BatchGetDevicePosition` request with `TrackerName` injected from the bound
8 * resource.
9 */
10export interface BatchGetDevicePositionRequest extends Omit<
11 location.BatchGetDevicePositionRequest,
12 "TrackerName"
13> {}
14
15/**
16 * Retrieves the latest position for up to 10 devices from the tracker in one call.
17 *
18 * Runtime binding for the `BatchGetDevicePosition` operation (IAM action
19 * `geo:BatchGetDevicePosition`), scoped to one {@link Tracker}. Provide the implementation with
20 * `Effect.provide(AWS.Location.BatchGetDevicePositionHttp)`.
21 *
22 * ### Reading Device Positions
23 * **Example:** Read Several Devices at Once
24 * ```typescript
25 * const batchGet = yield* Location.BatchGetDevicePosition(tracker);
26 *
27 * const result = yield* batchGet({ DeviceIds: ["vehicle-1", "vehicle-2"] });
28 * // result.DevicePositions → found positions, result.Errors → per-device failures
29 * ```
30 *
31 * @binding
32 */
33export interface BatchGetDevicePosition extends Binding.Service<
34 BatchGetDevicePosition,
35 "AWS.Location.BatchGetDevicePosition",
36 (
37 tracker: Tracker,
38 ) => Effect.Effect<
39 (
40 request: BatchGetDevicePositionRequest,
41 ) => Effect.Effect<
42 location.BatchGetDevicePositionResponse,
43 location.BatchGetDevicePositionError
44 >
45 >
46> {}
47export const BatchGetDevicePosition = Binding.Service<BatchGetDevicePosition>(
48 "AWS.Location.BatchGetDevicePosition",
49);