定制 gladcodes/keygen 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

gladcodes/keygen

最新稳定版本:2.0.0-alpha

Composer 安装命令:

composer require gladcodes/keygen

包简介

A fluent PHP random key generator.

README 文档

README

A fluent PHP random key generator.

Packagist Packagist Packagist

Keygen is a PHP package that generates random character sequences known as keys. The package ships with built-in key generators for four key types namely: numeric, alphanumeric, token and byte. Its implementation effectively combines simplicity and expressiveness.

Installation

With Composer

The Keygen package can be installed easily with [Composer] - require the gladcodes/keygen package from the command line.

$ composer require gladcodes/keygen

Alternatively, you can manually add the Keygen package to the composer.json file of your project and then run composer install from the command line as follows:

{
    "require": {
        "gladcodes/keygen": "~1.1"
    }
}
$ composer install

You can use it in your PHP code like this:

<?php

require __DIR__ . '/vendor/autoload.php';
use Keygen\Keygen;

printf("Your appID is %.0f", Keygen::numeric(12)->generate()); // Your appID is 878234290135

Usage and Documentation

Todos

  • Write tests

License

The Keygen package is covered by the MIT License.

统计信息

  • 总下载量: 568.03k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 123
  • 点击次数: 1
  • 依赖项目数: 3
  • 推荐数: 0

GitHub 信息

  • Stars: 119
  • Watchers: 2
  • Forks: 17
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04