scheduleCollections

fun scheduleCollections(collectionInterval: Duration, vararg credentials: TSCredentials)

Enqueues (or replaces) one independent recurring WorkManager job per credentials entry. Each job collects and uploads signals on its own and can be cancelled individually via stopScheduledCollections. Calling again with the same account ID replaces that account's existing schedule.

Every worker is self-contained: it carries its own credentials via WorkManager's androidx.work.Data, so it persists across app restarts.

Parameters

collectionInterval

How often to collect and upload. Must be at least MIN_COLLECTION_INTERVAL.

credentials

One or more credential sets. Each produces one independent periodic job.

Throws