﻿# SCIM pagination: an unobserved account is not a confirmed removal

A failed or changing directory sweep can make valid users appear absent. Separate page observations, stable identity and authority for access-removal reconciliation.

Author: Retrivium team
Updated: 2026-11-06
Canonical URL: https://retrivium.ai/journal/enterprise-ai-scim-pagination-absence-removal-authority/
Language: en

## Do not turn an incomplete directory sweep into removal authority

An enterprise assistant synchronizes users through SCIM and disables local access for identities absent from the latest sweep. A page request fails, but the sync worker treats the collected prefix as a complete directory. Valid accounts then appear to have disappeared. The operating question is what evidence permits a reconciliation process to interpret absence, rather than merely whether each received page contains valid user objects.

## Read pagination as changing query results

[RFC 7644](https://www.rfc-editor.org/rfc/rfc7644.html) explicitly says SCIM pagination is not stateful and clients must handle inconsistent results when resources change between requests. Its list response distinguishes totalResults, Resources, startIndex and itemsPerPage. A sequence of successful page requests is not automatically a frozen directory snapshot. Preserve requested filter and returned page metadata so the run's scope remains explainable if the total or membership changes during collection.

## Match resources by stable provider identity

[RFC 7643](https://www.rfc-editor.org/rfc/rfc7643.html) defines the provider-issued resource id as stable and non-reassignable. Use that identity, together with the intended provider context, when reconciling a sweep. Renamed display fields should not create a new account and make the old one look absent. Deduplicating repeated resource identifiers can make collection bookkeeping clearer, but cannot prove that an omitted resource was deleted or that the sweep observed one consistent point in time.

## Define the evidence needed for destructive reconciliation

Separate observed-present, explicitly removed and not-observed-in-this-run states. A failed request, changed query scope or incomplete sweep should remain visible rather than become a deletion list. Where the provider offers a stronger change feed or explicit removal contract, use its documented semantics; base SCIM pagination alone does not supply one. The application can require direct confirmation or a reviewed reconciliation policy before disabling an identity solely because it was absent from collection.

## Rehearse movement and interruption between pages

Use harmless test identities and record the intended directory scope. During the sweep, rename one resource, change membership and interrupt a page response. Observe collected provider identifiers, page outcomes and the final reconciliation status. Acceptance requires incomplete collection to remain incomplete and unconfirmed absence to avoid the authoritative-removal path. Also verify that a separately confirmed removal still receives the intended handling. These are proposed integration checks; no directory service or deprovisioning operation was exercised here.

## Explain completion without inventing snapshot guarantees

[Compound keyset pagination](/journal/guide-postgres-keyset-compound-boundary/) concerns a different continuation mechanism and also separates traversal from a frozen dataset. [Cloud team credential inventory](/journal/cloud-gpu-account-team-key-rotation/) addresses the access paths that an actual departure may require revoking. Here the narrow result is a directory observation with a declared completeness status. Report failures and changing scope alongside reconciled identities. A parsed page, a matching record count or an apparently empty final page cannot independently establish that every unobserved employee has lost their entitlement.
