Skip to content

basalt / drives/src / DriveConnectionCandidates

Type Alias: DriveConnectionCandidates ​

> DriveConnectionCandidates = readonly DriveConnection[] | ((query) => Promise<readonly DriveConnection[]> | readonly DriveConnection[])

Defined in: drives/src/notifications.ts:110

Where candidate connections come from.

An array for the simple case. A function for Dropbox, whose webhook URI is registered once per app: a notification arrives naming account ids and no tenant at all, so the app must look connections up by (provider, account.id) — a lookup that necessarily spans tenants. That is safe precisely because the id came from a signature-verified payload and never from the caller, and it stays the app's query rather than becoming a framework-wide table scan.

Released under the MIT License.