Skip to main content
The AuthForge SDK handles license validation, HWID fingerprinting, cryptographic signature verification, and background heartbeats. Each SDK is a single file you drop into your project — no package managers required.

Available SDKs

Python SDK

authforge.pyPython 3.9+, zero dependencies.

C# SDK

AuthForgeClient.cs.NET 6+, zero dependencies.

C++ SDK

authforge_sdk.h + .cppC++17, OpenSSL, libcurl.
SDKFilesRequirementsGitHubDirect Download
Pythonauthforge.pyPython 3.9+RepositoryDownload
C#AuthForgeClient.cs.NET 6+RepositoryDownload
C++authforge_sdk.h + authforge_sdk.cppC++17, OpenSSL, libcurlRepositoryDownload

How it works

All three SDKs implement the same flow:
  1. Initialize — Create a client with your App ID, App Secret, and heartbeat mode.
  2. Login — Call login(licenseKey). The SDK collects the machine’s HWID, generates a cryptographic nonce, and sends a validate request to the AuthForge API.
  3. Verify — The SDK verifies the HMAC-SHA256 signature on the server response using a key derived from SHA256(appSecret + nonce). This prevents replay and man-in-the-middle attacks.
  4. Heartbeat — A background thread runs at the configured interval (default 15 minutes) to keep the session alive and detect revocations.
  5. Failure — If authentication or a heartbeat fails, the SDK calls your onFailure callback with a reason ("login_failed" or "heartbeat_failed") and the exception. If no callback is set, the process exits.

Common constructor parameters

Every SDK accepts the same parameters:
ParameterTypeDefaultDescription
appIdstringrequiredYour application ID from the dashboard
appSecretstringrequiredYour application secret
heartbeatModestringrequired"SERVER" or "LOCAL"
heartbeatIntervalinteger900Seconds between heartbeat checks
apiBaseUrlstringhttps://auth.authforge.ccOverride the API base URL
onFailurecallbacknullCalled on auth/heartbeat failure with (reason, exception)
requestTimeoutinteger15HTTP request timeout in seconds

Next steps