Skip to content
/ IDGen Public

Generates url safe lexically sorted universally unique ids with a prefix in go

License

Notifications You must be signed in to change notification settings

Appointy/IDGen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

idgen

Go Report Card Build Status Coverage License: MIT

Generates url safe lexically sorted universally unique ids with a prefix in go. Inspired from Stripe.

Usage

package main

import (
    "fmt"

    "github.com/appointy/idgen"
)

func main()  {
    id := idgen.New("cus")
    fmt.Println(id)
    // Output: cus_0000XSNJG0MQJHBF4QX1EFD6Y3
}

Depends on

oklog/ulid

About

Generates url safe lexically sorted universally unique ids with a prefix in go

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages