Python client for the Identify auth service
Project description
identify-sdk (Python)
Python client for identify — a self-hosted modular authentication service.
Installation
pip install identify-sdk
Usage
from identify_sdk import IdentifyClient, IdentifyError
client = IdentifyClient(base_url="http://localhost:8080")
# Exchange username + password for a JWT
resp = client.login_with_password("user@example.com", "secret")
token = resp.token
# Validate a JWT
result = client.validate_token(token)
print(result.valid, result.identity.primary_identifier)
# Get identity for an authenticated token
identity = client.get_me(token)
Error handling
try:
resp = client.login_with_password("user@example.com", "wrong")
except IdentifyError as e:
print(e.status_code, str(e)) # 401, "HTTP 401: ..."
Full documentation: github.com/1909-pramod/identify-sdk
Project details
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 identify_sdk-0.1.2.tar.gz.
File metadata
- Download URL: identify_sdk-0.1.2.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
85eb5ea7a811a905d60a47fa483dbada43b7c713c371e816e24927aa74a875d5
|
|
| MD5 |
af756e4b07fe457fdff9cf0b60dd8aa5
|
|
| BLAKE2b-256 |
003231e633455888c2bf19fd59612c5967780d3950e1e38df5dea1daade524e1
|
Provenance
The following attestation bundles were made for identify_sdk-0.1.2.tar.gz:
Publisher:
publish-pypi.yml on 1909-pramod/identify-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
identify_sdk-0.1.2.tar.gz -
Subject digest:
85eb5ea7a811a905d60a47fa483dbada43b7c713c371e816e24927aa74a875d5 - Sigstore transparency entry: 1155185021
- Sigstore integration time:
-
Permalink:
1909-pramod/identify-sdk@f272992028eede098205780a3d84aad596878657 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/1909-pramod
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@f272992028eede098205780a3d84aad596878657 -
Trigger Event:
release
-
Statement type:
File details
Details for the file identify_sdk-0.1.2-py3-none-any.whl.
File metadata
- Download URL: identify_sdk-0.1.2-py3-none-any.whl
- Upload date:
- Size: 3.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9bd63d3d3d7847e7dec47592551a52815afd8b29c28177d31a05a78115031f9e
|
|
| MD5 |
8459b7bfa5710e26f39f09e20de21170
|
|
| BLAKE2b-256 |
7a6e0c3dda83525b527f193fb00003e6a411a2e56b4723ca3ffe1149eac21e90
|
Provenance
The following attestation bundles were made for identify_sdk-0.1.2-py3-none-any.whl:
Publisher:
publish-pypi.yml on 1909-pramod/identify-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
identify_sdk-0.1.2-py3-none-any.whl -
Subject digest:
9bd63d3d3d7847e7dec47592551a52815afd8b29c28177d31a05a78115031f9e - Sigstore transparency entry: 1155185022
- Sigstore integration time:
-
Permalink:
1909-pramod/identify-sdk@f272992028eede098205780a3d84aad596878657 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/1909-pramod
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@f272992028eede098205780a3d84aad596878657 -
Trigger Event:
release
-
Statement type: