scim2-models
SCIM2 models serialization and validation with pydantic
What it is and what it does
scim2-models wraps the SCIM2 specification (RFC7643 and RFC7644) in Pydantic v2 models, letting you work with identity provisioning data—users, groups, service provider configs, schemas—as validated Python objects instead of raw JSON. It handles the schema complexity of SCIM2, including field mutability, returned status, uniqueness constraints, and context-aware validation based on HTTP operations (creation, query, replacement, etc.).
The library is designed as a foundation for building SCIM2 servers and clients. It provides native classes for core resources, supports dynamic schema extensions, and includes SCIM message types like ListResponse, SearchRequest, PatchOp, and Error. Validation and serialization are handled by Pydantic, giving you IDE autocompletion and type safety out of the box.
Use it for:
- Build a SCIM2 identity provider server that accepts user and group provisioning requests from applications.
- Implement a SCIM2 client that syncs users and groups from a central directory to downstream SaaS applications.
- Validate incoming SCIM2 payloads in an API gateway or middleware before processing.
- Generate SCIM2-compliant error responses with automatic conversion from Python exceptions.
- Define and enforce custom SCIM2 schema extensions for organization-specific user attributes.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides Pydantic models for SCIM2 (System for Cross-domain Identity Management) resources, enabling parsing and validation of SCIM2 payloads as native Python objects for building identity provisioning servers and clients.
Yes. The package is actively maintained, has no known vulnerabilities, installs with minimal friction (one dependency), and directly implements the SCIM2 RFCs with Pydantic integration. It is a solid choice if you are building identity provisioning infrastructure. The alpha status reflects ongoing development, but the core functionality is stable and the library is already in use.
Install
scim2-models on PyPI
pip
pip install scim2-modelsuv
uv add scim2-modelspoetry
poetry add scim2-modelsInstalling scim2-models
Before you install
Low friction: pure Python wheel with only pydantic as a runtime dependency. Actively maintained with recent releases. Supports Python 3.9–3.13.
License in practice
Apache License 2.0 is permissive; you may use, modify, and distribute this package freely in commercial and open-source projects, provided you include a copy of the license and note any changes.
Quickstart
pip install scim2-models
from scim2_models import User
payload = {
"schemas": ["urn:ietf:params:scim:schemas:core:2.0:User"],
"id": "2819c223-7f76-453a-919d-413861904646",
"userName": "bjensen@example.com",
}
user = User.model_validate(payload)
Requires Python 3.10 or later.
Verify before relying
- Whether the library handles all SCIM2 extensions and custom resource types in production scenarios.
- Performance characteristics when validating large batches of SCIM2 payloads.
- Completeness of error handling and SCIM-compliant exception conversion in edge cases.
Package facts
| License | Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for… (full text in the JSON record) (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — pydantic |
| Maintenance | actively maintained — 123 days since the last release |
| First released | |
| Downloads | 254,685/month — #8,491 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: scim2_models-0.6.12-py3-none-any.whl
Keywords: scim, scim2, provisioning, pydantic, rfc7643, rfc7644
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
django-scim2Implements the SCIM 2.0 provider specification…
permissive · top 5,000 on PyPI
pydantic-scimProvides Pydantic data models for SCIM (System…
unclear · top 15,000 on PyPI
scim2-serverProvides a lightweight SCIM2 server…
permissive · top 15,000 on PyPI
django-pydantic-fieldProvides type-safe Pydantic model schemas for…
permissive · top 5,000 on PyPI
ibm-quantum-schemasProvides Pydantic models that define the…
permissive · top 15,000 on PyPI
geojson-pydanticProvides Pydantic models that validate and…
permissive · top 5,000 on PyPI
sigstore-modelsProvides Pydantic-based data models that mirror…
unclear · top 15,000 on PyPI
safety-schemasProvides Pydantic models and schemas for Safety…
permissive · top 5,000 on PyPI
stac-pydanticProvides Pydantic models for validating and…
permissive · top 15,000 on PyPI
jsonschema-pydantic-converterConverts JSON Schema definitions to Pydantic v2…
permissive · top 15,000 on PyPI