vercre-sdk
Python SDK for the VERCRE Verifiable Credentials API.
Installation
pip install vercre-sdk
Quick Start
from vercre_sdk import VercreClient
client = VercreClient(
api_key="vercre_admin_your_key_here",
base_url="https://api.vercre.io",
)
# Issue a credential
credential = client.issue_credential(
issuer_did="did:key:z6Mk...",
subject_did="did:key:z6Mp...",
credential_type="KYCBasic",
claims={"name": "Alice Johnson", "country": "US"},
)
print(f"Issued: {credential.credential_id}")
# Verify a credential
result = client.verify_credential(credential=credential.credential)
print(f"Valid: {result.valid}, Decision: {result.compliance_decision}")
Async Usage
import asyncio
from vercre_sdk import AsyncVercreClient
async def main():
async with AsyncVercreClient(api_key="vercre_admin_xxx") as client:
result = await client.verify_credential(credential=my_credential)
print(result.compliance_decision)
asyncio.run(main())
Error Handling
from vercre_sdk import VercreClient, RateLimitError, AuthenticationError
client = VercreClient(api_key="...")
try:
result = client.verify_credential(credential=cred)
except RateLimitError as e:
print(f"Rate limited. Retry after {e.retry_after}s")
except AuthenticationError:
print("Invalid API key")
Available Methods
Credentials
issue_credential()- Issue a new verifiable credentialverify_credential()- Verify a credential with compliance scoringrevoke_credential()- Revoke a credentialget_credential_status()- Check on-chain attestation statusget_credential()- Look up credential by IDlist_credentials()- List credentials by subject DID
Verification
verify_presentation()- Verify a W3C Verifiable Presentation
Issuers
get_issuer()- Get issuer detailslist_issuers()- List registered issuerscheck_issuer_can_issue()- Check credential type authorization
Disputes
file_dispute()- File a dispute against a credentialget_dispute()- Get dispute detailslist_disputes()- List disputes
Reputation
get_reputation()- Get issuer reputation scoresubmit_feedback()- Submit verifier feedback
Webhooks
register_webhook()- Register a webhook endpointlist_webhooks()- List registered webhooksdelete_webhook()- Remove a webhook
Billing
get_subscription()- Get current planget_usage()- Get usage and remaining quotasubscribe()- Change billing planget_billing_portal_url()- Self-service billing management
Keys
rotate_key()- Rotate signing key for a DIDlist_key_versions()- List key version history
License
MIT
Release files for vercre-sdk 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vercre_sdk-1.0.0.tar.gz | 6.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vercre_sdk-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 17.8 kB
Release files / vercre_sdk-1.0.0.tar.gz
| Download URL | vercre_sdk-1.0.0.tar.gz |
|---|---|
| Size | 6.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ea64163f19429f7571f4b350536054861abf90d431cda917e6b6065acce48867
|
|
BLAKE2b-256 checksum How to use checksums |
e3716f57a586f4ce70db3ecfb5921483ee63979f39e89f0ea906a409a6bb36a4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Release files / vercre_sdk-1.0.0-py3-none-any.whl
| Download URL | vercre_sdk-1.0.0-py3-none-any.whl |
|---|---|
| Size | 10.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
83a557a095c7256fff800379132e4549b1fc7b36f8c3b350b255a5d4f43335e8
|
|
BLAKE2b-256 checksum How to use checksums |
f6c65e4dec4dcc805e8ba59a1a1a03a20404c0d7c7d9b012a93e2b8346a09bfb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|