Skip to content

BatchUpdateDevicePosition

Source: src/AWS/Location/BatchUpdateDevicePosition.ts

Uploads position updates for up to 10 devices to the tracker (also triggers geofence evaluation for linked collections).

Runtime binding for the BatchUpdateDevicePosition operation (IAM action geo:BatchUpdateDevicePosition), scoped to one Tracker. Provide the implementation with Effect.provide(AWS.Location.BatchUpdateDevicePositionHttp).

const updatePositions = yield* Location.BatchUpdateDevicePosition(tracker);
yield* updatePositions({
Updates: [
{
DeviceId: "vehicle-1",
Position: [-122.3493, 47.6205], // [longitude, latitude]
SampleTime: new Date(),
},
],
});