SDK Documentation

Integrate Authera into your application with our comprehensive SDKs. Choose your language and get started in minutes.

Node.js SDK

Electron & Web backends

Installation

npm install authera-sdk-client

Quick Start

import { AutheraClient } from 'authera-sdk-client';

const client = new AutheraClient({
  appId: 'your-app-id',
  apiKey: 'your-api-key'
});

// Validate license
const isValid = await client.validateLicense('LICENSE_KEY');

Key Features

  • ✓ HMAC request signing built-in
  • ✓ Hardware ID (HWID) binding
  • ✓ Real-time license validation
  • ✓ Express/Fastify middleware support
  • ✓ Electron main/renderer process ready
  • ✓ TypeScript support with full types

Common Use Cases

  • • Protect Electron desktop applications
  • • License validation in Node.js servers
  • • User authentication and authorization
  • • License key generation and management

C# SDK

Desktop & WPF/WinForms

Installation

dotnet add package Authera.SDK

Quick Start

using Authera.SDK;

var client = new AutheraClient(
    appId: "your-app-id",
    apiKey: "your-api-key"
);

// Validate license
bool isValid = await client.ValidateLicenseAsync("LICENSE_KEY");

Key Features

  • ✓ Async-first API design
  • ✓ Machine binding (Windows SMBIOS)
  • ✓ Thread-safe operations
  • ✓ WPF/WinForms component support
  • ✓ .NET Framework 4.7.2+ & .NET 6.0+
  • ✓ Full IntelliSense documentation

Common Use Cases

  • • WPF desktop applications
  • • WinForms legacy applications
  • • Console applications
  • • ASP.NET backend integration

C++ SDK

Windows & High-performance

Installation

git clone https://github.com/khawarahemad/authera-SDK-Cpp.git

Quick Start

#include "AutheraClient.h"

AutheraClient client("your-app-id", "your-api-key");

// Validate license
bool isValid = client.ValidateLicense("LICENSE_KEY");

Key Features

  • ✓ Native crypto & HTTP stack
  • ✓ Minimal dependencies
  • ✓ Windows HWID detection
  • ✓ High-performance validation
  • ✓ suited for games & tools
  • ✓ Compiled binaries included

Common Use Cases

  • • Game client protection
  • • Performance-critical tools
  • • Windows system utilities
  • • CAD/3D software licensing

Core API Reference

License Methods

validateLicense(key)

Verify license validity and status

bindLicenseToHwid(key, hwid)

Bind license to hardware ID

getLicenseInfo(key)

Get license details and expiration

revokeLicense(key)

Invalidate a license key

Authentication Methods

authenticateUser(email, password)

User login with email & password

verifyOAuth(provider, token)

Verify OAuth tokens from providers

signUserToken(userId)

Create signed JWT for app users

verifyUserToken(token)

Validate signed user tokens

Best Practices

🔒 Security

  • Always use HTTPS for API calls
  • Store API keys in environment variables
  • Implement request signing for server-to-server
  • Validate HWID changes server-side
  • Rate limit license validation calls

⚡ Performance

  • Cache validation results locally
  • Implement exponential backoff for retries
  • Use async/await for non-blocking operations
  • Batch license checks when possible
  • Monitor API response times

✅ Testing

  • Use test app IDs for development
  • Mock license responses in unit tests
  • Test HWID binding edge cases
  • Validate error handling paths
  • Run integration tests before deployment

🚀 Deployment

  • Version your SDK integrations
  • Plan for API deprecation warnings
  • Monitor failed validations
  • Keep error logs for debugging
  • Have fallback authentication flows

Ready to integrate?

Choose your SDK above and start building. Check our GitHub repositories for complete examples and source code.