Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

NanoIDP

NanoIDP

Tests

Test real OAuth2/OIDC, SAML 2.0 and MCP authorization flows locally,
without running a production IAM stack.

📖 Documentation

Design principles, non-goals and medium-term direction live in VISION.md.

Need a real OAuth2/OIDC or SAML counterpart for an integration test, a demo or an agent, without standing up Keycloak or provisioning a cloud tenant?

NanoIDP is an identity test environment: a spec-honest OAuth2/OIDC and SAML 2.0 provider you install with pip, configure with two YAML files and throw away when the test is done. What it advertises is what it implements, so your client is tested against the specification, not against a mock's guesses. It is a development and testing tool, not a production IdP.

Quick Start

pip install nanoidp

python -m nanoidp init    # create ./config (users, settings, keys)
python -m nanoidp         # serve on http://localhost:8000

Get a first token:

curl -X POST 'http://localhost:8000/token' \
  -u 'demo-client:demo-secret' \
  -d 'grant_type=client_credentials'

The admin UI runs at http://localhost:8000. Prefer Docker?

docker run --rm -p 8000:8000 \
  -v $(pwd)/config:/app/config \
  ghcr.io/cdelmonte-zg/nanoidp:latest

From here: the Quickstart walks through users, clients and the Authorization Code + PKCE flow; Requesting tokens has a copy-paste request for every grant; Install covers the wizard, custom config paths and docker-compose.

What you can test against it

  • OAuth2 / OIDC: Authorization Code with PKCE, Client Credentials, Refresh Token with rotation, Device Authorization (RFC 8628) and the Password grant for legacy clients; introspection (RFC 7662), revocation (RFC 7009) and RP-initiated logout; per-client scopes and audiences, claims mapping and authority prefixes; an opt-in oauth21 profile that enforces draft OAuth 2.1 strictness.
  • SAML 2.0: SSO and AttributeQuery with signed assertions, and opt-in verification of signed AuthnRequests.
  • Agents and MCP: an MCP server that lets an agent create users and clients, mint tokens and read the audit log, with a read-only mode; MCP tools and the HTTP API expose the same capabilities.
  • Running it: two schema-versioned YAML files with validation, security profiles, a passwordless persona login for demos, an audit log, hooks and plugins for wiring the deploy in, a Docker image.

Every item above has its reference page in the documentation below.

Documentation

The full documentation lives at https://cdelmonte-zg.github.io/nanoidp/:

Security

NanoIDP is a development/testing tool and must NOT be used in production. Defaults favor convenience (plaintext passwords in config, permissive CORS, open redirects); hardening is opt-in via the stricter-dev (runtime) and oauth21 (draft OAuth 2.1 protocol strictness) profiles and explicit settings. The Security guide draws the line precisely.

Development

pip install -e ".[dev]"
pytest

See CONTRIBUTING.md for the development setup, the end-to-end test agent, code quality tooling, and the release process.

Adopters

Organizations using NanoIDP in their development or testing workflows:

Listing means NanoIDP is in use there. It does not imply sponsorship or endorsement. If you use it and would like to be listed, open an issue or a pull request against this section.

License

MIT License. See LICENSE for details.

❤️ Support NanoIDP

NanoIDP is maintained as an open-source project.

If it helps you test OAuth2, OpenID Connect, or SAML flows, you can support its development here:

Metadata

Release files for nanoidp 3.1.0rc3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nanoidp 3.1.0rc3
File Size Uploaded
nanoidp-3.1.0rc3.tar.gz 231.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nanoidp 3.1.0rc3
File Interpreter ABI Platform
nanoidp-3.1.0rc3-py3-none-any.whl Python 3 none any Details

Total release size: 501.0 kB

Release files / nanoidp-3.1.0rc3.tar.gz

Download URL nanoidp-3.1.0rc3.tar.gz
Size 231.0 kB
Tags Source
SHA-256 checksum
How to use checksums
bd90809e1d12726ff7c448f8a3c794cba90a4a10327fed4e9f68b6be118466a9
BLAKE2b-256 checksum
How to use checksums
06aceab193938af1718f0f17bf880b093777379f778aea292120b1a7e7537118
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.

Transparency log

Release files / nanoidp-3.1.0rc3-py3-none-any.whl

Download URL nanoidp-3.1.0rc3-py3-none-any.whl
Size 270.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
78227102b24a6456c9f08080e824b1ffb3e9ac13b177ec1852fcd27b50fd50d5
BLAKE2b-256 checksum
How to use checksums
8e5165c6acebeeb608ec67c5c28131c3e3ee487df57dd6e27b9fec1da9893a7f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.

Transparency log

Release history Release notifications | RSS feed

3.4.0

2 release files

3.3.0

2 release files

3.2.0

2 release files

3.1.0

2 release files

This release

3.1.0rc3 This release

2 release files

3.0.0

2 release files

2.8.0

2 release files

2.7.0

2 release files

2.6.0

2 release files

2.5.0

2 release files

2.4.0

2 release files

2.3.0

2 release files

2.2.0

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.4.0

2 release files

1.3.3

2 release files

1.3.2

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.2.3

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page