Sync Client¶
lacme.sync ¶
Synchronous wrapper around the async :class:~lacme.client.Client.
Provides :class:SyncClient, a blocking interface that delegates every
operation to the async Client through a managed event loop.
SyncChallengeHandler ¶
Bases: Protocol
Synchronous protocol for ACME challenge provisioning and cleanup.
SyncClient ¶
Synchronous ACME v2 client.
Wraps the async :class:~lacme.client.Client and exposes every public
method as a blocking call.
Usage::
with SyncClient(directory_url="...", account_key=key) as client:
cert = client.issue(["example.com"])
check_rate_limits ¶
Check if issuing for domains would exceed rate limits.
create_account ¶
create_account(*, contact: list[str] | None = None, terms_of_service_agreed: bool = True, only_return_existing: bool = False, eab_kid: str | None = None, eab_hmac_key: str | None = None) -> Account
Create or find an existing ACME account.
create_authorization ¶
create_authorization(identifier_value: str, *, identifier_type: IdentifierType = IdentifierType.DNS) -> Authorization
Create a pre-authorization for an identifier.
create_order ¶
create_order(domains: str | list[str], *, not_before: str | None = None, not_after: str | None = None) -> Order
Create a new certificate order.
download_certificate ¶
Download the certificate chain via POST-as-GET.
finalize_order ¶
Submit the CSR to finalize the order.
get_authorization ¶
Fetch an authorization via POST-as-GET.
get_authorizations ¶
Fetch all authorizations for an order.
issue ¶
issue(domains: str | list[str], *, challenge_type: str = 'http-01', challenge_map: dict[str, tuple[str, ChallengeHandler]] | None = None) -> CertBundle
Issue a certificate for the given domain(s).
poll_authorization ¶
Poll an authorization until it reaches a terminal state.
poll_order ¶
Poll an order until it reaches a terminal state.
respond_to_challenge ¶
Signal readiness for challenge validation.
revoke ¶
Revoke a certificate using the account key.
revoke_with_cert_key ¶
revoke_with_cert_key(cert_pem: bytes | str, cert_key: EllipticCurvePrivateKey, *, reason: int | None = None) -> None
Revoke a certificate using its own key pair.
rollover_key ¶
Roll over the account key.