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

author
Sri Krishna Paritala
May 29, 2019
c7fc62c · May 29, 2019

History

24 Commits
Nov 14, 2018
Feb 27, 2019
Nov 14, 2018
Feb 1, 2019
Nov 16, 2018
May 28, 2019
Feb 27, 2019
Nov 19, 2018
Feb 27, 2019

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