idmap
A local identity-correlation store: it maps identifiers from arbitrary namespaces (services) to a single canonical person. Start from any identifier and link more later — no service is special, and adding a new one is never a schema change.
It knows nothing about LDAP, GitHub, or any specific service. It's a set/get
utility over an identity graph,
backed by a single SQLite file. No network calls.
Install
From PyPI (needs Python 3.10+):
pip install idmap
Or, since it's a single file using only the standard library, drop it on your
$PATH directly:
cp idmap.py ~/.local/bin/idmap # anywhere on $PATH
The database is created on first use at $IDMAP_DB, or
${XDG_DATA_HOME:-~/.local/share}/idmap/idmap.db. Override per-invocation with
--db PATH.
Development
The project uses only Python's standard library. Run the full local check with:
make ci
This compiles the Python files, runs the unit tests, and builds the
distribution artifacts, so a change that breaks packaging is caught early.
Individual checks are available with make compile, make test, and
make build; running make lists all targets.
The build step needs the build package
(pip install build) and produces dist/*.whl and dist/*.tar.gz.
Releases are published to PyPI automatically by GitHub Actions when a GitHub
release is published (see .github/workflows/publish.yml), using PyPI
Trusted Publishing.
Concepts
- An identifier is
namespace:handle, e.g.github:alice,ldap:asmith,quay:alice-q. The namespace is lowercased; the handle is kept verbatim. - A namespace may have an associated URL, such as
github.comorfoo.my.corp.com.br. The URL is stored exactly as supplied; idmap never contacts it or otherwise interprets it. - A person (entity) is a cluster of identifiers that all refer to the same human. You never create a person explicitly — it appears the first time you name an identifier, and clusters merge automatically when you link two that already exist.
- A person may hold multiple handles in one namespace (alt accounts,
renamed users), so
get --nscan return more than one line.
Usage
# Assert that these identifiers name the same person (creates or merges).
idmap set github:alice ldap:asmith
# Attach more later, starting from any known identifier.
idmap set ldap:asmith quay:alice-q gitlab:alice-gl
# Resolve: all identifiers for the person, or just one namespace's handle(s).
idmap get ldap:asmith # github:alice, gitlab:alice-gl, ...
idmap get ldap:asmith --ns github # alice
idmap get quay:alice-q --ns gitlab # alice-gl
idmap get ldap:asmith --name # Alice Smith
# Inspect.
idmap ls # every person and their identifiers
idmap ls --ns github # every github:* handle on record
idmap namespace set github github.com # associate a URL with a namespace
idmap namespace get github # print the stored URL
idmap namespace ls # list namespaces and URLs
# Labels and corrections.
idmap name github:alice "Alice Smith"
idmap unlink quay:alice-q # split it off into its own person
idmap rm gitlab:alice-gl # forget an identifier
get prints nothing and exits non-zero when the identifier (or requested
namespace, or a name that was never set) isn't known — convenient for shell
callers.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file idmap-0.1.0.tar.gz.
File metadata
- Download URL: idmap-0.1.0.tar.gz
- Upload date:
- Size: 9.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd04a78407ab75ed097c231f142e25fb0a2c6da30a16dec19f6eb2c32c7c31f6
|
|
| MD5 |
728ff58882fb35fa93a84f029f3413a9
|
|
| BLAKE2b-256 |
b7d4bc3ee8929f17a26325d9fe644d08e560084c2b6270fd8ae98ee65d68d3d8
|
Provenance
The following attestation bundles were made for idmap-0.1.0.tar.gz:
Publisher:
publish.yml on lcarva/idmap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
idmap-0.1.0.tar.gz -
Subject digest:
dd04a78407ab75ed097c231f142e25fb0a2c6da30a16dec19f6eb2c32c7c31f6 - Sigstore transparency entry: 2851399256
- Sigstore integration time:
-
Permalink:
lcarva/idmap@db541f909c76bd6fb45313306690500b6f5d8736 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/lcarva
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@db541f909c76bd6fb45313306690500b6f5d8736 -
Trigger Event:
release
-
Statement type:
File details
Details for the file idmap-0.1.0-py3-none-any.whl.
File metadata
- Download URL: idmap-0.1.0-py3-none-any.whl
- Upload date:
- Size: 10.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aff7c6055f298e80d17d140e853f261a8bacace0ceb5bbf488fc82ec22457255
|
|
| MD5 |
6fe9655adf8c901bb57488f34c03425a
|
|
| BLAKE2b-256 |
81531325a611a74b76160b2594445bbad8ac0362aaa5a8587eaa8fa5856f0d78
|
Provenance
The following attestation bundles were made for idmap-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on lcarva/idmap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
idmap-0.1.0-py3-none-any.whl -
Subject digest:
aff7c6055f298e80d17d140e853f261a8bacace0ceb5bbf488fc82ec22457255 - Sigstore transparency entry: 2851399281
- Sigstore integration time:
-
Permalink:
lcarva/idmap@db541f909c76bd6fb45313306690500b6f5d8736 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/lcarva
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@db541f909c76bd6fb45313306690500b6f5d8736 -
Trigger Event:
release
-
Statement type: