uid

package
v0.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 14, 2026 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateShortID

func GenerateShortID() string

GenerateShortID creates a new 11-character lowercase short ID. It encodes the current microsecond timestamp in Crockford Base32. Thread-safe via mutex to prevent duplicate IDs under concurrency.

func IsShortID

func IsShortID(id string) bool

IsShortID checks whether the given string matches short ID lengths (11 or 21 chars).

func NormalizeID

func NormalizeID(id string) string

NormalizeID normalizes an ID to lowercase for consistent lookups.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL