Skip to content

keygen-sh/example-python-license-validation

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Example License Validation

This is an example of how to validate a license key using Keygen's API.

Running the example

First up, configure a few environment variables:

# Your Keygen account ID. Find yours at https://app.keygen.sh/settings.
export KEYGEN_ACCOUNT_ID="YOUR_KEYGEN_ACCOUNT_ID"

You can either run each line above within your terminal session before starting the app, or you can add the above contents to your ~/.bashrc file and then run source ~/.bashrc after saving the file.

Next, install dependencies with pip:

python3 -m pip install -r requirements.txt

Validating a license key

To perform a license key validation, run the script and supply a license key:

python3 main.py some-license-key-here

The script will validate the license key and print the validation result.

Questions?

Reach out at support@keygen.sh if you have any questions or concerns!

About

An example implementation of validating a license key using Keygen and Python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%