Skip to main content

Official Python client for the Locksmith JWT authentication API (signup, login, OAuth, magic links).

Project description

locksmith-py

Official Python 3 client for the Locksmith public auth API.

Install

pip install locksmith-py

Requirements

  • Python 3.10+
  • API key prefix lsm_live_ or lsm_sbx_ (environment is derived automatically).

Quick start

import os
from locksmith import LocksmithClient

c = LocksmithClient(api_key=os.environ["LOCKSMITH_API_KEY"])

result = c.sign_up(email="user@example.com", password="secure-password")
print(result["user"]["id"], result["accessToken"])

me = c.get_user(result["accessToken"])

Local JWT verification

payload = c.verify_token(access_token, public_key_pem)

License

MIT

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

locksmith_py-1.2.3.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

locksmith_py-1.2.3-py3-none-any.whl (4.8 kB view details)

Uploaded Python 3

File details

Details for the file locksmith_py-1.2.3.tar.gz.

File metadata

  • Download URL: locksmith_py-1.2.3.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for locksmith_py-1.2.3.tar.gz
Algorithm Hash digest
SHA256 aa6883f999f54d486d0fa8bfbe852e4328faabd8cc8053fc2e2d44623aa0badd
MD5 d752d69476bd6f0383c240ca8c61a77d
BLAKE2b-256 9348f6c2513d521d5f3a08d3354352cea7619cd0df97e5d574f2dba5e4a1a58e

See more details on using hashes here.

File details

Details for the file locksmith_py-1.2.3-py3-none-any.whl.

File metadata

  • Download URL: locksmith_py-1.2.3-py3-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for locksmith_py-1.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 05cc1d324b04ecd090b2de7918b83b38930d96aafb1dee68bdc50bbe95a9a47b
MD5 297509e5db290cbe64feac9d8074e61d
BLAKE2b-256 f65d939ebc70c276c5c68272de87aa04ce58d3fd8d010121f458f9c145444208

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page