{"id":20737101,"url":"https://github.com/phpexpertsinc/conciseuuid","last_synced_at":"2025-04-24T01:42:15.253Z","repository":{"id":46201783,"uuid":"157257110","full_name":"PHPExpertsInc/ConciseUuid","owner":"PHPExpertsInc","description":"A ConciseUuid Model for Eloquent / Laravel.","archived":false,"fork":false,"pushed_at":"2021-11-07T16:21:20.000Z","size":507,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-09-23T10:37:38.910Z","etag":null,"topics":["uuid"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PHPExpertsInc.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"contributing.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-11-12T18:21:56.000Z","updated_at":"2024-03-12T00:15:11.000Z","dependencies_parsed_at":"2022-08-24T00:50:55.221Z","dependency_job_id":null,"html_url":"https://github.com/PHPExpertsInc/ConciseUuid","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PHPExpertsInc%2FConciseUuid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PHPExpertsInc%2FConciseUuid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PHPExpertsInc%2FConciseUuid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PHPExpertsInc%2FConciseUuid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PHPExpertsInc","download_url":"https://codeload.github.com/PHPExpertsInc/ConciseUuid/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250545684,"owners_count":21448247,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["uuid"],"created_at":"2024-11-17T06:13:33.517Z","updated_at":"2025-04-24T01:42:15.191Z","avatar_url":"https://github.com/PHPExpertsInc.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ConciseUuid\n\nConciseUuid is an Eloquent Model that uses a concise UUIDv4 as the primary key.\n\nA normal UUID is 36 characters and looks like: \n\n    d318fb95-5b49-47ca-abd5-326a60524e70\n    \nThis is very long, and in base16, there is a lot of unnecessary space.\n\nConciseUuid takes this, strips out the \"-\" and converts the base16 into base62 (0-9, a-z, A-Z).\nHere is the Concise version of the above UUID:\n\n    Old: d318fb95-5b49-47ca-abd5-326a60524e70\n    New: 6QKnU3XheQMk3E6Vq1B4l6\n    \nAs you can see, it is much more concise: 15 characters less!\n\nBecause of how the UUIDv4 algorithm is specified, a UUID will never begin with anything\nother than a number (0-9). So if you want a special class of UUIDs, pass in `true`. These\nUUIDs will *always* begin with a letter, letting you quickly differentiate them from\nnormal UUIDs.\n\n    echo ConciseUuid::generateNewId(true);\n    // Output: rEBzkc6s67JU3kI7ZuA7TU\n\n## Usage\n\n    SQL: \n    CREATE TABLE my_model (id char(22) primary key);\n\n    PHP:\n    namespace PHPExperts\\ConciseUuid\\ConciseUuidModel;\n\n    class MyModel extends ConciseUuidModel\n    {\n    }\n\n    For your users table:\n    namespace PHPExperts\\ConciseUuid\\ConciseUuidAuthModel;\n\n    class User extends ConciseUuidAuthModel\n    {\n    }\n\n## Installation\n\nVia Composer\n\n``` bash\n$ composer require phpexperts/conciseuuid\n```\n\nHaving the GMP extension enabled **really** improves the execution time of this package.\n\n## Use cases\n\n✔ Generate new id function will always return 22 characters long string\n✔ Normal ids start with a number\n✔ System generated ids start with a letter\n✔ Can convert to a concise uuid\n✔ Can convert to a uuid\n✔ Can convert to a uuid without dashes\n✔ Can generate new version 4 uuids\n✔ Can strip slashes from uuids\n\n## Change log\n\nPlease see the [changelog](CHANGELOG.md) for more information on what has changed recently.\n\n## Testing\n\n``` bash\n$ phpunit\n```\n\n## Contributing\n\nPlease take a look at [contributing.md](contributing.md) if you want to make improvements.\n\n\n## Credits\n\n- [Theodore R. Smith](https://www.phpexperts.pro/])\n- [Rishi Ramawat](https://github.com/rishi-ramawat)\n- [Smijo Thekkudan](https://github.com/smijo149)\n\n## License\n\nMIT license. Please see the [license file](license.md) for more information.\n\n\n[ico-version]: https://img.shields.io/packagist/v/phpexperts/conciseuuid.svg?style=flat-square\n[ico-downloads]: https://img.shields.io/packagist/dt/phpexperts/conciseuuid.svg?style=flat-square\n[ico-travis]: https://img.shields.io/travis/phpexperts/conciseuuid/master.svg?style=flat-square\n[ico-styleci]: https://styleci.io/repos/12345678/shield\n\n[link-packagist]: https://packagist.org/packages/phpexperts/conciseuuid\n[link-downloads]: https://packagist.org/packages/phpexperts/conciseuuid\n[link-travis]: https://travis-ci.org/phpexperts/conciseuuid\n[link-styleci]: https://styleci.io/repos/12345678\n[link-author]: https://github.com/phpexperts\n[link-contributors]: ../../contributors]\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphpexpertsinc%2Fconciseuuid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphpexpertsinc%2Fconciseuuid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphpexpertsinc%2Fconciseuuid/lists"}