skgl_flutter 1.0.0 copy "skgl_flutter: ^1.0.0" to clipboard
skgl_flutter: ^1.0.0 copied to clipboard

A flutter plugin to generate & validate human readable, 20-character serial keys with up to 8 features embedded.

SKGL (flutter) #

Pub License

The SKGL library, written in Kotlin, with a shiny new API. Use this to generate & validate human readable, 20-character serial keys with up to 8 features embedded.

Installation #

Add skgl_flutter as a dependency in your pubspec.yaml file.

Import SKGL:

import 'package:skgl_flutter/skgl_flutter.dart';

Generate a Key #

final key = SerialKey.build('a-secret',
    config: SerialKeyBuildConfig(
      features: {1, 3, 5},
      duration: 30,
      chunk: true,
    ));

print(key.text); // XXXXX-XXXXX-XXXXX-XXXXX

Decode a Key #

final key = SerialKey('XXXXX-XXXXX-XXXXX-XXXXX', 'a-secret');

var createdOn = key.createdOn;
var expiresOn = key.expiresOn;
var features = key.features;
var isExpired = key.calculateIsExpired();
var daysLeft = key.calculateDaysLeft();

UI #

The flutter-powered example project can be used to generate or validate keys,

About

Generate

Validate

1
likes
140
pub points
0%
popularity

Publisher

unverified uploader

A flutter plugin to generate & validate human readable, 20-character serial keys with up to 8 features embedded.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

flutter, intl

More

Packages that depend on skgl_flutter