Delete Entities By Filter
Delete every database record in one table that matches filter_groups (the same filters Search Entities takes; at least one filter is required, and a request without one is refused with INVALID_ARGUMENT), for tables too large for Delete Entities. First call it without expected_count: nothing is deleted and matched_count says how many records match. Show that count to the user and get confirmation, then call it again with expected_count set to that count. If the matching set changed in between, the call fails with FAILED_PRECONDITION and nothing is deleted. Otherwise the records are deleted in the background in batches and job_id is returned; poll Get Entity Deletion Job for progress, and stop it with Cancel Entity Deletion Job. At most expected_count records are deleted. Tables with before-save workflows are refused with FAILED_PRECONDITION; use Delete Entities for those.
Authentication and permissions
Token requirements: User-based token (OAuth) or Organization-scoped API key or Workspace-scoped API key. Send a bearer access token for one of these identities. The permissions and resource restrictions below also apply.
- Delete matching records in a workspace’s database: Owner-only: the permission is checked on the table’s owning workspace. Worker tokens are refused. The background job re-checks the API key or user’s DELETE_ENTITY permission before every batch and stops if it was revoked.

